Results 1 to 2 of 2
  1. #1
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    userform modify... (2000 sr 1)

    i havce modified the old userform to make a simple data entry...
    if i have understand the routine updatae (with overwrite) the cells into range 1 to 8....
    i spossible inseted this range updating only the column L, M, AB, AI...

    Private Sub CommandButton4_Click()

    Dim RIGA As String

    RIGA = ScrollBar1.Value

    For I = 1 To 8
    Sheets(1).Cells(RIGA, I).Value = UserForm1.Controls("TextBox" & I).Text
    Next

    For I = 1 To 8
    UserForm1.Controls("TextBox" & I).Text = Sheets(1).Cells(2, I).Value
    Next

    MsgBox "MODIFICA EFFETTUATA!"

    End Sub

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: userform modify... (2000 sr 1)

    Don't use the loop For I = 1 To 8. Instead, use a separate line for each column:

    Sheets(1).Cells("L" & RIGA).Value = UserForm1.TextBox1.Text
    Sheets(1).Cells("M" & RIGA).Value = UserForm1.TextBox2.Text
    ...

Posting Permissions

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