---
title: "Update the Login Control"  
description: "Update the Login Control"  
author: "ravi kumar"  
published: 2011-11-01  
updated: 2011-11-02  
canonical: https://www.mindstick.com/forum/340/update-the-login-control  
category: "asp.net mvc"  
tags: ["asp.net mvc"]  
reading_time: 1 minute  

---

# Update the Login Control

How to [update](https://www.mindstick.com/forum/156353/what-is-hummingbird-update) the [Login control](https://www.mindstick.com/articles/627/login-control-in-asp-dot-net) to display Login [user](https://www.mindstick.com/articles/13001/multi-statement-table-valued-user-defined-function-in-sql-server) details once logged in successfully.i.e. once Login into the [Login form](https://www.mindstick.com/forum/355/login-form-and-registration-form-in-php) Login control should be [changed as](https://answers.mindstick.com/qa/43146/what-are-ways-farming-changed-as-a-result-of-the-industrial-revolution) Logoff control and diplay the Login [username](https://www.mindstick.com/forum/12798/there-is-no-viewdata-item-of-type-ienumerable-selectlistitem-that-has-the-key-username) details

## Replies

### Reply by Chris Anderson

Hi,\
\
You can create user [control](https://www.mindstick.com/blog/197/asp-dot-net-repeater-control) to change the [login](https://www.mindstick.com/articles/12852/styles-login-form-in-android) to logoff.\
**For eg.**\
\

```
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %><%    if (Request.IsAuthenticated) {%>        Welcome <b><%: Page.User.Identity.Name %></b>!        [ <%: Html.ActionLink("Log Off", "LogOff", "Account") %> ]<%    }    else {%>         [ <%: Html.ActionLink("Log On", "LogOn", "Account") %> ]<%    }%>
```

\
You can also refer demo mvc application provided default in visual studio.\


---

Original Source: https://www.mindstick.com/forum/340/update-the-login-control

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
