RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

.net's built in webbrowser

Zaphieon

Wanderer
.net's built in webbrowser

been trying to figure out a way to call the build in webbrowser using an ondoubleclick from ingame instead of the Launch Browser. I want to use the built in browser becuase its limited to its uses compare to the players default browser. I haven't got this to work yet though.. is it possible to do??
 

Jeff

Lord
Zaphieon;764107 said:
been trying to figure out a way to call the build in webbrowser using an ondoubleclick from ingame instead of the Launch Browser. I want to use the built in browser becuase its limited to its uses compare to the players default browser. I haven't got this to work yet though.. is it possible to do??

Uhh, I think you are confused, Launch Browser sends a packet that tells the client to load the clients default browser to a site, there is no built in browser.
 

Zaphieon

Wanderer
yeah bud theres a built in browser in the .net system.. found some info on it.. its a basic barebones browser.. you can script in address bars and what not.. but I was looking to get it just to pop up.. not talking about the launchbrowser that calls the default browser.. heres a link to a site talking about it.. theres tons out there.. wish i would have bookmarked the official .net sites info on it..

click here
 

mordero

Knight
It doesnt work that way. If you are using the UO client and you launch the browser, it launches the default one. When you "script" for RunUO, thats all server side; none of your code is being sent to the user as .net code. So, Jeff is right.
 

Zaphieon

Wanderer
i am not talking about using a the LaunchBrowser command.. talking about using the print command for the internal webbrowser. its in the .net software... and i believe everyone using razor has that on there pc yes? I was thinking though.. maybe something easier would be just to script a new browser that they have to install instead.. call the program through a script to open it directly, that might be easier to do what i am looking for.
 

majorcomet

Wanderer
As was noted above, the .NET browser control cannot be used in this case, unless what you want is to open the browser window on your SERVER, since that's where the code is running.

On the client, it's not even .NET code you are interacting with - it's a plain-old Win32 binary. You cannot 'script' the client from the server (and in fact, the UO client can't really be 'scripted' at all, beyond the simple macros built in.) The packet referenced above to get the client to open the user's own web browser is the only way to really do what you want here, without having to have external software involved.

So you mentioned the solution yourself, if you absolutely need to do this; Force your players to download a separate program that you write in .NET, and have that program somehow open or view the page you want to display.

But it would probably just be much easier just to use the uo client's built in browser opening functionality, and just make the page you are pointing to compatible with all the major browsers, so you don't need to box your players into needing a particular browser.

...

Also, just for the record; the 'built in' .NET web browser control is actually just whatever current version of Internet Explorer the user has installed, without the normal chrome of the browser. The control is used in a Windows Forms program to implement a browser within the program. It is not a standalone web browser on it's own.
 

Zaphieon

Wanderer
from what i have read it is not a form of the IE browser installed.. but hey I could be wrong


the easist way to get what i want would def. be a standalone browser... I am looking for something I can control a bit more appearance wise, as well as launching the program I want to be able to shut it down from within the game. I want it too look more like how shadowbox comes up.. with no edges at all.. just a floating box. that will centered not really full screen about 300x400.. and when trying to access this without interacting with in the game it comes up with a page that says sorry this cannot be accessed directly. at anyrate thnx for all the input though =P.. wish me luck. lol never did anything like this before but there is tons of info about it out there so shouldnt be to hard.
 

Jeff

Lord
Zaphieon;766460 said:
from what i have read it is not a form of the IE browser installed.. but hey I could be wrong


the easist way to get what i want would def. be a standalone browser... I am looking for something I can control a bit more appearance wise, as well as launching the program I want to be able to shut it down from within the game. I want it too look more like how shadowbox comes up.. with no edges at all.. just a floating box. that will centered not really full screen about 300x400.. and when trying to access this without interacting with in the game it comes up with a page that says sorry this cannot be accessed directly. at anyrate thnx for all the input though =P.. wish me luck. lol never did anything like this before but there is tons of info about it out there so shouldnt be to hard.

What you want is impossible, you cant display html pages inside UO, and no one is going to install a custom piece of software just for you to launch a browser on their computer......., the only thing you can do is launch the persons browser from inside UO.......
 

Zaphieon

Wanderer
done with the special "browser/program" they will have to download, Ill script in special stones that will launch this browser. using

System.Diagnostics.Process.Start();

and I believe theres a kill command as well. to close the window.

 

mordero

Knight
These in-game stones cannot interact with anything on the client's computer. Any .Net programming you do in server-side scripts will only effect things on the server side, not the client side. So your program will either a) have to monitor the opening of the default browser whenever UO is open, somehow check to see if it is opening your page, stop it from opening and then open its own browser or b) convince the user to make your program the default browser.
 

Zaphieon

Wanderer
going to test my script tonight if i finish it.. but heres the call method..


System.Diagnostics.Process.Start("C:/dduoweb.application",http://darkdays.zrockonline.net/test.html);

there for all they will have to do is download the 5kb app drop it under there C:/ and it will call it.. from what i have been playing with this should work just fine.

no need to make it the default browser using script in game it will open it, then will have a close method built in as well once i am done.
 

Jeff

Lord
Zaphieon;766512 said:
going to test my script tonight if i finish it.. but heres the call method..


System.Diagnostics.Process.Start("C:/dduoweb.application",http://darkdays.zrockonline.net/test.html);

there for all they will have to do is download the 5kb app drop it under there C:/ and it will call it.. from what i have been playing with this should work just fine.

no need to make it the default browser using script in game it will open it, then will have a close method built in as well once i am done.


System.Diagnostics.Process.Start("C:/dduoweb.application",http://darkdays.zrockonline.net/test.html);

will start on the server not the client..... why the fuck are you not fucking listening to us..... jesus fucking christ....its probably because your a ginger....
 

Zaphieon

Wanderer
Jeff;766513 said:
System.Diagnostics.Process.Start("C:/dduoweb.application",http://darkdays.zrockonline.net/test.html);

will start on the server not the client..... why the fuck are you not fucking listening to us..... jesus fucking christ....its probably because your a ginger....



sorry but as smart as you are bud.. I dont see how you can not understand this.. if process.start - started the process on the servers side not the clients them launchbrowser wouldnt work.. but thats all that command is - theres a way to do it.. just like starting the default browser with Launchbrowser, you can start other shit on someones pc... instead of trying to insult people, & trying to say something is impossible.. why dont you use that big brain of yours and fix your software bud. because right now your being a jackass.
 

Zaphieon

Wanderer
well got it working.. somewhat.. It is starting up on the clients side(( not on the server machine *wink* )), but my URL is not sending through correctly.. must have missed something on the browser end of it. and currently dont have a close method scripted into the program or server.. oh well will have to wait tell sunday to mess with everyone have a good 4th of july.
 
Top