Results 1 to 4 of 4

Thread: [RESOLVED] Pulling from a text document, yet no value?

Threaded View

  1. #1

    Thread Starter
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Resolved [RESOLVED] Pulling from a text document, yet no value?

    I am trying to pull 3 different values from a text document in the format of
    1 value per line.
    IE) 6
    19
    6/12/2005

    It pulls the first and last values out, but I seems to refuse to pull out the middle value.

    my code is as follows

    VB Code:
    1. Private Sub Form_Load()
    2. Dim DatesLength As Integer
    3. Open "H:\JOB\Dates.txt" For Input As #1
    4. PayIncreaseComboBox.Value = Input(2, #1)
    5. ShowLabels
    6. Dim ctl As Control
    7. For Each ctl In Me.Controls
    8. If ctl.Visible = True Then
    9.     If ctl.Name Like "DTPicker*" Then
    10.         DatesLength = Val(Input(2, #1))
    11.         MsgBox (DatesLength)
    12.         ctl.Value = Input(DatesLength, #1)
    13.     End If
    14. End If
    15. Next
    16. Close #1
    17. End Sub


    Anyone have any ideas?
    Last edited by kfcSmitty; May 19th, 2005 at 07:31 AM.

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