Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Put a web browser on your desktop
Message
 
 
To
25/02/2010 14:34:22
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01451027
Message ID:
01451044
Views:
123
This message has been marked as the solution to the initial question of the thread.
1. What is Signoff

2. You need to set txtUrl = site in order for this to work.

e.g.
if vartype(ox) = 'O' and ox.baseclass = 'Form'
   ox.txtUrl.value = site
    ox.txtUrl.valid()
endif
>Hi Naomi
>First time works like a charm. It's the second selection that doesn't work. It sticks on first selection.
>here's a functioning program with actual websitesif you'd like to paste it into a sample program.
>Press the first selection for google.
>Then redo only this time select Foxforum, the webbrowser remains on Google.
>
>k
>
>
>do netted
>activate popup mnubef
>SITE = " "
>
>proc netted
>DEFINE POPUP mnubef relative COLOR SCHEME 6 FROM 3,55  FONT 'tahoma',11 ;
> 
>DEFINE Bar 1 of mnuBef PROMPT 'Google'
>DEFINE Bar 2 OF mnuBef PROMPT 'FoxForum'
>DEFINE Bar 3 OF mnuBef PROMPT 'Universal thread'
>DEFINE Bar 4 OF mnuBef PROMPT 'Return to Menu' 
>On Selection Popup mnubef Do netter
>
>proc netter
>do case
>case bar()=1
>site = "http://www.google.ca/"
>DO NETUP
>DO SIGNOFF
>
>case bar()=2
>site = "http://foxforum.com/"
>DO NETUP
>DO SIGNOFF
>
>case bar()=3
>site = "http://www.levelextreme.com/"
>DO NETUP
>DO SIGNOFF
>
>
>case bar()=4
>clear
>deactivate popup mnubef
>return
>endcase
>
>
>PROC NETUP
>PUBLIC ox
>
>ox=NEWOBJECT("myformx")
>
>BINDEVENT(_screen,"resize",ox,"resize")
>
>ox.show
>
> 
>
> 
>
>DEFINE CLASS myformx as Form
>
>      ADD OBJECT txtURL as textbox WITH width=400,value=SITE
>
>    
>      
>
>      ADD OBJECT oweb as cweb WITH top=30
>
>      width=800
>
>      height=800
>
>      alwaysonbottom=.t.
>
>      allowoutput=.f.
>
>      titlebar=0
>
>      PROCEDURE init
>
>            this.oweb.width=thisform.Width
>
>            thisform.resize
>
>            this.oweb.height=thisform.height-thisform.txtURL.height-2
>
>            thisform.txtURL.valid
>
>      PROCEDURE resize
>
>            thisform.Width=_screen.Width
>
>            thisform.Height=_screen.height
>
>            this.oweb.top=30
>
>            this.oweb.height=thisform.Height-100
>
>            this.oweb.width=thisform.width-thisform.left
>
>      PROCEDURE txtURL.valid
>
>            thisform.oweb.navigate(this.value)
>
>       
>
>ENDDEFINE
>
>DEFINE CLASS cweb as olecontrol
>
>      oleclass="shell.explorer.2"
>
>      PROCEDURE refresh
>
>            nodefault
>
>ENDDEFINE
>
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform