Databinding
-
What are peoples thoughts on databinding (in ASP.NET), is it good or bad? I have recently started using databinding and I am not enjoying it. My biggest problem is that it is so hard to test. The only way to test it is by running it and manually trying every possibility. I fear that I will leave one or two properties unlinked and then they won't do anything. At the moment I am unable to get a dropdownlist working on a InsertItemTemplate. As it is the 'insert' one it doesn't try to populate the objects. I need to populate the items in the dropdown, but not populate the value. Setting the datasource doesn't do anything. Any ideas how I can solve this problem?
-
What are peoples thoughts on databinding (in ASP.NET), is it good or bad? I have recently started using databinding and I am not enjoying it. My biggest problem is that it is so hard to test. The only way to test it is by running it and manually trying every possibility. I fear that I will leave one or two properties unlinked and then they won't do anything. At the moment I am unable to get a dropdownlist working on a InsertItemTemplate. As it is the 'insert' one it doesn't try to populate the objects. I need to populate the items in the dropdown, but not populate the value. Setting the datasource doesn't do anything. Any ideas how I can solve this problem?
Member 4487083 wrote:
What are peoples thoughts on databinding (in ASP.NET), is it good or bad?
Well, I guess my question would be, what is the alternative ? Writing code that iterates by hand ? No thanks.
Member 4487083 wrote:
My biggest problem is that it is so hard to test. The only way to test it is by running it and manually trying every possibility.
I'm not sure how you mean.
Member 4487083 wrote:
I need to populate the items in the dropdown, but not populate the value. Setting the datasource doesn't do anything. Any ideas how I can solve this problem?
You should populate your drop down in the item databound event.
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
-
What are peoples thoughts on databinding (in ASP.NET), is it good or bad? I have recently started using databinding and I am not enjoying it. My biggest problem is that it is so hard to test. The only way to test it is by running it and manually trying every possibility. I fear that I will leave one or two properties unlinked and then they won't do anything. At the moment I am unable to get a dropdownlist working on a InsertItemTemplate. As it is the 'insert' one it doesn't try to populate the objects. I need to populate the items in the dropdown, but not populate the value. Setting the datasource doesn't do anything. Any ideas how I can solve this problem?
Databinding is a great feature, a base to zero code tricks. If you follow rules properly you will found it very helpfull and very thin front end pages.
Share your experience with others Check my Blog...