General information
Category:
The Mere Mortals .NET Framework
Ric
It depends (probably knew that was comming...). Technically, you can access it in any one of those manners since they're all heirachially related. Additionally, and if possible I'd recommend it, you can access and manipulate the data via this business object itself. The reason being is that since the business object is going to contain a copy of the data anyway, why create more overhead with a form level dataset? Instead, businessObject.GetCurrentDataSet() will return a reference to the dataset as an mmDataSet....so you can do stuff like BusinessObject.GetCurrentDataSet().table[0].rows[0].column[5] = 100 or whatever. If you want to use the typed dataset techniques, then just cast it first...((MyTypedDataSet)BusinessObject.GetCurrentDataSet()).tablename.row[0].columnname = 100.
If the business object that you want to access is the primary of that form, things get even easier...this.PrimaryBusinessObject.whatever....
But, if you DO need to create a form level copy of the dataset, then just cast it to any one of the three depending on how you want to access the data
dsOrders = (MyCustomDataSet)BusinessObject.GetCurrentDataSet();
dsOrders = (DataSet)BusinessObject.GetCurrentDataSet();
dsOrders = BusinessObject.GetCurrentDataSet; *It's already an mmDataSet*
Scott
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only