Forms :: Limiting Order Amount Based On Available Stock

Feb 26, 2014

I have an inventory database with a few tables:

1 with product info
1 with customer info
1 with incoming stock
1 with outgoing stock (orders)

I also have 3 query's:

Total incoming stock per product
Total outgoing stock per product
Total current stock per product (based on the 2 above queries)

I'm trying to make a form through which orders can be placed, and I want to limit the amount that can be ordered based on how much stock there is.

I've been told I can use the 'before update' event on the form to achieve this, but where to start. Do I use a Macro, an Expression, or do I need code?

Also, currently the record source for this form is the outgoing stock table, but I guess I'll need to add my 'current stock' query to the sources before this can work? And maybe even my other 2 queries because my 'stock' query is based on the other 2? But I can't really seem to get that to work either.

View Replies


ADVERTISEMENT

Limiting Amount Of Records In A Table?

Apr 25, 2005

Hey! I'm doing Computing AS level and the coursework is to create a system for "Terry's Turkey". This is basically my first introduction to Access, and our teacher is little to no use!

After alot of work working out things in access and reading alot of books, other than creating the switchboard, theres only a few things left to do!

The first is to limit the amount of "turkeys" that can be ordered. I have 2 tables that this envolves... Order and Customers, they have a one to many relationship (each customer may place one or more orders, each order must be placed by one and only one customer). They are linked by Customer ID. I need to set two limits, I guess by a validation rule of some kind. The first is that each Customer can place no more than 5 orders. The second is that their can be no more than 40 orders in total. A slight complication to this is that a customer can "cancel" an order, in this case its marked as cancelled (theres a yes/no field called Active to determine this), and ideally, these wouldnt be included in the counts.

So far I have the following as a query, though I have no idea how to put this into a validation rule
SELECT Count(Orders.OrderID) AS Var1
FROM Orders;

I guessed that to expand this to not including inactive orders something like
SELECT Count(Orders.OrderID) AS Var1
FROM Orders
WHERE active="yes";

