|
|
The MapPath method
|
Total Hit (2673) |
The ASP.NET Page object exposes the MapPath method, which converts a virtual path into a physical path, so it' is useful for passing arguments to objects that don't work with virtual paths:
«Code LangId=4»
Dim sr As New System.IO.StreamReader(Me.MapPath("/data/values.dat"))
«/Code»
You can al
....Read More |
Rating
|
|
|
|
Dynamically moving a server control
|
Total Hit (2743) |
Dynamically moving a server control instance on the page is very easy, thanks to the possibility to add any style attribute to the control. In this case, you can dynamically add the control's LEFT and TOP coordinates, and another attribute that says you want to use DHTML's absolute positioning. To t
....Read More |
Rating
|
|
|
Passing values from a page to another by means of the Context object
|
Total Hit (2705) |
Sometimes you may want to gather the user input with a page, and process it in a different page. As you know, ASP.NET web forms can post only to themselves, so you can't just change the form's <i>action</i> attribute and make the form post to a different page. And anyway, you may want to do some pro
....Read More |
Rating
|
|
|
Store Your Database Connection String in Web.Config
|
Total Hit (715) |
Here we present an example of how to store a database connection string in the application's Web.Config file. Web.Config is a part of every asp.net application and provides a nice, central location for storing information that may be needed in many of your web pages. This first bit of code is just a
....Read More |
Rating
|
|
|
Multi-row Editing in the ASP.NET DataGrid
|
Total Hit (845) |
This articles demonstrates how you can have multiple datagrid rows available for editing at one time, not just the one row you are normally limited to.
|
Rating
|
|
|
|
|
|
|
|
URL sharing across a network with ASP.NET
|
Total Hit (2409) |
URL Explorer is an ASP.NET application which displays the content of a generated XML file, representing the structure of your Favorites folder with the help of an XSLT stylesheet. URL Explorer allows the sharing of Internet Explorer shortcuts over an intranet or the Internet.
....Read More |
Rating
|
|
|
|
|
|
|
|
ASP.NET DataGrid Paging Part 1 - Built-In Paging
|
Total Hit (540) |
The DataGrid server control enables easy paging through data. You can set the DataGrid to use paging and specify a page size (number of records to display). Each time the page is loaded the DataSet is recreated and the DataGrid is bound to the appropriate records based on what page is to be displaye
....Read More |
Rating
|
|
|
File Upload with ASP.NET
|
Total Hit (638) |
This article shows you how work with uploading of the files using ASP.NET and C#.
|
Rating
|
|
|
|
Placing a Date Last Updated for a Page Inside a User Control
|
Total Hit (1045) |
You may have noticed that dotnetjohn.com pages now include a "Last Updated:" line at the bottom of all pages. I make extensive use of user controls on this site. The top of the page down through the "Powered by ASP.Net" graphic is a user control. The left side navigation is a user control as is the
....Read More |
Rating
|
|
|
|
|
|
|
|
Use the Xml Web Control to Display Database Query Results as XML
|
Total Hit (706) |
Sometime you may need to query a database and produce the results as an XML file. The .Net XML Web Control makes this extremely easy to do. All you have to do is create an instance of the XML control on your .aspx page. A very few lines of code can then be used to display the database query as XML.
....Read More |
Rating
|
|
|
Shopping Cart using C#.NET, Web Forms and SQL Server
|
Total Hit (633) |
This application is a Shopping Cart where users can select items and place an order. I have added the features of login, and adding new users if user does not exist. Validations are performed wherever needed like email format validation, zipcode etc.
....Read More |
Rating
|
|
|