|
Thanks for helping! But this seems to work too:
this.User.Identity.Name;
|
|
|
|
|
YEs, there are multiple ways to do this.
By the way, another way is using WindowsIndentity[^]:
WindowsIdentity.GetCurrent();
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Is WindowsIdentity not serverside? I think it is. Isn't it?
|
|
|
|
|
_Madmatt wrote: I think it is. Isn't it?
Obviously it is. And the GetCurrent returns the WindowsIdentity object that represents the current Windows user.
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Manas Bhardwaj wrote: the current Windows user.
The current logged on user on the server or client side?
|
|
|
|
|
_Madmatt wrote: The current logged on user on the server or client side?
Why dont you give it a try ?
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
'cause I'm logged on on the server and on my pc with the same account
But my code works so I'm happy
I'll give it a try, specially for you!
|
|
|
|
|
i need to play some videos in media player. While doing this, media player waits for taking whole the video to ram. this takes alot of time when size of video is about 200-300 mb. How can media player do this partly. my code is:
myObjectTag = myObjectTag + "<OBJECT id=playera classid=clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95 style=\"position: absolute;left: 0; top: 0; width: 100%; height: 100%;\" standby='Media is loding...>";
myObjectTag = myObjectTag + "<param name='url' value='" + sourceUrl + "' />";
myObjectTag = myObjectTag + "<param name='src' value='" + sourceUrl + "' />";
myObjectTag = myObjectTag + "<param name='AutoStart' value='true' />";
myObjectTag = myObjectTag + "<param name='Balance' value='0' />";
myObjectTag = myObjectTag + "<param name='CurrentPosition' value='0' />";
myObjectTag = myObjectTag + "<param name='showcontrols' value='true' />";
myObjectTag = myObjectTag + "<param name='enablecontextmenu' value='true' />";
myObjectTag = myObjectTag + "<param name='mute' value='false' />";
myObjectTag = myObjectTag + "<param name='PlayCount' value='1' />";
myObjectTag = myObjectTag + "<param name='rate' value='1.0' />"; //0.5=Slow, 1.0=Normal, 2.0=Fast
myObjectTag = myObjectTag + "<param name='uimode' value='full' />"; // full, mini, custom, none, invisible
myObjectTag = myObjectTag + "<param name='showdisplay' value='true' />";
myObjectTag = myObjectTag + "<param name='volume' value='50' />"; // 0=lowest, 100=highest
myObjectTag = myObjectTag + "</object>";
|
|
|
|
|
This is so FRUSTRATING...
I was losing session information when embedding an iFrame inside a PHP site, so decided to switch from InProc mode of sessions to StateServer. Made/added the following lines to my web.config:
<br />
<sessionState mode="StateServer" timeout="60" cookieless="AutoDetect" stateConnectionString="tcpip=localhost:42424" /><br />
<pages enableSessionState="true"> <br />
<httpModules><br />
<add name="Session" type="System.Web.SessionState.SessionStateModule" /><br />
and yet, the first time I touch a Session variable I get a:
Session state can only be used when enableSessionState is set to true, either in a configuration file or in the Page directive. Please also make sure that System.Web.SessionStateModule or a custom session state module is included in the <configuration>\<system.web>\<httpModules> section in the application configuration.
I am using Master and Pages and the Session is in the Master Page_Load code behind.
Any help is greatly appreciated.
|
|
|
|
|
Steve van Niman wrote: I was losing session information when embedding an iFrame inside a PHP site,
So, you want to maintain Session for two different site ?
Have a look into this article, It may help you
Exploring Session in ASP.Net[^]
|
|
|
|
|
No - just one site. Just need to get it out of IIS. Server managing sessions is the same server; however, if this is in place, then I am set to start a server farm if necessary.
|
|
|
|
|
what about Iframe inside in PHP Site? I am not able to understand section ?
|
|
|
|
|
Please don't worry about iFrame in PHP at this point. I can't get this to run as a simple website on my machine...
|
|
|
|
|
Wow - sometimes it amazes me as to how frequently the "website" or "project" becomes corrupted in Visual Studio. At wits end, started brand new website and literally copied over web.config from website giving me issues with sessionState - StateServer. Worked out of the gates... Ok so my config was correct, so why would my existing site not work? Went to \windows\Microsoft.Net\Framework\n.n.nnn.release\Temporary ASP.NET Files\ and deleted all websites - still a no go.
Then remembering what one of my friends told me, "It is common for the solution/website to become corrupted. When this happens, copy all files to a new directory and start over. Bingo - works out of the gate. Lost two days on something that should have worked because the platform I'm on cannot remain uncorupted...
|
|
|
|
|
I want to create a feed back form in asp.net using VB script
anybody pls help how to code that
if user click submit button it send a mail to my id
i designed the user interface page but i cont able to code to onclick action
|
|
|
|
|
|
i think that code was in C# but i am using VB script in asp.net
i tried that its not working i designed a user interface in as feedback.aspx
using language as VB
|
|
|
|
|
I am not able to understand what is your exact problem. In your Feedback form you should have Email, Subject and Comments field ( May be different based on requirments ) . On click of submit button you need to send mail on Email Id. Now, how to send mail I have alredy told you.
I think your problem is something different and you are not able to express it . Please try to explain in properly so that we can help you out !!
Thanks !
|
|
|
|
|
I designed a user interface for a web form
i have 11 text box, 4 dropdown box, and 2 button
Button 1 name is submit
Button 2 name is Reset
Now i any user click the submit button the content what was filled by the user in the text box and dropdown box should mail to a email id in text format this the task what i want to do
i am using asp.net and language as VB
|
|
|
|
|
kn.nageshwaran wrote: i am using asp.net and language as VB
Quote Selected Text
If you had tried searching the Code Project articles you could have found this[^].
|
|
|
|
|
Hey buddies , I am a new to ASP. I am a C# programmer............................. But my customers wanted me to make them web Pages when I made a software in C# for them.......................I have learned an introduction to Web Development in HTML and PHP. But I wanted to know ASP.Net . One of my friend told me to work on PHP bcoz ...."U can get more free codes when u r in trouble even Tutorials" as he said. For now I wanted to develop Personal sites. But latter I also wanted to develop my own advertisement site.
So which one do u recommend me to use? i.e which one is better in all case.
Thank you.
modified on Sunday, October 4, 2009 10:19 PM
|
|
|
|
|
It Depends Upon the website You Are Developing?But You Will get the most Help for Microsoft technologies when compared to any other technologies..!But Also Dont Forget Your Are In ASP.net Forum..!
All The Best For Your Future..!
|
|
|
|
|
Ok tnx for your information. By the way for now I am going to develop for 2 persons a personal site. Then I also wanted to develop my own advertisement only site(if it makes me more money). By the way I also heard that web pages developed by Asp.Net are slower than others developed by php. Is that really true? Why?
|
|
|
|
|
|
thank u man. It really helps me.
|
|
|
|