TARGET DATE form Changes Criteria

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form that has the following unbound date field
=DateAdd("m",-2,[Forms]![frmProjects]![BuildDate])

Is there a way to have a pop up form which would allow change in the
criteria WITHIN the formula from m to d or # from 2 to 3 etc. I don't want to
allow users in design mode obviously.

If anyone knows of an example I could look or can tell me how to do that I'd
appreciate the help!

Thanks!!
 
The same form can be used to change them like this --
=DateAdd(IIf([Forms]![frmProjects]![Add_Span] Is
Null,"m",[Forms]![frmProjects]![Add_Span]),IIf([Forms]![frmProjects]![Span_QTY]
Is
Null,-2,[Forms]![frmProjects]![Span_QTY]),[Forms]![frmProjects]![BuildDate])
 
Thanks for the quick response! Does this this code go on a button or does it
replace the code on the txt box or ?? Thanks!

KARL DEWEY said:
The same form can be used to change them like this --
=DateAdd(IIf([Forms]![frmProjects]![Add_Span] Is
Null,"m",[Forms]![frmProjects]![Add_Span]),IIf([Forms]![frmProjects]![Span_QTY]
Is
Null,-2,[Forms]![frmProjects]![Span_QTY]),[Forms]![frmProjects]![BuildDate])


lmv said:
I have a form that has the following unbound date field
=DateAdd("m",-2,[Forms]![frmProjects]![BuildDate])

Is there a way to have a pop up form which would allow change in the
criteria WITHIN the formula from m to d or # from 2 to 3 etc. I don't want to
allow users in design mode obviously.

If anyone knows of an example I could look or can tell me how to do that I'd
appreciate the help!

Thanks!!
 
This is criteria for your query.
[Forms]![frmProjects]![Add_Span] is the text box to enter d, y, or w
for days, years, or weeks. If you do not enter anything it will default to
months.
([Forms]![frmProjects]![Span_QTY] is the text box to enter the number
to add. If you do not enter anything it will default to -2.

lmv said:
Thanks for the quick response! Does this this code go on a button or does it
replace the code on the txt box or ?? Thanks!

KARL DEWEY said:
The same form can be used to change them like this --
=DateAdd(IIf([Forms]![frmProjects]![Add_Span] Is
Null,"m",[Forms]![frmProjects]![Add_Span]),IIf([Forms]![frmProjects]![Span_QTY]
Is
Null,-2,[Forms]![frmProjects]![Span_QTY]),[Forms]![frmProjects]![BuildDate])


lmv said:
I have a form that has the following unbound date field
=DateAdd("m",-2,[Forms]![frmProjects]![BuildDate])

Is there a way to have a pop up form which would allow change in the
criteria WITHIN the formula from m to d or # from 2 to 3 etc. I don't want to
allow users in design mode obviously.

If anyone knows of an example I could look or can tell me how to do that I'd
appreciate the help!

Thanks!!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top