472,325 Members | 995 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,325 software developers and data experts.

Control Source on a Text Box

I've created some fields that calculate future dates. The way they are
set up they do not save to a table. This is the expression I used
(=DateSerial(Year([IFSPOrginal]),Month([IFSPOrginal])+6,Day([IFSPOrginal]).
I placed it in the Control Source property. I want to save them to a
table so I can use them on a report.

So the 2 questions are:

1. How do you use a calculated field that doesn't save to a table in
a report?

2. If you have to save it to a table to use it in a report, where do
I put the expression so it does the calculation other than control
source property?

Thanks
Mark
Nov 12 '05 #1
6 2174
On 26 Feb 2004 11:04:52 -0800, Mark Lees wrote:
I've created some fields that calculate future dates. The way they are
set up they do not save to a table. This is the expression I used
(=DateSerial(Year([IFSPOrginal]),Month([IFSPOrginal])+6,Day([IFSPOrginal]).
I placed it in the Control Source property. I want to save them to a
table so I can use them on a report.

So the 2 questions are:

1. How do you use a calculated field that doesn't save to a table in
a report?

2. If you have to save it to a table to use it in a report, where do
I put the expression so it does the calculation other than control
source property?

Thanks
Mark


Regarding #1, above:
You don't save the calculated field to a table, you repeat the same
calculation in the report.
As long as your table contains the data in the fields used in the
calculations, that's all you need.

Regarding #2, above:
See my response to #1.
--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
Nov 12 '05 #2
Mark Lees wrote:
I've created some fields that calculate future dates. The way they are
set up they do not save to a table. This is the expression I used
(=DateSerial(Year([IFSPOrginal]),Month([IFSPOrginal])+6,Day([IFSPOrginal]).
I placed it in the Control Source property. I want to save them to a table so I can use them on a report.
You may assume that a report can be built on a table only. That is not
the case: you can use a query as source for the report. That happens to
be frequent use.
So the 2 questions are:

1. How do you use a calculated field that doesn't save to a table in
a report?
In a query. Or, immediately on the report: ou can set the controlsource
of report fields just as you set them in forms.
2. If you have to save it to a table to use it in a report, where do
I put the expression so it does the calculation other than control
source property?


It is so much advised against, that I couldn't even provide a technical
answer. Just don't store the calculated value.
--
Bas Cost Budde
http://www.heuveltop.org/BasCB
but the domain is nl

Nov 12 '05 #3
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

First off, you can use the DateAdd() function to add 6 months to the
date value IFSPOriginal:

DateAdd("m", 6, IFSPOriginal)

If the date IFSPOriginal is saved to the table you can use the same
function in the report. Use an unbound TextBox and set its
ControlSource to this:

=DateAdd("m", 6, [IFSPOriginal])
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQD5KIoechKqOuFEgEQJboQCgyHxsDYcCz9HnP2q6vzEm30 pnwF4An27A
fhqZr+nTo3uqW7Y56SvTL5XF
=LrYG
-----END PGP SIGNATURE-----
Mark Lees wrote:
I've created some fields that calculate future dates. The way they are
set up they do not save to a table. This is the expression I used
(=DateSerial(Year([IFSPOrginal]),Month([IFSPOrginal])+6,Day([IFSPOrginal]).
I placed it in the Control Source property. I want to save them to a
table so I can use them on a report.

So the 2 questions are:

1. How do you use a calculated field that doesn't save to a table in
a report?

2. If you have to save it to a table to use it in a report, where do
I put the expression so it does the calculation other than control
source property?


Nov 12 '05 #4
Thanks!
Nov 12 '05 #5
Thanks!
Nov 12 '05 #6
MGFoster:

Thanks for the help. However if I set it up with the DateAdd function
it asks me for a parameter value and bases the results from the
parameter value and not the one stored in IFSPOrignal.

MGFoster <me@privacy.com> wrote in message news:<PS*****************@newsread2.news.pas.earth link.net>...
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

First off, you can use the DateAdd() function to add 6 months to the
date value IFSPOriginal:

DateAdd("m", 6, IFSPOriginal)

If the date IFSPOriginal is saved to the table you can use the same
function in the report. Use an unbound TextBox and set its
ControlSource to this:

=DateAdd("m", 6, [IFSPOriginal])
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQD5KIoechKqOuFEgEQJboQCgyHxsDYcCz9HnP2q6vzEm30 pnwF4An27A
fhqZr+nTo3uqW7Y56SvTL5XF
=LrYG
-----END PGP SIGNATURE-----
Mark Lees wrote:
I've created some fields that calculate future dates. The way they are
set up they do not save to a table. This is the expression I used
(=DateSerial(Year([IFSPOrginal]),Month([IFSPOrginal])+6,Day([IFSPOrginal]).
I placed it in the Control Source property. I want to save them to a
table so I can use them on a report.

So the 2 questions are:

1. How do you use a calculated field that doesn't save to a table in
a report?

2. If you have to save it to a table to use it in a report, where do
I put the expression so it does the calculation other than control
source property?

Nov 12 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Billy Jacobs | last post by:
I have created a DataGridColumnDatePicker Component so that I can put a datetimepicker control in my datagrid. It almost works. When I put my...
5
by: Cro | last post by:
Hello Access Developers, I'd like to know if it is possible to perform a count in an expression that defines a control source. My report is...
2
by: Bob | last post by:
I've got a bound report with a query as the record source. I'm adding a total to the footer and have inserted a text box to display it. I'm...
0
by: Shane O. Pinnell | last post by:
I am sure this has come up before, but I haven't been able to find an answer as of yet. That said, any help is definitely appreciated! I have a...
6
by: Tom Rowton | last post by:
This one has me a bit confused and I'm not finding what I need in the MSDN or by searching these forums, so here goes... I have a rather...
7
by: moondaddy | last post by:
I have a user control being used instead of a frame page. when the user clicks on a menu item I need to send the ID (integer value) of that menu as...
2
by: Mike | last post by:
Hi, I am strugling with a simple problem which I can't seem to resolve. I have an asp.net page which contains a server-control (flytreeview, which...
0
by: nate | last post by:
the error returned is this: Server Error in '/AnnAccRpt' Application....
8
by: fernandezr | last post by:
I would like to use a user control as a template inside a repeater. Some of the fields in the control should be hidden depending on whether or not...
14
by: Rolf Welskes | last post by:
Hello, I have an ObjectDataSource which has as business-object a simple array of strings. No problem. I have an own (custom) control to which I...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: CD Tom | last post by:
This happens in runtime 2013 and 2016. When a report is run and then closed a toolbar shows up and the only way to get it to go away is to right...
0
by: CD Tom | last post by:
This only shows up in access runtime. When a user select a report from my report menu when they close the report they get a menu I've called Add-ins...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
0
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.