$PBExportHeader$w_main.srw forward global type w_main from window end type type cbx_pcode from checkbox within w_main end type type cbx_console from checkbox within w_main end type type sle_logfile from singlelineedit within w_main end type type st_1 from statictext within w_main end type type cb_optionoff from commandbutton within w_main end type type cb_beep from commandbutton within w_main end type type cb_stop from commandbutton within w_main end type type cb_start from commandbutton within w_main end type type cb_cancel from commandbutton within w_main end type end forward global type w_main from window integer width = 2135 integer height = 1044 boolean titlebar = true string title = "PBDebug" boolean controlmenu = true boolean minbox = true boolean maxbox = true long backcolor = 67108864 string icon = "AppIcon!" boolean center = true cbx_pcode cbx_pcode cbx_console cbx_console sle_logfile sle_logfile st_1 st_1 cb_optionoff cb_optionoff cb_beep cb_beep cb_stop cb_stop cb_start cb_start cb_cancel cb_cancel end type global w_main w_main type prototypes end prototypes type variables n_pbdebug in_pbdebug end variables on w_main.create this.cbx_pcode=create cbx_pcode this.cbx_console=create cbx_console this.sle_logfile=create sle_logfile this.st_1=create st_1 this.cb_optionoff=create cb_optionoff this.cb_beep=create cb_beep this.cb_stop=create cb_stop this.cb_start=create cb_start this.cb_cancel=create cb_cancel this.Control[]={this.cbx_pcode,& this.cbx_console,& this.sle_logfile,& this.st_1,& this.cb_optionoff,& this.cb_beep,& this.cb_stop,& this.cb_start,& this.cb_cancel} end on on w_main.destroy destroy(this.cbx_pcode) destroy(this.cbx_console) destroy(this.sle_logfile) destroy(this.st_1) destroy(this.cb_optionoff) destroy(this.cb_beep) destroy(this.cb_stop) destroy(this.cb_start) destroy(this.cb_cancel) end on type cbx_pcode from checkbox within w_main integer x = 549 integer y = 256 integer width = 562 integer height = 68 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" long textcolor = 33554432 long backcolor = 67108864 string text = "Show P-Code" end type type cbx_console from checkbox within w_main integer x = 549 integer y = 160 integer width = 562 integer height = 68 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" long textcolor = 33554432 long backcolor = 67108864 string text = "Show Console" end type type sle_logfile from singlelineedit within w_main integer x = 549 integer y = 40 integer width = 1541 integer height = 84 integer taborder = 30 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" long textcolor = 33554432 string text = "C:\PBApps\WebExamples\PBDebug\pbtrace.txt" borderstyle borderstyle = stylelowered! end type type st_1 from statictext within w_main integer x = 37 integer y = 576 integer width = 978 integer height = 68 integer textsize = -10 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" long textcolor = 255 long backcolor = 67108864 string text = "This will only work in an executable!" boolean focusrectangle = false end type type cb_optionoff from commandbutton within w_main integer x = 37 integer y = 416 integer width = 443 integer height = 100 integer taborder = 50 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" string text = "Option Off" end type event clicked;// turn off debugging option in_pbdebug.of_option_off(34) end event type cb_beep from commandbutton within w_main integer x = 37 integer y = 288 integer width = 443 integer height = 100 integer taborder = 40 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" string text = "Beep" end type event clicked;Beep(1) end event type cb_stop from commandbutton within w_main integer x = 37 integer y = 160 integer width = 443 integer height = 100 integer taborder = 30 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" string text = "Stop Debug" end type event clicked;// turn off debugging in_pbdebug.of_debug_off() end event type cb_start from commandbutton within w_main integer x = 37 integer y = 32 integer width = 443 integer height = 100 integer taborder = 20 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" string text = "Start Debug" end type event clicked;// set debug filename in_pbdebug.of_logfilename(sle_logfile.text) // turn on debugging options in_pbdebug.of_option_on(30) // Show function/event calls If cbx_console.Checked Then in_pbdebug.of_option_on(1) // Display console End If If cbx_pcode.Checked Then in_pbdebug.of_option_on(34) // Show pcode line execution End If // turn on debugging in_pbdebug.of_debug_on() end event type cb_cancel from commandbutton within w_main integer x = 1755 integer y = 832 integer width = 334 integer height = 100 integer taborder = 10 integer textsize = -8 integer weight = 400 fontcharset fontcharset = ansi! fontpitch fontpitch = variable! fontfamily fontfamily = swiss! string facename = "Tahoma" string text = "Cancel" boolean cancel = true end type event clicked;Close(Parent) end event
File: w_main.srw
Size: 6094
Date: Sun, 12 Jul 2026 05:10:42 +0200
Size: 6094
Date: Sun, 12 Jul 2026 05:10:42 +0200
- window w_main(srw)
- checkbox cbx_pcode
- checkbox cbx_console
- singlelineedit sle_logfile
- statictext st_1
- commandbutton cb_optionoff
- commandbutton cb_beep
- commandbutton cb_stop
- commandbutton cb_start
- commandbutton cb_cancel