• Log in or sign up for an account here: https://www.sythe.org/login

Need help with my rs client

hailmatt69

Member
Joined
Mar 10, 2007
Sythe Gold
0
Messages
85
Location
Canada
I have programed the app with all the world prefixes, but when I click the button to navigate to the world, The webrowser just loads the runescape main page.

Is there another bit of code I need to put in first to avoid this? Thanks for any help.
 
yeah:
Code:
    Private Sub rsscreen_Navigating(ByVal sender As Object, ByVal e As System.Windows.Forms.WebBrowserNavigatingEventArgs) Handles f2pbrowser.Navigating, p2pbrowser.Navigating
        e.Cancel = (e.Url.ToString.ToLower.Replace("www.", Nothing) = "http://runescape.com/")
    End Sub
 
It doesnt work, still loads to the main screen. Do I need two different browsers? one for f2p, and one for p2p, wat are those for in your code after Handles?
 
don't worry about it just change the handle for your webbrowser i was in a rush, so i just copied and pasted it from my client.
 
ok it works, srry i got a few more questions..
1)My web browser gets scroll bars, and I don't want these here... I have made the ScrollBarsEnabled value false, but they still show? how do I get rid of them.
2)The java box for the game isnt loading correctly in my program, it just stays as a large gray box and doesn't load.. Is this because I am just debugging the program?

Thanks for any help.
 
Use StealRS2 - i give you code but its slightly flawed (youll come accross it, but dont worry) it still works.

Make a new class and call it StealRS2, then put in this code.
Code:
Module StealRS2
    Private Declare Auto Function FindWindowEx Lib "user32" (ByVal parentHandle As IntPtr, _
                       ByVal childAfter As IntPtr, _
                       ByVal lclassName As String, _
                       ByVal windowTitle As String) As IntPtr
    Private Declare Auto Function SetParent Lib "user32" (ByVal hWndChild As IntPtr, _
                      ByVal hWndNewParent As IntPtr) As IntPtr
    Declare Auto Function SetWindowPos Lib "user32" (ByVal hWnd As IntPtr, _
                      ByVal hWndInsertAfter As IntPtr, _
                      ByVal X As Integer, _
                      ByVal Y As Integer, _
                      ByVal cx As Integer, _
                      ByVal cy As Integer, _
                      ByVal uFlags As UInteger) As Boolean

    Sub Steal(ByVal FormHandle As IntPtr, ByVal WBHandle As IntPtr)
        On Error Resume Next
        Dim RSHwnd As IntPtr, RSSunJava As IntPtr, RSSunJava6 As IntPtr
        RSHwnd = FindWindowEx(WBHandle, 0&, "shell embedding", "")
        RSHwnd = FindWindowEx(RSHwnd, 0&, "shell docobject view", "")
        RSHwnd = FindWindowEx(RSHwnd, 0&, "internet explorer_server", "")
        RSSunJava = FindWindowEx(RSHwnd, 0&, "Java Plug-in Control Window", "")
        RSSunJava6 = FindWindowEx(RSSunJava, 0&, "SunAwtFrame", "")
        RSSunJava = FindWindowEx(RSSunJava, 0&, "sun.plugin.viewer.frame.IExplorerEmbeddedFrame", "")
        RSHwnd = FindWindowEx(RSHwnd, 0&, "microsoft vm for java(tm) host window class", "")
        RSHwnd = FindWindowEx(RSHwnd, 0&, "msawt_comp_class", "")
        If (RSSunJava = 0) Then RSSunJava = RSSunJava6
        If (RSHwnd = 0) Then RSHwnd = RSSunJava
        If (RSHwnd = 0) Then Exit Sub
        SetParent(RSHwnd, FormHandle)
        SetWindowPos(RSHwnd, New IntPtr(0), 0, 0, 0, 0, &H200 Or &H1)
    End Sub
End Module

Then on your main form put a panel and a webbrowser. put the webbrowser into the form and go to the progresschanged event of your webbrowser1 and put in this code.
Code:
 Private Sub WebBrowser1_ProgressChanged(ByVal sender As Object, ByVal e As System.Windows.Forms.WebBrowserProgressChangedEventArgs) Handles WebBrowser1.ProgressChanged
        Steal(Panel1.Handle, WebBrowser1.Handle)
    End Sub

And by the way check your URLS or your environment paths. Go to start menu -> right click my computer -> properties -> advanced -> environment variables -> classpath -> edit. My url for this is: C:\Program Files\Java\jre1.6.0_02\lib\ext\QTJava.zip. Update your java if neccisary. Dont change that (<-<-) if you dont want to. Its better to check for updates.
 
I still can't get it to work, I still get the gray screen, but after trying it a few times a get he runescape cache error. I've been having this problem with eliteswitch aswell though, so would it be something to do with my java? I just updated it and still get the grey screen any suggestions?
 
its ur java then. Have u got the latest update?

Woops didnt read.
go into ur environment settings and head down to QTJAVA, edit that and put in this for the path - C:\Program Files\Java\jre1.6.0_01\lib\ext\QTJava.zip. That is for the JRE1.6.0 version of java (mine) it depends on yourjava version, if you got that version then it shud work
 
yeah, i never used stealrs2, because i could never understand what it actually did, and i hate leechers, so i would just resize the browser so there was no scrollbars, and moved the part where ad was above the top of the form.

however know it seems to make sense and i might make a new client that usese stealrs2, if i do, which probably won't happen.
 
Go into ur environment settings and head down to QTJAVA, edit that and put in this for the path - C:\Program Files\Java\jre1.6.0_01\lib\ext\QTJava.zip. That is for the JRE1.6.0 version of java (mine) it depends on yourjava version, if you got that version then it shud work
I tryed this, and it didn't change anything. But I found I was able to get the browser to work with an unsigned applet, but I don't want this.


yeah, i never used stealrs2, because i could never understand what it actually did, and i hate leechers, so i would just resize the browser so there was no scrollbars, and moved the part where ad was above the top of the form.
I've fixed the scrollbar problem thanks.
 
Back
Top