LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 01-29-2013, 08:41 PM   #1
DrDwayne
Member
 
Registered: May 2010
Location: Wichita
Distribution: Ubuntu Debian
Posts: 87

Rep: Reputation: 0
Calling a Shell in Linux Wine. . .From a Windows Program


I have a program that calls a shell, to access the internet in windows. the command is:

ShellExecute(NULL, "open", "www.qrz.com", "", NULL, SW_RESTORE);

What this does, is shell out of a windows program, opens up firefox, puts WWW.qrz.com in the url, and goes to the site.

When I install my program in Wine and run this command, nothing happens.

I would like wine to load up the browser, insert the URL, and go to it.

Any help in this arena?

Dwayne
 
Old 01-30-2013, 11:09 AM   #2
Habitual
Senior Member
 
Registered: Jan 2011
Distribution: Undecided
Posts: 3,569
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by DrDwayne View Post
I have a program that calls a shell, to access the internet in windows. the command is:

ShellExecute(NULL, "open", "www.qrz.com", "", NULL, SW_RESTORE);

What this does, is shell out of a windows program, opens up firefox, puts WWW.qrz.com in the url, and goes to the site.

When I install my program in Wine and run this command, nothing happens.

I would like wine to load up the browser, insert the URL, and go to it.

Any help in this arena?

Dwayne
Dwayne:
Try
Code:
ShellExecute(NULL, "open", "http://www.qrz.com", "", NULL, SW_RESTORE);
or possibly
Code:
ShellExecute(NULL, "open", "firefox http://www.qrz.com", "", NULL, SW_RESTORE);
 
Old 01-30-2013, 09:29 PM   #3
DrDwayne
Member
 
Registered: May 2010
Location: Wichita
Distribution: Ubuntu Debian
Posts: 87

Original Poster
Rep: Reputation: 0
Thank you very much. . .I have tried both, and they still do not work. . .

I am trying to shell out of Linux wine to call the browser.
 
Old 01-31-2013, 05:54 AM   #4
millgates
Member
 
Registered: Feb 2009
Location: 192.168.x.x
Distribution: Slackware
Posts: 651

Rep: Reputation: 269Reputation: 269Reputation: 269
Do you have a browser installed in wine?
 
Old 02-03-2013, 08:48 PM   #5
DrDwayne
Member
 
Registered: May 2010
Location: Wichita
Distribution: Ubuntu Debian
Posts: 87

Original Poster
Rep: Reputation: 0
Finally solved it. . .

I posted earlier on this, and finally solved it. . .

ShellExecute(NULL, "open", "www.qrz.com", "", NULL, SW_RESTORE);

*is* the correct working call. . .

Difference? Wine 1.2 will NOT work. ..I upgraded to 1.3 (I thought I had the latest, but I didn't). and now the command works like a charm.

Thank you all very much for posting help on this problem! It was a blessing.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Error calling a windows program using wine nightrider Suse/Novell 6 07-13-2012 12:54 PM
[SOLVED] calling linux program from wine fachamix Linux - Software 1 11-30-2009 10:11 AM
Wine installed a program onto my windows partition, Windows BSOD on boot. DJGCrusader Linux - Enterprise 9 08-14-2009 09:25 AM
Problem calling linux program from Java spasco Programming 3 04-25-2004 01:13 AM
C program code calling a Linux system command Linh Programming 1 06-05-2003 02:44 PM


All times are GMT -5. The time now is 02:20 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration