View Single Post
Old 03-30-2008, 12:44 PM   #2 (permalink)
daat99
RunUO Forum Moderator
 
daat99's Avatar
 
Join Date: Dec 2004
Location: Israel
Age: 27
Posts: 8,163
Send a message via ICQ to daat99 Send a message via AIM to daat99
Default

Quote:
Originally Posted by Scriptiz View Post
Hello,

I'm trying to "control" firefox via a C# program. Is it possible?

Actually I can just start the Process firefox.exe but then I don't know how to change the Url of this process, how to get the Url, get the html source code of the actually visited page in this firefox process, ...

Can you help me? Is it a way to do that? I hope


ps: I'm french so excuse my poor English.
ps2: I went for 5days so I'll read your answers in only 5days
1. To open Firefox in a specific URL you can just pass the url as a parameter to Firefox (run this in Start->Run: "firefox.exe http://www.runuo.com/forums/c/89428-control-firefox-c.html#post747059")

2. It's very likely that there is a lot better and easier way then this! but...
To get the source code you can "create" your own c# web explorer.
There should be a c# library that can "open" a url and "download" the source code so it can be displayed on the screen (look at ConnectUO or many other c# applications that integrate a small web browser into them).
__________________
I always try to help
Sometimes, I don't know how....

My Web Page
Forum Rules
-------------------------------------------------------------
Extensive OWLTR System | Token System | World Teleporters
-------------------------------------------------------------
daat99 is offline   Reply With Quote