+ Reply to Thread
Results 1 to 4 of 4

Importing csv data into worksheet from the web

  1. #1
    Registered User
    Join Date
    05-06-2004
    Posts
    60

    Importing csv data into worksheet from the web

    Hello,

    I am having trouble importing comma delimited data into a worksheet using a form. Below is how my code works. I have a textbox, which dependent upon what is entered, will later be tacked on to the end of a url address that will pull up comma delimited data. I've made it this far, but have no idea how to import that information into a sheet named "Data". Is it possible to do this ? if so, is it possible to have this done in the background invisible to the user?

    Here's what I have so far:

    Private Sub CommandButton6_Click()

    With Application
    .Calculation = xlManual
    End With
    ActiveWorkbook.PrecisionAsDisplayed = False
    With Application
    Dim r As Long
    Dim ws1 As Worksheet
    Set ws1 = Worksheets("SNEM")
    r = ws1.Cells(Rows.Count, 1).End(xlUp).Offset(0, 1).Row
    ws1.Range("B" & r).Value = Segm.Value
    ws1.Range("C" & r).Formula = "=RC[-2]&RC[-1]"
    ws1.Range("D" & r).Formula = "=HYPERLINK(RC[-1])"

    If ws1.Range("B" & r).Value > 0 Then
    ws1.Range("A" & r).Value = "http://www.geo.sbc.com/scripts/fnp/export/csv_content.asp?SEGMENT="
    Else
    ws3.Range("A" & r).Value = ""
    End If
    .Calculation = xlCalculationManual
    Application.ScreenUpdating = False
    Application.Visible = False
    .ScreenUpdating = False
    End With
    Call getsnem
    End Sub

    (call getsnem follows the hyperlink, which opens internet explorer and pulls the data.....also, the url above is incorrect for security reasons)


    Thanks,

    Oreg

  2. #2
    Registered User
    Join Date
    05-06-2004
    Posts
    60

    Importing csv data into worksheet from the web

    Still can't figure this out. Any ideas ???

  3. #3
    Tom Ogilvy
    Guest

    Re: Importing csv data into worksheet from the web

    since all the specifics are a secret, maybe you just need to do a search on
    this newgroup in google and see if you can find some code to help you out.
    http://groups.google.com/advanced_search?hl=en

    --
    Regards,
    Tom Ogilvy


    "Oreg" <[email protected]> wrote in message
    news:[email protected]...
    >
    > Hello,
    >
    > I am having trouble importing comma delimited data into a worksheet
    > using a form. Below is how my code works. I have a textbox, which
    > dependent upon what is entered, will later be tacked on to the end of a
    > url address that will pull up comma delimited data. I've made it this
    > far, but have no idea how to import that information into a sheet named
    > "Data". Is it possible to do this ? if so, is it possible to have this
    > done in the background invisible to the user?
    >
    > Here's what I have so far:
    >
    > Private Sub CommandButton6_Click()
    >
    > With Application
    > Calculation = xlManual
    > End With
    > ActiveWorkbook.PrecisionAsDisplayed = False
    > With Application
    > Dim r As Long
    > Dim ws1 As Worksheet
    > Set ws1 = Worksheets("SNEM")
    > r = ws1.Cells(Rows.Count, 1).End(xlUp).Offset(0, 1).Row
    > ws1.Range("B" & r).Value = Segm.Value
    > ws1.Range("C" & r).Formula = "=RC[-2]&RC[-1]"
    > ws1.Range("D" & r).Formula = "=HYPERLINK(RC[-1])"
    >
    > If ws1.Range("B" & r).Value > 0 Then
    > ws1.Range("A" & r).Value =
    > "http://www.geo.sbc.com/scripts/fnp/export/csv_content.asp?SEGMENT="
    > Else
    > ws3.Range("A" & r).Value = ""
    > End If
    > Calculation = xlCalculationManual
    > Application.ScreenUpdating = False
    > Application.Visible = False
    > ScreenUpdating = False
    > End With
    > Call getsnem
    > End Sub
    >
    > (call getsnem follows the hyperlink, which opens internet explorer and
    > pulls the data.....also, the url above is incorrect for security
    > reasons)
    >
    >
    > Thanks,
    >
    > Oreg
    >
    >
    > --
    > Oreg
    > ------------------------------------------------------------------------
    > Oreg's Profile:

    http://www.excelforum.com/member.php...fo&userid=9195
    > View this thread: http://www.excelforum.com/showthread...hreadid=475680
    >




  4. #4
    Registered User
    Join Date
    05-06-2004
    Posts
    60

    Importing csv data into worksheet from the web

    Hi Tom,

    Thanks for the response. I will try the newsgroup you provided for solutions. I sent you a private message with the full address if that will help.

    Thanks again.

    Oreg

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1