Results 1 to 3 of 3

Thread: vb6; Get data from a website.

  1. #1

    Thread Starter
    New Member
    Join Date
    Jun 2009
    Posts
    2

    vb6; Get data from a website.

    Hello.
    I will make a program so when i have an item. It shall update the price from the website. Also i have created a program with Intel cpu. When i use the combo box and choose than, then it shall show the price in a text box. Is it possible to get the price from the homepage and transfer it to the textbox?



    -Ahlmo

  2. #2
    "Digital Revolution"
    Join Date
    Mar 2005
    Posts
    4,471

    Re: vb6; Get data from a website.

    Not sure I understand exactly...

    First, you need a way to get the webpage's HTML code. You can use the Inet control, Winsock control, API functions, web browser control, etc.

    The easiest and most straightforward would probably be the Inet control.

    Press CTRL+T in VB to bring up the Components window. Find, and select "Microsoft Internet Transfer Control". Click OK, and then add the Inet control to your form. It should have a name of "Inet1".

    Then you can get the HTML of a webpage with something like:

    vb Code:
    1. 'In a command button
    2. Private Sub Command1_Click()
    3.     Dim strHTML As String
    4.  
    5.     strHTML = Inet1.OpenURL("http://www.URLToWebpage.com")
    6.     Debug.Print strHTML 'Show HTML in immediate/debug window
    7. End Sub

    From there, you can use string manipulation (functions such as: Left$(), Right$(), Mid$(), InStr(), InStrRev(), etc.) to extract out the information you need.

    If you post the URL to the page and tell us what information you want to extract, we can probably help...

  3. #3

    Thread Starter
    New Member
    Join Date
    Jun 2009
    Posts
    2

    Re: vb6; Get data from a website.

    Okay.
    Here: http://www.komplett.dk/k/ki.aspx?sku=393886
    I want to have this price updated, when they change: 849,-

    Also, if they change to 800,- then the program shall change the price to 800,-

    That's i mean

    And when i have you:

    Is it possible to make a "Search function"
    Also if i add a motherboard, and i tell it, just take memory, who is ddr2 ram, can it be possible? Maybe try to pm me your msn (;:

    Ty for helping.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width