+ Reply to Thread
Results 1 to 8 of 8

Fixing the date.

  1. #1
    Registered User
    Join Date
    10-06-2005
    Posts
    6

    Fixing the date.

    I have a weekly production sheet and want it to put the date in automatically when i enter the production info.

    So on the first day it would put the date in, and on the next day it would put that date in.

    Its so i can put the week day in to calculate weekly production.

    Is this possible or am i just been lazy.

    Any help would be much apprecieated.

    cheers

    Ian

  2. #2
    Registered User
    Join Date
    10-06-2005
    Posts
    6
    Just had a thourght.

    Can you have mondays date of that week put into the first row as soon as the file is opened that week?

    I could then have it work out the rest of the week.

    cheers

    Ian

  3. #3
    gls858
    Guest

    Re: Fixing the date.

    cs2883 wrote:
    > I have a weekly production sheet and want it to put the date in
    > automatically when i enter the production info.
    >
    > So on the first day it would put the date in, and on the next day it
    > would put that date in.
    >
    > Its so i can put the week day in to calculate weekly production.
    >
    > Is this possible or am i just been lazy.
    >
    > Any help would be much apprecieated.
    >
    > cheers
    >
    > Ian
    >
    >

    Not exactly what you asked but will this work?

    Insert a static date or time

    Current date Select a cell and press CTRL+;

    Current time Select a cell and press CTRL+SHIFT+;

    Current date and time Select a cell and press CTRL+; then SPACE then
    CTRL+SHIFT+;


  4. #4
    Registered User
    Join Date
    10-06-2005
    Posts
    6
    thanks, i'm ever hopeful of a lazy way of doing it.

    regards

    Ian

  5. #5
    Gord Dibben
    Guest

    Re: Fixing the date.

    Ian

    If your data is being entered in column A and you want a date stuck into
    column B use this event code.

    Private Sub Worksheet_Change(ByVal Target As Excel.Range)
    'when entering data in a cell in Col A
    On Error GoTo enditall
    Application.EnableEvents = False
    If Target.Cells.Column = 1 Then
    n = Target.Row
    If Excel.Range("A" & n).Value <> "" Then
    Excel.Range("B" & n).Value = Date
    End If
    End If
    enditall:
    Application.EnableEvents = True
    End Sub

    This is worksheet event code.

    Right-click on the sheet tab and "View Code". Copy/paste the code into the
    module.


    Gord Dibben Excel MVP

    On Thu, 6 Oct 2005 15:32:37 -0500, cs2883
    <[email protected]> wrote:

    >
    >I have a weekly production sheet and want it to put the date in
    >automatically when i enter the production info.
    >
    >So on the first day it would put the date in, and on the next day it
    >would put that date in.
    >
    >Its so i can put the week day in to calculate weekly production.
    >
    >Is this possible or am i just been lazy.
    >
    >Any help would be much apprecieated.
    >
    >cheers
    >
    >Ian



  6. #6
    Registered User
    Join Date
    10-06-2005
    Posts
    6
    cheers, ill have a go with that and let you know how i go.

    regards

    Ian

  7. #7
    Registered User
    Join Date
    10-06-2005
    Posts
    6
    Ok, i'm really new to all this. What exactly do i have to do with that. I've tried to put it in as a macro. Is that right? If not what do i do?

    Sorrry to be a pain!

    cheers in advance

    Ian

  8. #8
    Registered User
    Join Date
    10-06-2005
    Posts
    6
    Its ok, i got the idea of how to do it from another post.

    This forum is ace!!

    cheers

    Ian

+ 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