+ Reply to Thread
Results 1 to 5 of 5

Automatic conversion of a cell value and inserting specific value in another cell

  1. #1
    Registered User
    Join Date
    01-03-2016
    Location
    Serbia
    MS-Off Ver
    2007
    Posts
    25

    Unhappy Automatic conversion of a cell value and inserting specific value in another cell

    hy,
    when i paste workhours from monthly schedule, for ex. a1=12 (day shift), and b2=12 (4 hours of day and 8 hours of night shift) and so on for all days in one month (two rows), a need to run a macro to automaticaly change value of b2 cell to 8, and to enter a2 cell value 4... (to split night hours for calculating paycheck).. - only second row where there is a cell value, cell changes and cell above... two rows are for one person, than c,d for other, e,f for another and so on.

    Thanks

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Automatic conversion of a cell value and inserting specific value in another cell

    Welcome to the forum

    1st, I would suggest that it is often not a good idea to replace actual data with some "standard" value - the raw data is then gone for good. Rather, leave the raw data as is, and use a formula to show whatever you need.
    2nd, it is always better for us if you can upload a small (clean) sample workbook (not a pic) of what you are working with, and what your expected outcome would look like.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    01-03-2016
    Location
    Serbia
    MS-Off Ver
    2007
    Posts
    25

    Re: Automatic conversion of a cell value and inserting specific value in another cell

    1 name 1 12 12 12 day
    12 12 12 night

    2 name 2 12 12 12 day
    12 12 12 night

    3 name 3 12 12 12 12 12 day
    12 night

    4 name 4 12 12 12 day
    12 12 night

    paycheck:

    1 name 1 12 4 12 4 12 4 day 06.00-22.00
    8 8 8 night 22.00-06.00 8h

    2 name 2 12 12 12 4 4 4 day 06.00-22.00
    8 8 8 night 22.00-06.00

    3 name 3 12 12 12 12 12 4 day 06.00-22.00
    8 night 22.00-06.00

    4 name 4 12 12 4 12 4 day 06.00-22.00
    8 8 night 22.00-06.00
    Last edited by milosvica; 04-30-2016 at 06:37 AM.

  4. #4
    Registered User
    Join Date
    01-03-2016
    Location
    Serbia
    MS-Off Ver
    2007
    Posts
    25

    Re: Automatic conversion of a cell value and inserting specific value in another cell

    i need to automaticly populate (or replace) night hours 12 into :
    from 19.00-22.00 = 3 hours day
    22.00-06.00 = 8 nightly hours
    06.00-07.00 = 1 day hour

    4 hours of daily shift
    8 hours of nightly shift

    i can copy sheet and change in it
    have 300 people

  5. #5
    Registered User
    Join Date
    01-03-2016
    Location
    Serbia
    MS-Off Ver
    2007
    Posts
    25

    Re: Automatic conversion of a cell value and inserting specific value in another cell

    ................
    i need to automaticly change 12 night hours to 4 in day and 8 in night in paycheck sheet from monthly sheet
    Attached Files Attached Files

+ 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. VBA Code for inserting automatic date/time when another cell is completed
    By Jes1397 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-18-2015, 10:16 AM
  2. [SOLVED] Inserting a date in a specific format into a cell
    By Bezzie in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-09-2014, 03:32 AM
  3. Replies: 15
    Last Post: 03-08-2014, 05:19 PM
  4. Inserting a picture in specifice cell of specific size
    By mgalterio in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-03-2012, 12:14 PM
  5. [SOLVED] VBA Code not inserting the right number in a specific cell
    By akwishestofish in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-13-2012, 05:07 PM
  6. Inserting excel formula into specific cell
    By kchm_2000 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-22-2011, 02:40 AM
  7. inserting value if another cell contains a specific word
    By exceluser2 in forum Excel General
    Replies: 3
    Last Post: 03-01-2006, 03:10 PM

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