Name If using the latter, don't forget to import the System.
Name and Web User Control, I am trying to user User.
NET don't have a smart tag that allows you to select a data source, so at first glance, it is not easy to see how to bind a value returned from a Sql Data Source or Access Data Source control to the label.
Here's how to programmatically access the data returned by such a Data Source and apply it to a non-databound control.
I tried to use it but got the following error: " The type or namespace name 'User' could not be found (are you missing a using directive or an assembly reference?
Name in User Control What namespace do I have to include in my User Control code behind to be able to access the Forms Login User.
I couldnt actual...difference between Http Context. User Control I am trying to convert my aspx page that has all my graphics into a header user control, in the page I reference the username that is logged into the site. This worked just fine before I moved it to the ascx page. Thanks Craig In a user control or custom control your will need to use either: Page. Name function but it tells me that User is not identifited. NET code, whereas with the Data Set, you would need to create an object of the appropriate type - Data View, then iterate the Data Row View collection to access the values.In this, the code is remarkably similar to accessing values directly from a Data Set's table collection using plain ADO. The code below shows the contents of an aspx file, which contains two label controls, and two Sql Data Source controls.