Window 98 RunProgram Gotcha?

Windows specific forum
Karbon
PureBasic Expert
PureBasic Expert
Posts: 2010
Joined: Mon Jun 02, 2003 1:42 am
Location: Ashland, KY
Contact:

Window 98 RunProgram Gotcha?

Post by Karbon »

Code: Select all

RunProgram("http://www.google.com")
Under Windows 2000 and higher it opens the default browser and goes to www.google.com - under Windows 98 it does nothing..

I'm not sure if this is any kind of bug in PB, it might be that 98 just doesn't support this kind of thing.. If anyone has any more of a clue than I do on this please let me know!
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

Re: Window 98 RunProgram Gotcha?

Post by NoahPhense »

Karbon wrote:

Code: Select all

RunProgram("http://www.google.com")
Under Windows 2000 and higher it opens the default browser and goes to www.google.com - under Windows 98 it does nothing..

I'm not sure if this is any kind of bug in PB, it might be that 98 just doesn't support this kind of thing.. If anyone has any more of a clue than I do on this please let me know!
What version of IE ?

- np
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6172
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

i think not all versions of 98 support this, it might be related to the 'start' command on the command prompt that i think doesn't exist on windows 98 either (not on me own machine, can't check at the moment)
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB - upgrade incoming...)
( The path to enlightenment and the PureBasic Survival Guide right here... )
fweil
Enthusiast
Enthusiast
Posts: 725
Joined: Thu Apr 22, 2004 5:56 pm
Location: France
Contact:

Post by fweil »

NoahPhense,

If RunProgram does not apply, does ShellExecute() work for you ?

Code: Select all

  ShellExecute_(0, "open", "http://www.purebasic.com", "", "", 0)
Rgrds
My avatar is a small copy of the 4x1.8m image I created and exposed at 'Le salon international du meuble à Paris' january 2004 in Matt Sindall's 'Shades' designers exhibition. The original laminated print was designed using a 150 dpi printout.
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

..

Post by NoahPhense »

fweil wrote:NoahPhense,

If RunProgram does not apply, does ShellExecute() work for you ?

Code: Select all

  ShellExecute_(0, "open", "http://www.purebasic.com", "", "", 0)
Rgrds
Its not me, it's Karbon. ;)

I was attempting to help diagnose.

- np
fweil
Enthusiast
Enthusiast
Posts: 725
Joined: Thu Apr 22, 2004 5:56 pm
Location: France
Contact:

Post by fweil »

Sorry !

I should upgrade to 3.91 ! 8)
My avatar is a small copy of the 4x1.8m image I created and exposed at 'Le salon international du meuble à Paris' january 2004 in Matt Sindall's 'Shades' designers exhibition. The original laminated print was designed using a 150 dpi printout.
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

..

Post by NoahPhense »

fweil wrote:Sorry !

I should upgrade to 3.91 ! 8)
Good Idea..

- np
Karbon
PureBasic Expert
PureBasic Expert
Posts: 2010
Joined: Mon Jun 02, 2003 1:42 am
Location: Ashland, KY
Contact:

Post by Karbon »

Yes, shellexecute_() does work!
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
benny
Enthusiast
Enthusiast
Posts: 465
Joined: Fri Apr 25, 2003 7:44 pm
Location: end of www
Contact:

Post by benny »

@Karbon:

In Win98 go to ->START->EXECUTE COMMAND
and then try to type in:

Code: Select all

http://www.google.com
Does this open the explorer with google :?:
In XP it does - so if it doesn't, I think it's Win98-related, because IMHO the RunProgram-Command is like the START->EXECUTE COMMAND thing :?: :!: :roll:

Otherwise try something like

Code: Select all

Windows.s = Space(256)
GetWindowsDirectory_(@Windows.s, 256)
RunProgram("iexplore.exe", "http://www.google.com", Windows.s)
Maybe this helps :!:

EDIT
Ahhhh .. ok .. problem already solved :oops:
I was too late ... as always!
regards,
benny!
-
pe0ple ar3 str4nge!!!
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Window 98 RunProgram Gotcha?

Post by PB »

> RunProgram("http://www.google.com")
> under Windows 98 it does nothing..
> I'm not sure if this is any kind of bug

Well, technically it's NOT a bug because it's RunProgram, not OpenWebPage. ;)
Brice Manuel

Post by Brice Manuel »

Windows.s = Space(256)
GetWindowsDirectory_(@Windows.s, 256)
RunProgram("iexplore.exe", "http://www.google.com", Windows.s)
Just an FYI, you don't want to run internet explorer, you would want to run explorer. You also would want to run explorer instead of start. Examples in Pseudocode:

RunProgram "explorer.exe" "http://whatever.com"
RunProgram "explorer.exe" "whatever.bmp"
RunProgram "explorer.exe" "whatever.wav"
Karbon
PureBasic Expert
PureBasic Expert
Posts: 2010
Joined: Mon Jun 02, 2003 1:42 am
Location: Ashland, KY
Contact:

Post by Karbon »

I didn't say it was a bug - it's a "gotcha" - something to keep in mind! :-)

Use ShellExecute_() if you want to open the default browser, though, even on Win98..
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Post by PB »

> I didn't say it was a bug

I was just responding to your comment of "I'm not sure if this is any kind of bug" by replying that it isn't, that's all. ;)
Karbon
PureBasic Expert
PureBasic Expert
Posts: 2010
Joined: Mon Jun 02, 2003 1:42 am
Location: Ashland, KY
Contact:

Post by Karbon »

"Unsupported feature" we'll call it :-)
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
Post Reply