update a value only TODAY

anxoperez

Active Member
Joined
Oct 3, 2007
Messages
254
I have a value in A1 which fluctuates.

I have 2 columns--DATE and REGISTRY. I have a macro that records each DATE and its corresponding value under REGISTRY. The corresponding value is whatever appears in cell A1 for that date.

What I need is for that value under REGISTRY to also fluctuate just like in A1 but ONLY throughout THAT DATE. Once the date is over (or the document is closed), I need it to freeze the value (whatever value it showed last).

Can anyone help me with this?
 
But your formula doesn't include this:

If last date = TODAY then last registry = 'THE LIST'!I2

Or am I supposed to type it in manually? if so, will it be done automally for each subsequent day?

Also, I have not even tried your formula because the parameters I gave you were simplified. For instance, the columns I was talking about are not in A and B but in C and D as you can see from the table. If you still want me to try your formula taking into consideration what I just wrote, maybe you can adapt it and I can try it and tell you.

I await your reply.
 
Last edited:
Upvote 0

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
unless you try the event code you do not know whether it works or not
keep the original file safely somewhere and do this in copied file.

in the copied file do this
in the sheet "rank" in column A and B there is only one row of entries
entry in A5 is
=today().
this automatically puts today's date in 5
in B5 the entry is
='the list'!F5
So automatically the F5 values in sheet "the list" is entered in B5 of sheet "rank"

now do an experment.

even though it is the middle of the day save the file .
automatically a new row will be added in column C and D and see whether these new wntries are ok. If it is ok remove these two NEW entries and wait for the end of the day to save the file

the event code shoud NOT be copied in the standard module but as explained by me in the earlier thread.

COPY YOUR FILE AND KEEP the original SAFE FOR RETRIEVAL IN CASS IF THRE IS MESS UP

see my sheet "rank" (the sheet "the list" is also in the workbook which has some entry in F5.


today here is 12 June 2008. this automatically entred in A5. B5 is also entered automatically (I did not enter) because of the formula alrady existing.
now I save the file and result you see in C9 and D9.

now you delete values C9 and D9 and save this fille and see what happens in C9 and D9
Book1.xls
ABCD
1
2
3
4TODAYdailyloadDATESPOSITION
512-Jun-086.505-Jun-080,00
606-Jun-08-0,2
709-Jun-08-5.5
810-Jun-08-12
912-Jun-08-18.5
rank
 
Upvote 0
Venkat,

Here are the problems I encountered:

- the position does not seem to reflect the position shown in 'the list'!F5

- It did add today's date, but now I have 2 of today's date in column C

- I changed the time on my computer to 23.59pm and when it hit 0.00h it didn't do anything.

- Also, if I press save twice (just to experiment), it adds tomorrow's date.

Here's what it looks like (not including the last thing I wrote):<SCRIPT language=JavaScript src="http://www.interq.or.jp/sun/puremis...[/XD][XH][/XH][/XR][/RANGE][/XH][/XR][/RANGE]
 
Upvote 0
- the position does not seem to reflect the position shown in 'the list'!F5

B5 entry should be
=thelist!F5

- It did add today's date, but now I have 2 of today's date in column C
the above will solve the problem
also on the first day (yesterday) type manually C5 and D5 entries

other days the macro will take care of col C and D that is from 6th row onwards.

- I changed the time on my computer to 23.59pm and when it hit 0.00h it didn't do anything.

this is not envisaged in my macro. Only if you manually save and whenever you save the file the macro will automatically run.
It looks your computer is on all the 24 hours seven days and this file is never closed.

when you change the clock to 23:59 and quickly save the file see what happens(if it is delayed by more than one second it will go into tomorrow's date). do you want exacly to run the macro at 23:59. any macro will take more than one second to run. I do not know whether you can accomplish this. can you not save the file at some appropriae time at the end of the day. do not save the file more than once in the same day. if you do keep the last row of that date and delete other rows of the same date.

- Also, if I press save twice (just to experiment), it adds tomorrow's date.

naturally as the clock shifts to 0:00 and tomorrow is today.

you webpage is some east european language. I could not change the encoding.

give feedback.
 
Upvote 0
Hi again, Venkat.

I think we're really missing each other. This process is very slow and the thing is I actually really need to solve this issue because I have four people waiting for an answer to move on with their work. I know the point of forums is to post everything so everyone can see it, but since it takes a full day to get a reply from each other (are you in australia?), would you agree to using an instant messaging service to solve the issue? I wouldn't mind posting the results afterwards in here so everyone can see them. It's just that for a simple "no, I didn't mean that" it takes a full day to communicate. That's what happened with this last thread. My computer is not on 24h/day, I don't want to do anything at 23.59h and I was not talking about B5, but rather D5.

Please let me know if that'd be ok. We could use MSN messenger or Skype.

unitednationsorganizationªhot

and

anxoperez

respectively

I could log on tomorrow anytime after 10-11am GMT+1.
 
Upvote 0
I understand and appreciate your problem . But i am an old man and so my hearing efficiency may not be high. Beside I am an indian It would be difficult for me to really understand your accent fully and the same for you. It is also difficullt to give an offhand reply to the lspoken quereies. The only thing is we can communicate through email (venkat1926@gmail.com).


try this

BEFORE ENTERING THE EVNT CODE
first day enter a5 the first days date and in B5 the formula
=thelist!F5
in C5 the first days date and D5 position
DO NOT COPY THE MACRO
all manuallly
save the file



the next day COPYthe macaro in the place I have indicated
do NOT save immediately. at the end of the save the file
what the event code does is
it will put the dat'sa date in C6 and in D6 the formula you have given .
the even code itself has provision put todays date in c6.
the next day when you save the event code will put that day's date in C7. so there is no need to have today()+1.
but suppose you save it more than once you will get repeated data of the same date . in that case leave it alike that and the next day remove the earlier same date's values keeping the last entry (or row ) of the previous dates values and at the end of the day save it.


I know my solution was not efficient. I expected some othre exeprt would have also given a BETTER solution. NoW you know what the event code does(if necessaray go through the code statemnts) and I am sure with your technical profess you will be able to do some experiments and modify the code and solve it

there is one more trick you can do but that becomes still more difficult.

anyhow you are always at liberty to send me an emaill(my email address is given above)

greetings.
 
Upvote 0
for one more time let me modify my instructions
this is an experiment for you

BEFORE ENTERING THE EVNT CODE
create a fresh copy of the file
change the computer date to day before yesterday

enter in a5
=today()
and in B5 the formula
=thelist!F5
in C5 the first days date and D5 position
DO NOT COPY THE MACRO
all manuallly
save the file

change the computer date to yesterday
COPYthe macaro in the place I have indicated
save the file

change back to today's date
at the end of the day save the file

see whetehr you get what youwant


If you are not satisfied with this solution kinldy repost the question to the newsgroup and some expert will give a better solution.

I do not have msn messenger or skype. I only have yahoo messenger.
greetings.bye
 
Upvote 0
Hi again, Venkat.

Unfortunately it does not appear to work.

I will follow your advice and re-post my question onto a new thread.

Please understand that I am very thankful for you help.
 
Upvote 0

Forum statistics

Threads
1,214,967
Messages
6,122,503
Members
449,090
Latest member
RandomExceller01

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top