By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 1,665 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

Getting closer with Inventory Database

P: 18
Hi guys. I posted a question last week about getting the order qty based on my case packs. I couldn't figure out the code, and I couldn't seem to explain myself right. So what I did was added 5 new label and text boxes on my form to do my math for me.

1: =Abs([availableStock])
2: =([qtyOrder]/[cartonqty]) + .4 (I couldn't get it to round up...)
3: =Round([qtyCasepack],0)
4: =[qtyRoundCase]*[cartonQty]
5: =[qtyFinalOrder]*[unitCost]


4 and 5 are my final answers... The qty to order, and how much that item will cost.

So then I put these fields on my report, but the values will not show up. I tried doing all 5 of these formulas in the SQL Statement, and that did not work. I tried sourcing it to read from the form, and that did not work either.

Does anyone know what I am doing wrong at this point?

Thanks,

Stephanie
Aug 26 '08 #1
Share this Question
Share on Google+
5 Replies


puppydogbuddy
Expert 100+
P: 1,923
Hi Steph,
Still working hard on your system, I see!

Try placing your report in design view and look to see if the component fields from which your calculations are derived appear in the field list. The field list is an icon on the report designer toolbar that looks like a writing tablet with a list on it. The field list shows every field included in the report's record source (bound fields).....and generally would include the fields representing components of the calculations. These "component" fields are then referenced in the textbox control where the actual calculation is displayed.

Some bit of advice for you. Did you know there is a sample inventory database that comes with Access? The best way to learn code is to look at code used in similar applications. Even though your have designed your application to your specifications, there will still be some similar processes for which you can look at the code that was used. To get this database Click the key icon to start Access, and instead of opening an existing file, select Access Database Wizards, Pages, and projects. Then click on the inventory database icon.

Also see this link for a 3rd party inventory database for Access that costs $35 (less than the cost of a book) and I believe it comes with source code.

http://www.tinit.co.uk/?s=Stock_Control

Additionally, one of the best book reference sources I have ever used, uses an inventory system as one of the illustrative examples, showing step by step how to build an inventory application from the ground up. The book is entitled "Building Microsoft Access Applications" Copyright 2005 by John L. Viescas, Microsoft Access MVP.

Hope this helps.
Aug 28 '08 #2

P: 18
Hi Steph,
Still working hard on your system, I see!

Try placing your report in design view and look to see if the component fields from which your calculations are derived appear in the field list. The field list is an icon on the report designer toolbar that looks like a writing tablet with a list on it. The field list shows every field included in the report's record source (bound fields).....and generally would include the fields representing components of the calculations. These "component" fields are then referenced in the textbox control where the actual calculation is displayed.

Some bit of advice for you. Did you know there is a sample inventory database that comes with Access? The best way to learn code is to look at code used in similar applications. Even though your have designed your application to your specifications, there will still be some similar processes for which you can look at the code that was used. To get this database Click the key icon to start Access, and instead of opening an existing file, select Access Database Wizards, Pages, and projects. Then click on the inventory database icon.

Also see this link for a 3rd party inventory database for Access that costs $35 (less than the cost of a book) and I believe it comes with source code.

http://www.tinit.co.uk/?s=Stock_Control

Additionally, one of the best book reference sources I have ever used, uses an inventory system as one of the illustrative examples, showing step by step how to build an inventory application from the ground up. The book is entitled "Building Microsoft Access Applications" Copyright 2005 by John L. Viescas, Microsoft Access MVP.

Hope this helps.






Thank you! Yes, I am still working on it... I acutally used the inventory template from office.com for a reference on the code.

I'll try out what you said and let you know how I did.

Thanks again!
Stephanie
Aug 28 '08 #3

P: 18
OK... I double checked on everything you suggested and it's still not working. If I take the field from the field list, there is nothing displayed. If I source it to the form, then #Name comes up...
Sep 2 '08 #4

puppydogbuddy
Expert 100+
P: 1,923
OK... I double checked on everything you suggested and it's still not working. If I take the field from the field list, there is nothing displayed. If I source it to the form, then #Name comes up...
Hi StephR,
If there is nothing displayed after setting fields from the field list to the control source for the corresponding textbox controls in the report designer......I would run the reports recordsource query by itself (not as part of the report) and see if the query is returning any data.

Beyond that, rather than try and guess at the cause of your problem, I think you should read the tutorial called "Creating Reports Manually" at this link:http://www.jegsworks.com/Lessons/dat...rtmanually.htm

It has a pictorial step by step "how to" and explains how calculated fields operate, and why certain errors occur. Even if the tutorial does not directly solve your problem, I think you will be in a better position to know what question to ask.

Let me know what happens.

PDB
Sep 2 '08 #5

P: 18
Hi StephR,
If there is nothing displayed after setting fields from the field list to the control source for the corresponding textbox controls in the report designer......I would run the reports recordsource query by itself (not as part of the report) and see if the query is returning any data.

Beyond that, rather than try and guess at the cause of your problem, I think you should read the tutorial called "Creating Reports Manually" at this link:http://www.jegsworks.com/Lessons/dat...rtmanually.htm

It has a pictorial step by step "how to" and explains how calculated fields operate, and why certain errors occur. Even if the tutorial does not directly solve your problem, I think you will be in a better position to know what question to ask.

Let me know what happens.

PDB

THANK YOU so much for this reply!

I will let you know how it goes.

Stephanie
Sep 8 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.