Need help with my rs client

Discussion in 'Programming General' started by hailmatt69, Dec 21, 2007.

Need help with my rs client
  1. Unread #1 - Dec 21, 2007 at 5:38 PM
  2. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs client

    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.
     
  3. Unread #2 - Dec 21, 2007 at 6:54 PM
  4. slashshot007
    Joined:
    May 6, 2006
    Posts:
    164
    Referrals:
    0
    Sythe Gold:
    0

    slashshot007 Active Member

    Need help with my rs client

    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
     
  5. Unread #3 - Dec 21, 2007 at 7:36 PM
  6. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs client

    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?
     
  7. Unread #4 - Dec 21, 2007 at 8:28 PM
  8. slashshot007
    Joined:
    May 6, 2006
    Posts:
    164
    Referrals:
    0
    Sythe Gold:
    0

    slashshot007 Active Member

    Need help with my rs client

    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.
     
  9. Unread #5 - Dec 22, 2007 at 1:14 AM
  10. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs 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.
     
  11. Unread #6 - Dec 22, 2007 at 10:18 AM
  12. rattytatt50
    Joined:
    Oct 26, 2007
    Posts:
    67
    Referrals:
    0
    Sythe Gold:
    0

    rattytatt50 Member

    Need help with my rs client

    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.
     
  13. Unread #7 - Dec 22, 2007 at 3:42 PM
  14. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs client

    does the browser have to be within the panal for this to work?
     
  15. Unread #8 - Dec 22, 2007 at 4:51 PM
  16. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs client

    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?
     
  17. Unread #9 - Dec 23, 2007 at 7:43 AM
  18. rattytatt50
    Joined:
    Oct 26, 2007
    Posts:
    67
    Referrals:
    0
    Sythe Gold:
    0

    rattytatt50 Member

    Need help with my rs client

    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
     
  19. Unread #10 - Dec 23, 2007 at 7:46 AM
  20. rattytatt50
    Joined:
    Oct 26, 2007
    Posts:
    67
    Referrals:
    0
    Sythe Gold:
    0

    rattytatt50 Member

    Need help with my rs client

    and by the way, check if you didnt disable java
     
  21. Unread #11 - Dec 23, 2007 at 9:50 AM
  22. slashshot007
    Joined:
    May 6, 2006
    Posts:
    164
    Referrals:
    0
    Sythe Gold:
    0

    slashshot007 Active Member

    Need help with my rs client

    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.
     
  23. Unread #12 - Dec 23, 2007 at 1:07 PM
  24. hailmatt69
    Joined:
    Mar 10, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    hailmatt69 Member

    Need help with my rs client

    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.


    I've fixed the scrollbar problem thanks.
     
  25. Unread #13 - Dec 24, 2007 at 6:48 AM
  26. rattytatt50
    Joined:
    Oct 26, 2007
    Posts:
    67
    Referrals:
    0
    Sythe Gold:
    0

    rattytatt50 Member

    Need help with my rs client

    Have you tried googling?
     
  27. Unread #14 - Dec 24, 2007 at 1:17 PM
  28. slashshot007
    Joined:
    May 6, 2006
    Posts:
    164
    Referrals:
    0
    Sythe Gold:
    0

    slashshot007 Active Member

    Need help with my rs client

    he said he fixed the problem
     
< Can't compile... | notepad++ download (sorry if wrong place) >

Users viewing this thread
1 guest


 
 
Adblock breaks this site