MonoX support board

Start the conversation, ask questions and share tips and solutions with fellow developers.

Non-registered users can only browse through our support boards. Please register now if you want to post your questions. It takes a second and it is completely free. Alternatively, you can log in without registration using your credentials at major sites such as Google, Microsoft Live, OpenId, Facebook, LinkedIn or Yahoo.

how to print users name in users profile page  (Mono Support )

9674 put(a) pogledan, 4 odgovor(a) 18.12.2013. 10:52:15Kreirao(la) sonap
sonap

sonap

18.12.2013. 10:52:15
Hello, I was wondering how is it posible to just print the name of the user whose profile I am currently watching.
To be more specific, I am editing the AboutMe.aspx and I want to print the user's name in a <div> element.

Thank you in advance,
Panos
Ovaj sadržaj još nije ocijenjen. 
475 Reputacija 52 Ukupno objava
imarusic

imarusic

18.12.2013. 10:55:29
Hi,

did you try to use username Url parameter?
Ovaj sadržaj još nije ocijenjen. 
3016 Reputacija 428 Ukupno objava
sonap

sonap

18.12.2013. 11:12:02
Hello!
Thanks a lot for your reply,

I haven't. You mean this:  <a href="<# ProfileUrl #>"><# Username #></a> ?

How is it used?

Thanks,
Panos
Ovaj sadržaj još nije ocijenjen. 
475 Reputacija 52 Ukupno objava
imarusic

imarusic

18.12.2013. 11:16:21
Hi,

take a look please at the folowing code snippet:

string username =  String.Empty;
if(UrlParams.UserProfile.UserName.HasValue)
    username = UrlParams.UserProfile.UserName.Value;
Regards.
Ovaj sadržaj još nije ocijenjen. 
3016 Reputacija 428 Ukupno objava