+ Reply to Thread
Results 1 to 6 of 6

How to: copy data from sheet 1 to 2 after hitting a submit button?

  1. #1
    Registered User
    Join Date
    01-30-2012
    Location
    cairns
    MS-Off Ver
    Excel 2003
    Posts
    29

    How to: copy data from sheet 1 to 2 after hitting a submit button?

    I've got a file attached of the kind of thing I'm after.... two sheets: data from the first should transfer to the second when the user presses the SUBMIT button, so the second sheet is all plain data with each new entry coming in beneath the previous row. If (hopefully, when) this one is up and running I'd like to add a few other fields too.

    The highlighted fields should have drop down menus, with options as described. The date should be in a specific format, say DD/MM/YYYY - the format must be the same for each entry - can it be set to DD/MM/YYYY so if someone enters the date in another format (e.g. 4 April 12) it will convert it? Or is it easier to have a calendar pop-up so you can just mouse click the date?

    Once all fields are full, the user will click the SUBMIT button and all the entries should go the the second sheet.

    How do I do this??? I'm sure it's not the most complicated thing you could hear of but it's certainly well over my head, I don't know where to start. Please help !!

    Will
    Attached Files Attached Files

  2. #2
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: How to: copy data from sheet 1 to 2 after hitting a submit button?

    something like:
    Please Login or Register  to view this content.
    You can set data validation on column A to ensure only valid dates are entered

  3. #3
    Registered User
    Join Date
    01-30-2012
    Location
    cairns
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: How to: copy data from sheet 1 to 2 after hitting a submit button?

    Thanks for the code, it's working well except for two things... when the data is sent to sheet 2, the input cells in sheet 1 don't clear; also the data that goes to sheet 2 is overwriting itself on the first row rather than shifting down a row each time new data comes across - is there a way to fix this? I would have thought the third code line ".ClearContents" would deal with the first prob? and maybe the "Offset" part of the rest would take care of the second? Along those lines can you please list in plain language what the code is asking for each different part? That would be really interesting/useful. Thanks for the help

    - Will

  4. #4
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: How to: copy data from sheet 1 to 2 after hitting a submit button?

    OK I understand, the above was for if you are adding more rows on the first sheet and want them all moving across, but you are wanting to use the same cells to add rows.

    Try this:
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    01-30-2012
    Location
    cairns
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: How to: copy data from sheet 1 to 2 after hitting a submit button?

    Unreal, works a treat! Thanks heaps for helping out. I'll get to work prettying it up.

  6. #6
    Registered User
    Join Date
    01-30-2012
    Location
    cairns
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: How to: copy data from sheet 1 to 2 after hitting a submit button?

    Hi, I'm having some troubles linking the code to a command button in excel 2003 (the attached file is in excel 2011 for mac). I need it work on a work computer using excel 2003. I've attached the new spreadsheet, it has both an autoshape submit button, which works ok, and and a command button - which I like the look of more but can't get to work...... Can you please have a look at the word doc attached, I've got some screen shots of the process I'm using to attach the code to the command button, I'm doing something wrong somewhere along the line.

    Another thing, an added feature I'd like to have is, for example, if someone clicks on the "exam type" list and selects "orthopaedics" then I would like a designated list to selectable under the next cell, "exam" - so different lists will appear under "exam" depending on what is selected in "exam type". Is this possible?

    Thanks heaps!

    doserepor.xlsproblems.docx

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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