+ Reply to Thread
Results 1 to 4 of 4

Copy TextBox data to Worksheet in specific range

  1. #1
    Forum Contributor
    Join Date
    04-22-2012
    Location
    Australia
    MS-Off Ver
    Excel 2016
    Posts
    329

    Copy TextBox data to Worksheet in specific range

    Good day all,

    I am working with a code to copy a contractor details to a particular worksheet. On my first UserForm if you press the "Add Personnel" cmd button it takes you to a second userform "Contact & Qualification Details" on this UserForm I have 4 TextBoxes, when the data is entered I need this data to be copied to sheet "PAGE 2" in the relevant grid starting at A18 & then clear all textboxes for the next entry to be copied below the last, I have the code below & so far had no success, any assistance would be greatly appreciated, thank you all once again & have a great day - Marco


    Please Login or Register  to view this content.
    Attached Files Attached Files

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Copy TextBox data to Worksheet in specific range

    Should iColumn not be iRow here?
    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    04-22-2012
    Location
    Australia
    MS-Off Ver
    Excel 2016
    Posts
    329

    Re: Copy TextBox data to Worksheet in specific range

    Hi Norie, I've tried both Column & Row, to no avail? The Code does however stop at "ws.Cells(iColumn, "A").Value = Me.TextBox1.Value" but just at a loss as to why? Thanks Norie - Marco

    **Update** - Don't ask me why but I change the code to "Row" from "column" & yes you guessed it Norie...works perfectly, thanks for the advice, you're a star! Have a fantastic day! - Marco
    Last edited by matrixpom; 10-28-2012 at 07:02 PM.

  4. #4
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Copy TextBox data to Worksheet in specific range

    No problem Marco.

+ 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