+ Reply to Thread
Results 1 to 9 of 9

Moving row to a worksheet once discharge date is filled in.

  1. #1
    Registered User
    Join Date
    06-19-2013
    Location
    Indianapolis, IN
    MS-Off Ver
    Excel 2010
    Posts
    7

    Moving row to a worksheet once discharge date is filled in.

    Hello, I'm extremely bad with VBA/Macros so I'm hoping you can help me.

    I have two worksheets, Active Admissions and Discharge.

    I have in column P, a filed for a user to enter a discharge date. What I'd like is, when this field is populated with a date, for that row to be cut and pasted in the Discharge sheet, then the data in the Active Admissions would be shifted up to fill in the gap left by the data that was cut.

    Hopefully this makes sense. I'm sure this is simple, but I'm having trouble wrapping my brain around this.

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,895

    Re: Moving row to a worksheet once discharge date is filled in.

    this would be easier to provide a solution if you give us a sample spreadsheet.

    Attach a sample workbook. Make sure there is just enough data to make it clear what is needed. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are demonstrated, mock them up manually if needed. Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Registered User
    Join Date
    06-19-2013
    Location
    Indianapolis, IN
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Moving row to a worksheet once discharge date is filled in.

    Not a problem. See the attached sheet.

    I've added before and after for each of the worksheets. All data inclduded is dummy data.

    Inpt Call back help.xlsx

    What I'm wanting to autmomate is moving the row when a date is entered into the discharge date column (Column P in the Active Admissions sheet)

  4. #4
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,895

    Re: Moving row to a worksheet once discharge date is filled in.

    Here is a macro code to run that will move if there is a date in column P.
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    06-19-2013
    Location
    Indianapolis, IN
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Moving row to a worksheet once discharge date is filled in.

    Thank you so much, that works perfectly!!

  6. #6
    Registered User
    Join Date
    06-19-2013
    Location
    Indianapolis, IN
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Moving row to a worksheet once discharge date is filled in.

    Ok new problem with this. It's no longer working. I've copied the data over exactly. I set up the MACROS to run w/ ctrl+d. When I try to run it, nothing happens. even when I go back to a previous version of the file, nothing happens.

  7. #7
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,895

    Re: Moving row to a worksheet once discharge date is filled in.

    It's no longer working.
    Need more information. What does this mean. Are you getting an error message? Are your sheet names the same? Layout the same?

  8. #8
    Registered User
    Join Date
    06-19-2013
    Location
    Indianapolis, IN
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Moving row to a worksheet once discharge date is filled in.

    No error messages. Sheet names and layout are exactly the same. When I run the Macros, nothing at all happens. The action that's supposed to happen, does not happen. Nothing changes at all. I've verified that macros are enabled. I'm highly confused. I even tried opening a new document and copying the macros into the new document and still no luck.

  9. #9
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,895

    Re: Moving row to a worksheet once discharge date is filled in.

    Is the file that you have copied the code into an .xlsm file? VBA will not operate in an .xlsx file. You must have a macro enabled file.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Start and Stop times by account number and discharge date
    By newbie4 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-23-2013, 03:56 AM
  2. daily income based on date, admission, discharge and fee on a given date
    By annazet in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 03-18-2013, 06:29 PM
  3. Moving rows to specific sheets if a cell is filled
    By KWIN in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-16-2011, 05:05 PM
  4. How can I setup a date without the slashes moving in a worksheet?
    By TT in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-06-2005, 10:05 AM
  5. How to prevent cursor from moving behind filled cells
    By Spreadsheet Slave in forum Excel General
    Replies: 1
    Last Post: 04-04-2005, 09:06 AM

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