469,270 Members | 1,164 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,270 developers. It's quick & easy.

C# starting Opera process

I want to start in C# a process of Opera web browser with a given URL.
I'm using Windows Mobile 5 and Opera 9.5 Beta
Ive tried the following code (working of Internet Explorer)
Expand|Select|Wrap|Line Numbers
  1. System.Diagnostics.Process proc = new System.Diagnostics.Process();
  2. proc.StartInfo.FileName = "iexplore";
  3. proc.StartInfo.Arguments = "http://www.google.com";
  4. proc.Start();
I've tried to change "iexplore" in "opera" or "opera.exe" but no success at all.
Can you please give me a hand?
Dec 4 '08 #1
7 5559
PRR
750 Expert 512MB
Expand|Select|Wrap|Line Numbers
  1. Process.Start("firefox.exe", "http://www.google.com");
  2. //or specify path
  3. //Process.Start(@"C:\Program Files\Mozilla Firefox\firefox.exe", "http://www.google.com");
  4.  
  5. //OR 
  6. ProcessStartInfo ind = new ProcessStartInfo("firefox.exe", "http://www.google.com");
  7. //ProcessStartInfo ind = new ProcessStartInfo(@"C:\Program Files\Mozilla Firefox\firefox.exe", "http://www.google.com");
  8.   Process.Start(ind);
  9.  
  10.  
Dec 4 '08 #2
Curtis Rutland
3,256 Expert 2GB
The method you are using is correct, but the file names your are using seem to be wrong.

You're going to have to find the path and name of the executable file and use the full path and name.
Dec 4 '08 #3
Frinavale
9,735 Expert Mod 8TB
@insertAlias
By default, the path to the Opera browser is:

C:\Program Files\Opera\opera.exe
Dec 4 '08 #4
Plater
7,872 Expert 4TB
@Frinavale
So then on a mobile device it would probably be
\Program Files\Opera\opera.exe
Dec 4 '08 #5
Curtis Rutland
3,256 Expert 2GB
Moved to Mobile Development.
Dec 4 '08 #6
Frinavale
9,735 Expert Mod 8TB
@Plater
Aha! Good catch Plater :)
Dec 4 '08 #7
markmcgookin
648 Expert 512MB
I wondered where this post came from, just realised you moved it. Did the above solution of kicking off the \Program Files\Opera\Opera.exe work?
Dec 4 '08 #8

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

7 posts views Thread by barry womb | last post: by
4 posts views Thread by Howard Jess | last post: by
43 posts views Thread by Christoph Schneegans | last post: by
5 posts views Thread by Marri | last post: by
8 posts views Thread by cypher543 | last post: by
1 post views Thread by kevin.a.sweeney | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.