john.clark
New member
- Joined
- Mar 8, 2007
- Messages
- 3
- Programming Experience
- 1-3
ADO.NET TABLEADAPTOR method
Hi all,
Very new to using table adaptors, binding sources etc and am having a problem that I'm sure is going to be an easy one to solve....though for some reason the solution is evading me at the moment.
I have a small single tier application that has a dataset: chimeraDataset
In the dataset I have a datatable with the relevant tableadaptor: PCT_INVENTORY
I've added a method into the tableadaptor called: PCT_get_details_for_factory_object which is linked to a parameterized SQL 2005 stored procedure.
Previewing the data within the dataset designer works fine, however, I now need to use that data on my form.
Ok... form1 has BindingSource1 which is connected to an instance of ChimeraDataset it also has PCT_InventoryTableAdapter1
If i place the following code into the load event of the form, I get ALL of the data, presumably as it's using the default GETDATA:
PcT_InventoryTableAdapter1.Fill(ChimeraDataSet.PCT_Inventory)
My MAIN question is how do I tell the tableadaptor to fill with data from my method in the tableadaptor called PCT_get_details_for_factory_object ?
Many thanks,
JC
Hi all,
Very new to using table adaptors, binding sources etc and am having a problem that I'm sure is going to be an easy one to solve....though for some reason the solution is evading me at the moment.
I have a small single tier application that has a dataset: chimeraDataset
In the dataset I have a datatable with the relevant tableadaptor: PCT_INVENTORY
I've added a method into the tableadaptor called: PCT_get_details_for_factory_object which is linked to a parameterized SQL 2005 stored procedure.
Previewing the data within the dataset designer works fine, however, I now need to use that data on my form.
Ok... form1 has BindingSource1 which is connected to an instance of ChimeraDataset it also has PCT_InventoryTableAdapter1
If i place the following code into the load event of the form, I get ALL of the data, presumably as it's using the default GETDATA:
PcT_InventoryTableAdapter1.Fill(ChimeraDataSet.PCT_Inventory)
My MAIN question is how do I tell the tableadaptor to fill with data from my method in the tableadaptor called PCT_get_details_for_factory_object ?
Many thanks,
JC