Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Binding Complex Stored Procedure to a form

Status
Not open for further replies.

jjme88

Programmer
Dec 28, 2007
58
0
0
GB
I have a problem where by I have some quite complicated sql server 2000 stored procedures that I want to bind to a adp form. All is fine I can return the recordset and bind the fields to the form and the data displays.

I do this via setting the 'Record Source' to the stored proc and setting the 'input paramters'

The problem I have is that the records are not updateable which I can understand. I get the message "The field XYZ is bassed on an expresion and can't be edited"

What I would like to do is having got the records displayed is allow them to be edited... all be it disconeted from the underlying records and then via a 'Save' button grab any changes a user makes and apply them back to the database.

Does that make sense to anyone.. can anyone sugest a method for doing this???
 
This sounds more like VB / .NET than VBA - can you clarify ?

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
sorry i should have explained. I am using MS Access 2003 adp file to presnet the data to the users. So this is an MS Access form bound to the Stored proc.

The stored proc has various layers and temp tables to manipulate the data into a recordset that I can bind to about 12 text box controls I have on the form. All works fine. One of the fields I can use as a key so if I can some how set access t allow me to change the values on the screen in the text boxes I can then run a procedure via a button that will upadte the apprariate tables for the change.

What I dont know how to do is set access so It will let me change the values in the text boxes, even though there is no way for it to update thte underying tables...

Hope that makes some sense.

thanks for any help!!
 
Hmmmm - certainly not an Access guru (you may get a better answer from the Access Forms forum: Forum702

The way I might get around this (again, not going to necessarily be the best way) would be to have a button on the form that you could click if you wanted to change values. This would either pop up a "mirror" of the current form (same kayout but to the side of the original form) or make visible a set of textboxes that are NOT bound to the dataset. You could then add the new values to the unbound textboxes and use your key to update these values into your tables - this would have the added benefit of making visible to yourself (or the user) what the before and after values would be...

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
ok thanks for the tip I will try that. I will also ask the question in the correct place.

Thanks again.
 
It's not that this is the incorrect place - just that you may get people with more specific Access knowledge in that forum...

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top