A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Go to



 
 
Thread Tools Display Modes
  #1  
Old December 27th, 2006, 08:39 PM posted to microsoft.public.access.forms
steph44haf
external usenet poster
 
Posts: 46
Default Go to

Hello,

I would like to go to the next unused record automatically when I open a
form (hopefully from the switchboard). I have a database that keeps track of
product numbers. We are assigned a lot of about 500 product numbers every
few months and I would like to load those to the database and then as we add
new products mark them used. How can I go to the next unused prodcut number
when opening a form? (I am hoping that I don't have to use coding, but that
would be ok if it is the only way.)

Any info I can get to point me in the right direciton would be helpful.

Thanks much,

Stephanie
  #2  
Old December 27th, 2006, 09:04 PM posted to microsoft.public.access.forms
Dirk Goldgar
external usenet poster
 
Posts: 1,164
Default Go to

"steph44haf" wrote in message

Hello,

I would like to go to the next unused record automatically when I
open a form (hopefully from the switchboard). I have a database that
keeps track of product numbers. We are assigned a lot of about 500
product numbers every few months and I would like to load those to
the database and then as we add new products mark them used. How can
I go to the next unused prodcut number when opening a form? (I am
hoping that I don't have to use coding, but that would be ok if it is
the only way.)

Any info I can get to point me in the right direciton would be
helpful.

Thanks much,

Stephanie


You could just base the form on a query that returns only the unused
product numbers, or else apply a where-condition when opening it (e.g.,

DoCmd.OpenForm "frmProductNos", _
WhereCondition:="Used=False"

), and thus have the form only show unused product numbers. As far as
what constitutes the "first" unused number, that depends on the way your
product numbers are set up, but it may very well be that having the
form's recordsource query sort ascending on product number will do it.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


  #3  
Old December 27th, 2006, 09:17 PM posted to microsoft.public.access.forms
steph44haf
external usenet poster
 
Posts: 46
Default Go to

I never thought of that. I will give it a try. Thanks!

"Dirk Goldgar" wrote:

"steph44haf" wrote in message

Hello,

I would like to go to the next unused record automatically when I
open a form (hopefully from the switchboard). I have a database that
keeps track of product numbers. We are assigned a lot of about 500
product numbers every few months and I would like to load those to
the database and then as we add new products mark them used. How can
I go to the next unused prodcut number when opening a form? (I am
hoping that I don't have to use coding, but that would be ok if it is
the only way.)

Any info I can get to point me in the right direciton would be
helpful.

Thanks much,

Stephanie


You could just base the form on a query that returns only the unused
product numbers, or else apply a where-condition when opening it (e.g.,

DoCmd.OpenForm "frmProductNos", _
WhereCondition:="Used=False"

), and thus have the form only show unused product numbers. As far as
what constitutes the "first" unused number, that depends on the way your
product numbers are set up, but it may very well be that having the
form's recordsource query sort ascending on product number will do it.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 02:52 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.