1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

I need help!!

Discussion in 'Visual Basic .NET' started by korfx04, Apr 28, 2010.

  1. korfx04

    korfx04 Junior Member

    Joined:
    Feb 27, 2009
    Messages:
    152
    Likes Received:
    96
    I'm working on a bot called reddit rabbit, what it does is submit your articles are whatever to reddit.com and once it submits, it will logout/in into another account with proxy and up vote what you submitted at random intervals. It's does this until it reaches the end of your username & password list then it will submit another article or w/e..

    If you have 1000 usernames for reddit, the program will up vote w/e your submitted to reddit 1000 times before continuing. Everything works fine and dandy, but right now i have 2 listboxes 1 for usernames and one for passwords, but i want to be able just to use one listbox for both username and passwords. So it will look like this Username:password


    Do you know how this can be done?
     
  2. crashed

    crashed Jr. VIP Jr. VIP Premium Member

    Joined:
    Aug 13, 2008
    Messages:
    958
    Likes Received:
    1,198
    Occupation:
    Guru-slayer
    Location:
    Behind the VPN...
    Home Page:
    Where are you loading the username password from?

    It's pretty simple to split a string in .net

    Code:
    Dim parts As String() = line.Split(New Char() ":")
    ' username = parts(0)
    ' password = parts(1)
    
     
  3. korfx04

    korfx04 Junior Member

    Joined:
    Feb 27, 2009
    Messages:
    152
    Likes Received:
    96
    Thats not working.
    Dim parts As String() = line.Split(New Char() ":")


    error
    Code:
    Error    1    Comma, ')', or a valid expression continuation expected.    C:\Users\Chris\Documents\Visual Studio 2010\Projects\Rabbit Reddit\Rabbit Reddit\rr.vb    53    57    Rabbit Reddit
    
    Then the i add comma i get
    Dim parts As String() = line.Split(New Char(), ":")


    Code:
    Error    1    'Line' statements are no longer supported. File I/O functionality is available as 'Microsoft.VisualBasic.FileSystem.Line Input' and the graphics functionality is available as 'System.Drawing.Graphics.DrawLine'.    C:\Users\Chris\Documents\Visual Studio 2010\Projects\Rabbit Reddit\Rabbit Reddit\rr.vb    53    35    Rabbit Reddit
    
    Imports System.IO
     
  4. crashed

    crashed Jr. VIP Jr. VIP Premium Member

    Joined:
    Aug 13, 2008
    Messages:
    958
    Likes Received:
    1,198
    Occupation:
    Guru-slayer
    Location:
    Behind the VPN...
    Home Page:
    Try

    Code:
    Dim parts As String() = line.Split(New Char() {":"})
     
  5. korfx04

    korfx04 Junior Member

    Joined:
    Feb 27, 2009
    Messages:
    152
    Likes Received:
    96
    none of the above worked but i took it and done it like this

    Code:
     
                Dim line As String
                Dim parts() As String
                line = usernames.SelectedItem
                parts = line.Split(":")
    
                WebBrowser1.Document.GetElementById("user_login").Focus()
                WebBrowser1.Document.GetElementById("user_login").InnerText = parts(0)
    
                WebBrowser1.Document.GetElementById("passwd_login").Focus()
                WebBrowser1.Document.GetElementById("passwd_login").InnerText = parts(1)
    
    
    and it worked... lol