Problem with staying logged in on webbrowser.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Dave Siegel
    New Member
    • Feb 2007
    • 42

    Problem with staying logged in on webbrowser.

    Hey,

    I made a webbrowser for a game, but when you login and then open another form with another webbrowser inside of it, it's logged out on that one. Any idea how to fix that?

    I'm using Vb6

    Cheers
  • Dököll
    Recognized Expert Top Contributor
    • Nov 2006
    • 2379

    #2
    Originally posted by Dave Siegel
    Hey,

    I made a webbrowser for a game, but when you login and then open another form with another webbrowser inside of it, it's logged out on that one. Any idea how to fix that?

    I'm using Vb6

    Cheers
    Hello, Dave!

    Are you setting one browser to close in order for the next to open?
    Perhaps you need to have one browser for both/all forms, just a hunch...

    I pulled up the below for you. You'll have to do some reading. I think what you need in towards mid portion of the page "switching browsers":

    vbCity is a community of VB and .NET developers joined together with a common goal: to learn, teach, and have fun programming. Developers from all over the world come together to share knowledge, source code, and tutorials for free to help their fellow programmers - Professional Developers, Hobbyists and Students alike. (http://vbCity.com)


    Also, you should post what you have working for a closer look.

    Sorry for your troubles.

    Dököll

    Comment

    • Dave Siegel
      New Member
      • Feb 2007
      • 42

      #3
      What im trying to do is the following.

      When you're logged in and you go to the page

      http://faketown.com/scripts/swf/user.php?action =getProfile

      You get info like how much credits etc he/she has.
      But when im using a 2nd webbrowser right now the 2nd window isnt logged in. So it only shows the information of the guest login.

      I'm trying to make a grab page to grab the userinfo, but if it isnt logged in on the 2nd webbrowser then it doesnt grab it.

      What to do?

      Comment

      • Dököll
        Recognized Expert Top Contributor
        • Nov 2006
        • 2379

        #4
        Originally posted by Dave Siegel
        What im trying to do is the following.

        When you're logged in and you go to the page



        You get info like how much credits etc he/she has.
        But when im using a 2nd webbrowser right now the 2nd window isnt logged in. So it only shows the information of the guest login.

        I'm trying to make a grab page to grab the userinfo, but if it isnt logged in on the 2nd webbrowser then it doesnt grab it.

        What to do?
        Couldn't you maintain only one browser

        I was hoping to point you having just one for all instances.

        I did some more snooping around, this because it seems you're comfortable with your code as written, the link provided has some sample code that also help switch from different browsers:

        Code:
        Private Sub Command1_Click()
           If Option1.Item(0) Then
              WebBrowser1.Navigate Text1.Text
           Else
              WebBrowser2.Navigate Text1.Text
           End If
        End Sub
        
        Private Sub Option1_Click(Index As Integer)
           Select Case Index
              Case 0
                 WebBrowser.Visible = True
              Case 1
                 WebBrowser.Visible = False
           End Select
        End Sub
        Again, I do not know what your code looks like, but you shoul be able to tell VB grab user info for either browser (the available browser). I am now beginning with Browser functions, I would stay tuned in case other members have other ideas.

        Did you read through the link?

        Here is a somewhat related link, wanted to post in case useful for later purpose:

        Last edited by Dököll; May 20 '07, 03:11 PM. Reason: Added question

        Comment

        Working...