+ Reply to Thread
Results 1 to 6 of 6

Add New Records Horizontally Not Vertically ?

  1. #1
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Add New Records Horizontally Not Vertically ?

    .
    This is the layout of the sheet where new entries will be added :



    A
    B
    C
    D
    E
    F
    G
    H
    I
    J
    K
    L
    M
    N
    O
    P
    1
    Item ID
    Equipment Piece
    Out Time
    In Time
    Time Used
    Equipment Piece
    Out Time
    In Time
    Time Used
    Equipment Piece
    Out Time
    In Time
    Time Used
    Equipment Piece
    Out Time
    In Time
    2
    A123
    Drill 1
    7:33
    14:21
    =D2-C2
    Drill 23
    15:00
    15:38
    Drill 18
    16:00
    3
    A456
    Drill 2
    9:14
    10:20
    =D3-C3
    Drill 6
    11:11
    4
    A789
    Drill 3
    9:00
    9:29
    =D4-C4
    5


    I'm trying to determine how to add new CHECK OUT / CHECK IN times across a row rather than down a column.

    The workbook will utilize a UserForm for new data entry.

    The form will require selecting the ITEM ID ... then the EQUIPMENT PIECE the item is used with and finally the CHECK OUT or CHECK IN time. For this example let's say the ITEM ID refers to a drill bit. Each drill bit is different from all
    the others and can be used in several different drills.

    The employee checks out a specific drill bit and needs to enter the drill ID and the check out time. Then when the project is complete, they need to check the drill bit back in, placing the check in time immediately after their check out time.

    I'm not certain how to accomplish the coding for use across a row.

    Can you help ?

  2. #2
    Valued Forum Contributor
    Join Date
    03-24-2014
    Location
    England
    MS-Off Ver
    Excel 2003 - 2016
    Posts
    575

    Re: Add New Records Horizontally Not Vertically ?

    Without seeing your userform it's difficult to post code. However, when you're counting down a column (yes, I know, you want to count across a row but bear with me) you'd use a variable to count your way down the rows, like so:

    Please Login or Register  to view this content.
    However, since you want to count across the row you can use CELLS() instead, like so:

    Please Login or Register  to view this content.

    Unsure if this is helpful, if not then you'll def need to post the code you've currently got for data entry.


    EDIT: I've just seen how many posts you've got on this forum. There's no way the above is helpful in any way cos you def know this already. Please post the code you're currently using.

  3. #3
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Re: Add New Records Horizontally Not Vertically ?

    .
    If I were to use the "vertical" means of entering new data (without a means of going back to amend existing data, this is the basic code I would utilize :

    Please Login or Register  to view this content.
    I'm really not certain how to approach this project 'horizontally'. Please excuse my lack of knowledge in that regard.
    Attached Files Attached Files

  4. #4
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Add New Records Horizontally Not Vertically ?

    Are you searching for the item ID and then wanting to add just time out and time returned?

    Edit: I see now what you doing with the horizontal entries

  5. #5
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Re: Add New Records Horizontally Not Vertically ?

    .
    nigelog :

    Yes

  6. #6
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Add New Records Horizontally Not Vertically ?

    Apologies for delay
    from your simple database code

    Please Login or Register  to view this content.
    2 can be substituted for a "This Row" variable

+ 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. [SOLVED] Lookup Horizontally & Vertically
    By djfatboyfats in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-03-2014, 12:07 PM
  2. look-up values horizontally and reflect them vertically
    By Ksenia in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-30-2014, 01:52 PM
  3. Can you autofill horizontally and vertically?
    By keez1993 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-27-2014, 03:59 AM
  4. [SOLVED] Is it possible to freeze both vertically and horizontally?
    By claralou in forum Excel General
    Replies: 4
    Last Post: 09-27-2013, 05:04 AM
  5. [SOLVED] listbox display vertically and not horizontally
    By Blackbeginnings in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-18-2013, 07:03 PM
  6. Merging Cells Horizontally and Vertically
    By mandyc51 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-26-2012, 09:24 AM
  7. [SOLVED] Sumproduct vertically and horizontally
    By jimstrongy in forum Excel General
    Replies: 2
    Last Post: 03-21-2012, 04:37 PM

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