.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How to handle logout whent using loginstatus control

Posted By:      Posted Date: September 23, 2010    Points: 0   Category :ASP.Net


I am using form authentication in my application and Loginstatus is using to logout .

My problem is I want to store login and logout information to database.

Which event handler should i use to insert logout time to database.

Please help..

View Complete Post

More Related Resource Links

login/logout control


Hello All,

I receive this error when running the application.  It is the LogOutPageUrl from the login/logout control.  I have substituted several different destination pages, which all work in any other part of the application.  However still get this error?  Can someone tell me what may be causing this, or why none of the other pages I have used will work either?

Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable.  Please review the following URL and make sure that it is spelled correctly.

how to you get the Handle.ToInt32 of a wpf control?

how to you get the Handle.ToInt32 of a wpf control?

Logout does not refresh LoginName and LoginStatus



i have a masterpage containing this code :

<asp:LoginView ID="LoginView1" runat="server" >
        <asp:LoginName ID="LoginName1" runat="server" />
        <asp:HyperLink ID="HyperLink_be_member" NavigateUrl="~/mypath/NewMember.aspx"
            runat="server">You're a member?</asp:HyperLink>
<asp:LoginStatus ID="LoginStatus1" runat="server"  />

when i am logged in, everything works fine : loginName shows the login name and loginstatus shows "Logout" hyperlink. And it shows this wherever i am in the website (subfolder or root).

But when i click on logout hyperlink, i go back to homepage and then loginName shows the login name of the member who just signed out and loginstatus still shows "logout" hyperlink. That s wrong.

When i go on a subfolder page, the loginName shows "You re a member ?" and loginStatus shows "Log in". That's the right behavior.

After trying lots of time to log in and log out and understand why it works this way, i real

asp:LoginStatus control with nested ?



Is it possible to place a nested span inside

an <asp:LoginStatus /> control? 

So instead of just...

<a id="LoginStatus1" href="javascript:__doPostBack('LoginStatus1$ctl00','')">

you would have...

<a id="LoginStatus1" href="javascript:__doPostBack('LoginStatus1$ctl00','')">
<span class="myCustomSpan">Logout</span></a>

why my LoginStatus always shows:"Logout"?



I didn't have this issue before, I have just created a simple default page with a LoginStatus control on the right top of the page:

<asp:LoginStatus ID="LoginStatus1" runat="server" />

And from the design view => Login Status Task, I selected: View Logged out. (so it should shows: "Login" text).

But when I run the page, it always show "Logout", I even haven't implement any membership yet.

Where is the problem?


Reorder List Control Drag Handle



I'm using a reorderlist (Ajax Control Toolkit Release 4.1.40412.2) inside a scrolling div  (class="reorderListDemo" style="overflow:scroll; height:225px; width:1300px; table-layout:fixed; text-align:left;"). When the height of the reorderlist is greater than the height of the div, the div will automatically have a vertical scrollbar. The problem is that when i scroll down to drag an item  from the bottom of the reorderlist, the reorderlist does not work properly. The drag image and the drop target does not correspond to the item i want to move.

I've attached a copy of my css file:


.modalBackground {

.popupMenu {

.popupHover {

.dragHandle {
	border:outset thin white;

.reorderListDemo li {

How to handle login control events when using a custom FBA login page?


Thanks to Kirk Evans' blog post that is liberally referenced all over the place, I have managed to get a custom login page working on my SP2010 site and it is pretty great.  The problem that I am having is that there doesn't seem to be anyway to respond to the events that are raised by asp.net login control that is in my page.

The page is inherited from Microsoft.SharePoint.IdentityModel.Pages.FormsSignInPage and as a result will error out when I attempt to reference a code-behind .cs file.  My question is, how do I respond to the events being raised by the login control that is in the page so that I can do things like logging successful user sign-ins?

Joseph Ackerman, MCSD, MCP.Net

invoke or begininvoke cannot be called on a control until the window handle has been created


Hello , Our application use the SQL 2008 R2 express edition 32/64 bit .

Now we have a new upgrade for our Application but we need to update the Existing SQL 2008 R2 express to a SQL 2008 R2 advanced services

to install the add-in Full Text Search.

When we do a upgrade during the setup , maintenance / upgrade , First we get a completed messagebox , after 1 min we get

the following error : invoke or begininvoke cannot be called on a control until the window handle has been created.

On the internet / microsoft there are patches for this known issue but not for the R2 version only for the SQL 2008 Express .

What can I do to update my SQL 2008 R2 express edition to a edvanced edition.

Anybody ?

Thanks , Yours Sincerely

getting a handle on a control


I have a javascript function that accepts the client id of a radioButton list control as a parameter.  In this function I want to clear the checked attribute (ie if any of the radio buttons were checked, clear them)


I have this


function resetRadioButton(args) {


                var radiolist = $(args);


                return false;

args is the client id of the radio button list i want to clear, but this just wont work.  Im a relative newbie to jquery, so im obviously doing somethig wrong, can anyone help ?

Adding Dynamic Rows in ASP.NET GridView Control with TextBoxes and with Delete functionality

In my previous examples, I have demonstrated on how to add dynamic rows in GridView control with TextBoxes and how to save the values into the database. Now, seems that most of the developers are asking if how to add a delete functionality with it. So in this example, I'm going to show on how to delete a certain row in the dynamic GridView with TextBoxes.

Accessing the different controls inside a GridView control

how we can access a particular control which resides inside a GridView control. In this article I will show you how you can access different controls inside a GridView control. We will see how we can access a TextBox control, a DropDownList control and a ListBox control. If you are working with ASP.NET 1.X then you might want to check out my article Accessing Different Controls Inside a DataGrid.

In-Depth look at the GridView Control

In the last article we looked at few of the new controls available in Asp.net 2.0. We also talked about Grid View Control which has replaced the Asp.net 1.1 DataGrid control for good. In this article we will examine more features of the Grid View control. In this article we will see some of the common operations that can be performed using the GridView control. Apart from these operations there are many more functions that can be performed on the control and which we will see in the later articles

ASP.NET repeater control - databind with style

even used the inline editing features, which I at the time thought was the coolest way possible to write ASP.NET code ( I managed to write code to hide all other rows and only show the current one - the row being edited). With a nice looking EditTemplate it looked indeed very slick but it really turned into giant and hard to manage code behind files.

Creating Paging for a Repeater Control

A common question is "How do I implement paging within a Repeater?" Although the beauty of the Repeater control is its flexibility, you're on your own for building most functions. ASP.NET 2.0 has included some new controls that provide paging, as does the DataGrid in ASP.NET 1.1. However, this tip shows you how to roll your own paging for a simple data viewer.

Using TemplateFields in the GridView Control

The GridView is composed of a set of fields that indicate what properties from the DataSource are to be included in the rendered output along with how the data will be displayed. The simplest field type is the BoundField, which displays a data value as text. Other field types display the data using alternate HTML elements. The CheckBoxField, for example, renders as a checkbox whose checked state depends on the value of a specified data field; the ImageField renders an image whose image source is based upon a specified data field. Hyperlinks and buttons whose state depends on an underlying data field value can be rendered using the HyperLinkField and ButtonField field types.

How To Add calendar control inside a GridView

This article show hot to add calendar control inside a GridView with code in c#

Using ATLAS PopUp Control with Calendar inside the GridView Control

In this video tutorial Mohammad demonstrates how you can access the Calendar control which is displayed using the ATLAS PopUp control inside the GridView control.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend