Dang spell check... ordEr was fixed from what you typed.
Liz Ravenwood
Programmer/Analyst
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Wednesday, July 25, 2012 4:30 PM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] using query results for a default value
Yes Crystal, you've got it. I am only thinking of the calculation because it is the default value for the next record in the subform.
So I need to learn how order is used?
Liz Ravenwood
Programmer/Analyst
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Crystal
Sent: Wednesday, July 25, 2012 4:21 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: Re: [MS_AccessPros] using query results for a default value
Hi Liz,
I am having trouble understanding what you are asking ...
Do you want a field called LayerNum to have its value sequentially created when new records are added to the subform? You should store this information, not calculate it. I often put a field called Ordr (ordEr is reserved) into tables and have code to create its value automatically. Then users can rearrange things by changing its value :)
Warm Regards,
Crystal
*
(: have an awesome day :)
*
________________________________
From: Liz Ravenwood
Pros, I have a subform with an FK of ID from the PK of main form ID.
I need the subform to autonumber not the ID, but something called a LayerNum but only within the ID. That is, each ID of main record has multiple layers of sub.
So, I was thinking I could set the default value to a calculated field in a query.
SELECT Max([LayerNum]+1) AS [Next]
FROM TestSideLayers
GROUP BY TestSideLayers.ID
HAVING (((TestSideLayers.ID)=[Forms]![DSMain]![ID]));
And then have the form field default be: =[NextLayer]![Next]
However, I get that nasty #Name? business or whatever it is and it isn't working.
Liz Ravenwood
[Non-text portions of this message have been removed]
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
Rabu, 25 Juli 2012
RE: [MS_AccessPros] using query results for a default value
__._,_.___
.
__,_._,___
Langganan:
Posting Komentar (Atom)
Tidak ada komentar:
Posting Komentar