Date not appearing in report

gary g

Registered User.
Local time
Today, 07:16
Joined
Jul 4, 2009
Messages
38
Access 2010

One of the Field Names in my table is titled ActionDeadlineDate, with Date/Time selected as the Data Type for the field. On one of my forms I have created a text box based on this field. Under Properties/Control Source for this text box I have inserted the following formula:
=[DateReceivedinADR]+40 Basically, this forces the text box to auto populate to a date 40 days beyond whatever date is entered in the DateReceivedinADR text box. On the form itself everything works flawlessly.

I have created a query that includes the ActionDeadlineDate field. However, when I run a report off this query it will not populate the date for this field. On the report this column is just blank, with no date indicated.

Can anyone explain why this may be so? All other date fields I use on the form (at least those without an underlying date formula) appear as they should. Is there a way to make a date based on a formula appear on the report as well?

Hope I didn't make this too complicated. Maybe what I am asking for is not possible since a date formula is being utilized in the text box, rather than a simple date. Anyone's assistance will be appreciated. Tks.
 
Yep, the way you have done will only show the value for display. So you can either add the to the Control Source of the control on your Form OR if you want to store the value... In the After_Update event of DateReceivedinADR put...

Code:
Me.ActionDeadlineDate =[DateReceivedinADR]+40

Then the value will be in the field for use in your query/report.
 
Just for clarification, in the second sentence of your reply you wrote "So you can either add the...", what did you want to say after the word the?

Also, should I add the code exactly as you wrote it, including the preface me? I am never sure what the me stands for whenever I see code written. Obviously I am not well versed in writing code. :(

Thanks again.
 
Oops, after the word *the* should have been *=[DateReceivedinADR]+40 *. That's what I get for not proof reading!

If you are using in the Event Procedure then yes, use the Me. (which basically stands for the Form you are on).
 
Thank you very much for the followup. I will give it a try.
 

Users who are viewing this thread

Back
Top Bottom