selecting table adapters in datasets
-
Hi, In my dataset I have numerous table adapters which I need to chose from at runtime. I can create at runtime a text string for the adapter I need to use however I cannot use that string to construct the method. What I have done is create an array of tableadapters and then used the index of that array to contruct the method. As the project grows, this is becoming a consuming exercise and I am surprised there isn't a better way. Is there some way that you can select a tableadapter from the dataset at runtime using the string representation of the table adapter to select it with. Thanks.
-
Hi, In my dataset I have numerous table adapters which I need to chose from at runtime. I can create at runtime a text string for the adapter I need to use however I cannot use that string to construct the method. What I have done is create an array of tableadapters and then used the index of that array to contruct the method. As the project grows, this is becoming a consuming exercise and I am surprised there isn't a better way. Is there some way that you can select a tableadapter from the dataset at runtime using the string representation of the table adapter to select it with. Thanks.
-
Glen Harvy, I THINK its possible to do this with Reflection, but i've never used it, maybe a bit of googling/someone else might be able to confirm my post. Regards, Gareth.
Thanks for your response. I've never used reflection either! Guess I'll have to learn :) I've tried googling (always do) and I'm sure it's there but what do I search on is the hard part :(
Glen Harvy