Any help at all would be most appreciated! I have spent many hours pondering over this is and looking at as many access sources that I can! I think this is my last resort :(

View 3 Replies View Related

General :: Limiting Amount Of Bookings Per Course To 50

Jun 27, 2013

I have Trainee, Staff, Course, and Booking tables and forms. Everything is working fine but I want to limit the amount of bookings per course to 50, how would I go about doing this?

View 9 Replies View Related

Forms :: Hiding Certain Fields Based On Number Amount

Jun 13, 2013

I search around online and did come across much info on code to how to hide fields. But, the problem is I cant seem to find a way to hide a certain amount of fields based on a number amount.

example: Lets say I have a 12 text fields to show 12 months of monthly payments, and lets say a client only has a 3 payment term. How can I list 3 under installment field and have remaining 9 fields auto hide since they wont be necessary? this way I only see what applies and not additional text fields.

View 1 Replies View Related

Forms :: How To Auto Populate Fields Based On Payment Term And Amount

May 14, 2013

How can I auto populate fields based on a payment term & amount?

example: client has 9 monthly payment of $150 term due every 15th of the month. (I would like it to be able to max out at 30 months)

So what I want to do is populate 9 monthly fields with dates and $150 payments fields next to it. Now, the payment fields even after auto populate, must be flexible in the sense for me to add a different amount just in case client makes an over payment that month too. In, addition I would like a check mark box to auto populate along if possible based on the 9 month term, this way I can manually check TRUE when payment is received in office.

View 3 Replies View Related

Order Entry / Stock Control Template Db

Jan 5, 2006

I have to provide a Quote/Order/Invoice and stock control system very quickly for one of our satellite offices, and wondered if anyone knew of any "boilerplate" databases that have done all the grunt work, so that I can just edit reports and forms etc to get them up and running. We are happy to pay a (modest) fee for this service, but would expect to get full access to the design/code for later development and customisation if required.

I've tried Googling but get page after page of rubbish !! Any pointers would be gratefully recieved.

Thanks and Regards

Richard Keith

View 3 Replies View Related

Forms :: Dataset Based On A Table - Order Of Added Records

Aug 9, 2013

I have a form with a dataset based on a table. (there are a number of buttons on the form with code so it's important I don't delete the form and start again with a new one)

The data displays correctly but the order is wrong. It displays the last record added as the first record when viewed in form view.

I want to reverse this order, how do i go about it? It seems very simple but I've yet to find a solution.

I also don't want to base it on a query because of the code mentioned earlier.

View 4 Replies View Related

Limiting And Filling Fields Based On Another Field

May 1, 2014

The database I am building is for Student & Alumni administration at a non-profit culinary school. In the various forms for entering student information and for defining tests and recording test scores, I would like to not have to re-select things like Class Number or Test number.

I was able to use the Test Number field as Link Master, Child in a Test Results sub-form where Test Parameters is the Master form. But I am not able to link with the Class Number, getting the error message: "The setting you entered isn't valid for this property" even though it is one of the Suggested Link Fields. The form record source is a query linking the Class Table, Test Parameters, Test Results and Students.

I noticed that I can eliminate both Class Number and Test Number from the sub-form. In the underlying query, both these fields are updated. However, the underlying Test Results table does have the Test Number but not the Class Number. While there is still a "queryable" link from the student to the Class Number, I would very much want the Class Number to be stored in the Test Results table.

Is there a way to accomplish this through the sub-form Link Master/Child property or any other/better way to inherit both the Class Number and Test Number in each Test Results record entered?

View 4 Replies View Related

Tables :: Limiting Table Input Based On Variable Values

Feb 7, 2014

I'm quite new to Access and am just working on a little practice database where I keep track of sales of a product.
Basically I have a table keeping track of the different types of products, a table keeping track of customers, a table for orders and one for replenishments of stock. I have a query that calculates the stock of each type of product based on replenishments and sales.

Now I want to make sure that a customer can't order any more than there is in stock. I know you can restrict what's entered into a table with a validation rule but that's only for static restrictions. After searching the internet for an answer I've pretty much learned that I can't really make this restriction directly in the table, correct? But then how can I achieve this? Do I have to restrict the amount through a form somehow?

View 3 Replies View Related

Modules & VBA :: Adding Amount And Checking Daily In Hand Amount?

Jul 21, 2015

I have One table(and designed form from it) in which i have recording the daily transactions(it is like a daily book). Daily transactions took place like Purchase of items of Amount 45, sale=70, sold on account=100 etc.

What problem i am facing is: I would like to Add Cash In Hand amount and would like to show it on my form. When day end I would like to move remaining cash In Hand on separate column of that date. The next day i would like to take the previous Remaining Cash in Hand as Cash In Hand at Start for next date and so on.

View 2 Replies View Related

General :: Multiply Different Amount Of Hours By Different Amount Of Rates

Jul 17, 2014

I am trying to make a report in which I can see the amount of money that I have to pay weekly to an employee. To explain myself clearer, I have different rates for each employee. For example:

NameNormalPayRateVacationPayRateSickPayRateOvertimePayRateStandbyPayRate
John Smith$15$10$15$30$8
Ken Jonson$10$8$10$20$8

I am doing this in a query. So what I want to be able to do is, for example, take 4 hours that the employee worked at NormalPayRate and multiply it. But if tomorrow the employee worked at a different rate, for example 3 hours overtime, I want those 3 hours multiplied by OvertimePayRate.

The way I saw it on my Google researches, is that they have only one rate and the amount will be [SumOfHours]*[Rate]. But how can I tell my query to skip, for example, one rate because the employee didn't work at that rate that day. So I can have different amount for the different rates.

By the way, entering the information I can divide at what rate the employee worked x day. So if the employee work 6 hours at regular, and later on 4 hours at standby, I have those information separated in my table.

Results that I am getting: I can easily get the amount in money multiplying the whole hours by a rate, so my result in my report will be multiplied by the same rate.

I am using Access 2013 ...

View 2 Replies View Related

Forms :: Limiting Combobox With Query

Oct 16, 2014

I'm trying to filter the options in a combo box based on two criteria. The first criterion is another combo box on the same form, for a cascading combo effect. This criterion works fine, no problems at all. The second criterion is a query. So the combo box should display only those values that match both the upstream combobox AND the results of the query. What's really frustrating is that this combobox works just fine in my development dbase. It only stops working when I move it into my active dbase. Anyway, here's the SQL for the combobox rowsource:

SELECT DISTINCT Size2.SizeID, Size2.XYdim
FROM (Shapes INNER JOIN (qrySignsInInventory INNER JOIN Size2 ON qrySignsInInventory.SizeID = Size2.SizeID) ON Shapes.ShapeID = Size2.ShapeID) INNER JOIN Signs ON Shapes.ShapeID = Signs.ShapeID
WHERE (((Size2.SizeID)=[qrySignsInInventory].[SizeID]) AND ((Size2.ShapeID)=(SELECT Signs.ShapeID FROM Signs WHERE Signs.SignID = [Forms]![frmUsedDropdown]![cmbSignID])));

I've hilighted the criterion that isn't working. Also, I'm not getting any errors or anything, it's just that the results aren't being filtered. I've triple-checked the references for the active dbase, and I've checked the results of the query. Everything should be working.

View 4 Replies View Related

Forms :: Limiting Input Data Record For Patient In Same Month

May 23, 2015

How to limit input data on the same month for each patient? The field is a data/text box on a subform

I found this code on Form Current Event!:

Code:
Private Sub Form_Current() Dim intMaxNumRecs as Integer
intMaxNumRecs = 5 'Max Number of Records to Allow
If Me.NewRecord Then With Me.RecordsetClone
If .RecordCount > 0 Then .MoveLast: .MoveFirst
If .RecordCount >= intMaxNumRecs Then
MsgBox "Can't add more than " & intMaxNumRecs & " records in the demo database!" .MoveLast Me.Bookmark = .Bookmark
End If End If End With End If End Sub

But I want a monthly limit...

View 1 Replies View Related

Forms :: Limiting Continues Form To Accept 7 Lines And Dating Them With Current Week?

Jul 29, 2013

Form info

1st Form Name: Mainform
Text to enter employee ID : empid

Sub form within Mainform: SFTimesheet (continues form)
text to enter: Timein, Break, Timeout

SFTimesheet shows and accept entries for each employee called using the text empid, on the mainform

I wanted the subform to show 7 days /lines starting from Sunday to Saturday of current week and dating the text "Timein" accordingly. When employee enteres an entry on the 7th Line, it should give them a new 7 lines for the new week to begin.

View 5 Replies View Related

Form Based On Ascending Order Of A Field

Apr 25, 2006

Hello all,

How can i get the records of a form based on a field ascending order (not the primary key), when i open it?

Thank you in advance.

View 3 Replies View Related

Forms :: Limit Amount Of Data That Users Need To Input

May 23, 2014

We have a database where we are trying to limit the amount of data that users need to input.

We have a form, which contains order information. Where a customer has specific requirements, we add those requirements to a separate document review table MasterSpecification and DetailedSpecification.

When a customer has specific requirements, we can open the frmMasterSpecification and search for the document.

Assuming a review has been done the requirements will be shown on the subform Frmsubcoverage. I would like to be able to select the record source from this form and have the details entered into our order entry form.

Under the specification form there could be many sub coverage records depending on the type of item ordered to that specification.

View 6 Replies View Related

Forms :: Display Fields With Large Amount Of Data

Mar 27, 2013

Best way to display "notes: field that gets updated/added to multiple times, in a form. (Access 2007)

I've got a DB to track information about product changes. Each month we have a meeting and discuss problem products. I'm concerned with a notes/comments section. Currently it is a memo field in the source table that can be added to, so the notes are cumulative. But we want to auto-add a date to each new entry (in case the person inputting the data forgets, and so that notes can be sorted by order on a report).

There may be many comments on a certain product or there may be none. Sometimes the note may be very long, other notes on the same product may be very short. I created a new table with a one-to-many relationship to case ID (to link it to the main form), auto-populate a date field, and field for notes in order to link multiple notes to each case (and of course an autonumber PK).

I can put the subform in the original form, but then the note field will be the same size for every note, though notes are not all uniform in size/length, and it ends up taking up a LOT of room on the main form. So I created a button to click to open the subform, but it brings up all records for all cases, not just the currently selected case. Again, have the problem of one uniform field size for all notes, regardless of size/length.

Then I considered a report to view past history (field size can shrink or grow as needed) then a button on the report that opens a form for data entry/entry of new note. But again the report displays all records for all cases, not just the currently selected case.

View 2 Replies View Related

Forms :: Upper Limit On Amount Of Time Allowed?

Sep 28, 2014

How do I put an upper limit on the amount of time allowed in a date/time field?

For example - during a heart procedure a person is exposed to radiation, it will never be more than a total time of 10 minutes. I want to know how much, but I want data integrity so I don't want them to be able to enter more than 10 minutes.

View 5 Replies View Related

Queries :: Sort Order In Query Based On ID (Autonumber)

Sep 10, 2013

This is something I occasionally see in Access and has been bugging me for quite a while.

As an example, when I have a table (all text fields except for the ID field which is an Autonumber with a unique index - ie just what Access creates when you import data) and I try to make a new table from a query by indexing the Autonumber field in descending order (ie to reverse the order of the table), it doesn't work properly.

So if I have:

SELECT [mytable].* INTO [mytable sorted] FROM [mytable] ORDER BY [mytable].[ID] DESC;

When I preview the data (ie run the select query to have a look at it), it looks fine.

When I change the query to a 'Make Table' and I then I check the table it makes, the order changes part-way down the list, so looking at the ID field it runs from number 2669 down to 2087 correctly, then it goes from 1960 to 1956, then 1803 to 1799, then 1751 to 1747, etc etc etc. After a while it seems to correct itself again, and orders normally down to #1

I'm using Access 2002.

View 5 Replies View Related

Queries :: Order Shortage Based On Multiple Stages?

Aug 17, 2015

I have a production database in which orders are checked for shortages at different levels of production in which :

1 raw product can be fetched in 2 or more final products, Shortages are checked as per priority.

In this database i have tables named "finalproductlist" and "rawproductslist" in which products are connected in one to many (see table "productmapping"). For E.g. 1 product in raw table can be fetched into 2 or more final products.

I have stocks query on both levels with which shortage is checked.

I want to create the order shortage query which gives the shortage at both levels prioritywise.

View 14 Replies View Related

Forms :: Calculations In Subform - Display Total Amount For All Records

Nov 20, 2014

I am trying to get the main form to display a total Amount for all records in Purchase order details but the control displays Error:

I have a Form called frmPurchaseOrder with a sub-form sbfrmPurchaseOrderDetails

sbfrmPurchaseOrderDetails takes item details from a table based on what is selected in the combo box then fills out four additional fields in the same sub-form.

SELECT tblItemListDetails.ItemID, tblItemListDetails.ItemName, tblItemListDetails.ItemSize, tblItemListDetails.ItemUnit, tblItemListDetails.ItemUnitCost, tblItemListDetails.ItemBrand FROM tblItemListDetails WHERE (((tblItemListDetails.Supplier)=[Forms]![frmPurchaseOrders]![SupplierCombo]));

Private Sub cmbItemName_Change()
Me.txtSize.Value = Me.cmbItemName.Column(2)

[Code] ....

View 5 Replies View Related

Forms :: Handling Large Amount Of Data In Memo Field

Jun 9, 2013

My DVD library database I have a memo field which has the description of the movies.

In some cases, like my tv show records, I have a lot of data because of the episodes and episode descriptions.

I'm currently displaying this data using a split form with the datasheet on the left

I must use a small font in the memo field in order to display all data.

I could use a larger font and simply scroll but I'm looking for an alternative.

I've even thought of creating a hyperlink filed and point to the movie on IMDB's web site. But when I click the link nothing happens even though I copied and pasted the link into the field.

View 8 Replies View Related

Forms :: Adding All Invoices For Expense Together And Display Total Amount

Sep 25, 2013

I have a subform in columns that has a list of invoices bound together by the site number on the form there is a Expense code that runs 51 to 95.

On another tab I want to add all the invoices for a expense code together and display the total amount

Below is an example of invoices

IDSite CodeInvoice DatePOInvoiceContractorInvoice AmountExpense Code
10289S20/09/2013 346603410Dj Commercial Cleaning Ltd 25.2362A
20289S28/09/2013 346061141Platinum Landscapes 240.0055A
30289S03/09/2013 353112021Clean And Green 167.0063A
40289S02/08/2013 353112015Clean And Green 174.0063A
50289S19/08/2013 111115271Southern Electric 189.5679A
60289S19/08/2013 346061121Platinum Landscapes 240.0055A
70289S02/06/2013 353112009Clean And Green 160.0063A
80289S02/05/2013 353112003Clean And Green 181.0063A

I want it to display on another tab

51 General Expenses £452.36
55 Gardens £1523.65

and so on

whats the best way to do this?

View 2 Replies View Related

General :: Priority Based Multiple Order Shortage List

Jan 21, 2013

I have created an access application for production system .

I have a final stock query and 2 to 3 orders based on priority and i want to create a shortage list based on priority ... here is detail :

ItemName....|Stock qty....|ORDER1....|ORDER2....|ORDER3....|
A.................|200............|40............. |90............|100...........|
B.................|500............|0.............. .|400..........|200...........|
C.................|30..............|40............ .|0..............|20............|
D.................|0...............|0............. ..|10............|0...............|
E.................|900............|400...........| 300..........|280...........|
F.................|130............|200...........| 50............|0...............|

Now I want shortage as:

ITEM NAME |O1 SHORTAGE | O2 SHORTAGE | O3 SHORTAGE|
A................|00..................|00......... ..........|30..................|
B................|00..................|00......... ..........|100.................|
C................|10..................|00......... ..........|20...................|
D................|00..................|10......... ..........|00...................|
E................|00..................|00......... ..........|80...................|
F................|70..................|50......... ...........|00...................|

What method Do I use to write a query as I have hundreds of Products and 40-50 orders????????

View 6 Replies View Related

General :: Pull Data From SQL Server Based Off Of Order Number?

May 27, 2015

I am looking into re-creating something I have created in Microsoft Excel into Microsoft Access.What I do in the Excel spreadsheet, is when I type in an order number, various fields in the spreadsheet are populated using vlookups and ODBC's.

I wish to re-create this in Access but not sure how. I have a basic form, with various fields such as, order number, part number, description, quantity.What I have in my mind is that I would like to be able to type in an order number, then the rest of the fields would be populated by a query to a SQL Server database.i can see a way to do this using VBA but would rather look for a more direct way if possible.

View 2 Replies View Related

Forms :: User View - Reduce Amount Of Options On Menu Bars

Aug 15, 2013

I have created a front end and put into production for my users but I want to reduce the amount of menu bar options they see so someone cant click on a button wondering what it does and mess something up. What is the best way to reduce the amount of options a user sees on the menu bars when they open the front end of the db?

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved