Browse a Listing
Top > ASP.NET > Tips and Tutorials
Popular Tags
Free Script links
I initially turned to ADO.NET's DataRelation and DataSet objects so that they could handle the relationship management for me. The DataRelation object's capabilities are dead on for single tables with self-referencing keys or multi-table relationships without self-referencing keys. If your current situation falls into either of these categories, you'll want to use the DataRelation object scenario to recursively build your hierarchical structure rather than the solution described in this article. In fact, most tutorials you'll find in books or on the web deal with either of these two situations. However, I have found that the DataRelation object is a little flaky when it comes to combinations of self-referencing tables and multi-table nested relationships, particularly with those that run more than 2 levels deep or have their root level row with the same PrimaryKey as its ForeignKey ParentID. Of course, if you are using foreign key constraints, you can't just set the ParentID to 0.
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 8 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
One of the challenges we had was being able to process a PagePostBack and save several hundred records across multiple tables within a reasonable amount of time. Plus, as the tool obtained more and more users with the number of analysis models growing exponentionally, it wouldn't be long before the wait time for data updates became unacceptable. We originally started out by following standard practices for populating classes, calling class methods with these classes as parameters which called stored procedures to save the data points one by one. To enhance performance a bit, we shared an open connection across all of the method calls. On larger models this resulted in waiting 15 seconds or so for the page to post to itself. Not a horrible wait time but I wanted to do better.
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 3 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
The control offers a very user friendly experience in that it allows the user to use their stylus / mouse to adjust the weight for a given decision criteria instead of typing the numbers. The first mode, Percent, sets the desired percentage of importance for a given criteria. Then automatically redistributes the remaining values evenly across the other sliders. Thus, the user only has to change one value instead of several while guaranteeing that the total of all the slider rows equals 100 The second mode is a simple one to nine range that allow the grouped sliders to be autonomous from each other. The following is a pair of rough screen shots of the two modes:
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 2 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
Using the Parameterized Factory Pattern, we can create a VersionFactory class that returns back a version specific class based on the version type or id passed into the VersionFactory. Not only can we dynamically return a specific class, we can also move methods back and forth between the version specific classes and the VersionMain class without adjusting anything in our ASP.NET pages or outside classes. This enables us to create a default class to handle all standard versions and custom classes for those versions with special business rules while the UI section of our code is obvilious. We don't have store any information in the database stating whether it is a custom class or not. If the custom class simply exists, it is used. Otherwise, the default class is returned. The following is a graphical representation of our class diagram:
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 2 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
Let's also review the application environment. A typical user analysis model would consist of around a 100 of these data entry pages. The Web site itself supports an unlimited number of analysis models. Thus, the database is quite large and the process of obtaining the meta data is quite complex. Running more queries than absolutely necessary can be a real drag on performance. Also keep in mind that a typical user will spend anywhere from 15 - 45 minutes on a single data entry page completing that section of the analysis model.
Normally, I would be reluctant to implement a solution that loads up the ViewState in this manner. Our web farm environment pretty much ruled out the use of static objects or the application cache. The performance impact of having larger than normal ViewState and the process of managing ViewState isn't necessarily prohibitive. That said, if you are trying to squeeze out every once of performance, doing this without it being necessary could hurt your cause.
You can use my sample as a means to measure how much is being stored in ViewState for the amount of data you expect to have in your own application. The default setting of 60 textboxes and 60 dropdown lists (each list contains 10 records) takes up roughly 100KB of html and ViewState combined
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 9 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
In this tutorial you'll find out how to validate a TextBox and RadioButtonList control on a webform using RequiredFieldValidator, which will show a warning and stop the submission of the form if a required field has no value.
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 2 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
Member Reviews
Visitor Ratings
Google PR
This is part I of the tutorial that teaches you how to connect to a SQL database from ASP .NET using SQL Authentication. This part shows you how to set up MSDE for Mixed Mode and how to use Web Data Administrator to create databases and users.
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 1 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
This is part II of the tutorial that teaches you how to connect to a SQL database from ASP .NET using SQL Authentication. This part shows you how to connect to the database using ASP .NET code and Visual Studio .NET's features.
Category:
Write a Review
Add Favorite
Refer it to Friend
Report Broken Link
Date Added: Oct 10, 2006 Hits: 0 Rating: 0.00 Votes: 0
Member Reviews
Visitor Ratings
Google PR
Member Reviews
Visitor Ratings
Google PR