ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   No update of dates (https://www.excelbanter.com/excel-discussion-misc-queries/27809-no-update-dates.html)

[email protected]

No update of dates
 
I have a worksheet, which is a log of clients I see everyday and it
goes for 2 weeks at a time. How can I use one of the functions, ie:
today(), and have the worksheet pick up the correct date everyday, but
without updating the previous dates in that worksheet?

Thank you in advance.

Hernan.


bigwheel

" wrote:

I have a worksheet, which is a log of clients I see everyday and it
goes for 2 weeks at a time. How can I use one of the functions, ie:
today(), and have the worksheet pick up the correct date everyday, but
without updating the previous dates in that worksheet?

Thank you in advance.

Hernan.

Try entering this as the code for a workbook page

Private Sub worksheet_activate()
Range("A65536").End(xlUp).Offset(1, 0).Select
ActiveCell = Date
End Sub

Each time the sheet is opened, the date is put into the next empty cell

[email protected]

Thank you Bigwheel for replying. However, I don't understand where is
it that I have to enter this code.

Could you please explain it.

Thanks again.

Hernan


bigwheel

" wrote:

Thank you Bigwheel for replying. However, I don't understand where is
it that I have to enter this code.

Could you please explain it.

Thanks again.

Hernan

OK. Click ToolsMacroVisual Basic Editor
When it opens, you should see in the left hand column, the name of your open
workbook. Double click the sheet name and paste the code into the empty
window that appears on the right. Then, each time you open that worksheet,
it should enter the date in the next empty cell in column A

[email protected]

Hi Bigwheel,

I tried this but it didn't work.

I even formatted column A as DATE, and nothing.

Thank you for helping me anyway.

Hernan.


bigwheel

see file sent to your hotmail address


Hernan

Now is doing it! :-) Thanks.

Question... What do I have to add in order for the "cursor" to move to the
right once the date is placed?

Where can I read about all this stuff? :-)

Hernan

"bigwheel" wrote:

see file sent to your hotmail address


bigwheel

"Hernan" wrote:

Now is doing it! :-) Thanks.

Question... What do I have to add in order for the "cursor" to move to the
right once the date is placed?


Activecell.Offset(0,1).Select

Where can I read about all this stuff? :-)


There are many Excel books available


All times are GMT +1. The time now is 08:37 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com