Caption is a variable Wishlist
Posted: Fri Sep 19, 2014 11:01 pm
Hello Polo et al,
Is it possible to modify the Open Window Procedure that the Form Designer auto generates. I ask if it's possible to add an extra parameter into the procedure call
Current output from Form Designger. I have "Caption as a variable" selected with the variable WindowTitle.s
Now with EnableExplicit I have to create a Global declaration for WindowTitle.s so that the procedure can access the variable. I don't like Globals much so if I can call the openwindow procedure and specify the string that would be great from my main.pb file.
main.pb
aboutwindow.pbf
So the Form Designer takes your variable that you supply to "Caption as a variable" and puts it into the OpenWindow call and puts the variable into the Procedure call.
I hope you understand what I mean.
Is it possible to modify the Open Window Procedure that the Form Designer auto generates. I ask if it's possible to add an extra parameter into the procedure call
Current output from Form Designger. I have "Caption as a variable" selected with the variable WindowTitle.s
Code: Select all
Procedure OpenAboutWindow(x = 0, y = 0, width = 180, height = 90)
AboutWindow = OpenWindow(#PB_Any, x, y, width, height, WindowTitle.s, #PB_Window_SystemMenu)
OKButton = ButtonGadget(#PB_Any, 40, 50, 100, 25, "OKButtony")
EndProceduremain.pb
Code: Select all
OpenAboutWindow(x = 45, y = 60, width = 180, height = 90, "My About Page")Code: Select all
Procedure OpenAboutWindow(x = 0, y = 0, width = 180, height = 90,WindowTitle.s)
AboutWindow = OpenWindow(#PB_Any, x, y, width, height, WindowTitle.s, #PB_Window_SystemMenu)
OKButton = ButtonGadget(#PB_Any, 40, 50, 100, 25, "OKButtony")
EndProcedureI hope you understand what I mean.