Results 1 to 2 of 2
2005-09-12, 14:08 #1
- Join Date
- Sep 2005
- Thanked 0 Times in 0 Posts
ado, stored proc and subforms (2002)
with the great help of you guys my little project is coming along really nice now, thanks very much. This is quite difficult for me as im a complete novice and i thankyou for your patience with helping me time after time.
i have a form called order entry, and a subform called order entry subform. I would like to synchronise these forms together but there is a problem i have.
basically when users are putting on an order and have saved it, they can still view it in order entry by selecting the order number in a drop down box, it then brings up the order. when the order is invoiced it then is released from order entry.
I would like to get the two forms working together with stored proceedures, the only thing is, when there are no orders in there, i still need to obviously be able to put orders in to start and they are going need to be able to view them over.
ive written a stored proceedure that needs the foreign key from the orders table as a parameter to load the order detail lines. but now i dont know what to do in respects to passing the parameter to it if there are no records in respects to new order input. Any ideas?
2005-09-12, 15:02 #2
- Join Date
- Dec 2000
- Burwash, East Sussex, United Kingdom
- Thanked 206 Times in 190 Posts
Re: ado, stored proc and subforms (2002)
I suggest you take a look at the NorthwindCS sample database (usually in Program FilesMicrosoft OfficeOffice nSamples where n is the relevant version number - e.g. 10 is Office XP) which has exactly this kind of setup. (Note: you may need to create the Northwind database in your copy of SQL server if it is not already present) You will notice that the Order Details Extended procedure is used without a parameter as the recordsource for the Customer Orders Subform2, and this subform is synchronised with the Customer Orders Subform1 form by using the Link Master Field and Link Child Field settings.Regards,
Microsoft MVP - Excel