DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Tue, 21 Aug 2007 20:21:42 +0530,    posted on: microsoft.public.dotnet.framework.aspnet        back       

Thread Index
  1    SenthilVel
          2    Aidy
          3    Bahadýr ARSLAN
                 4    SenthilVel
                        5    SenthilVel
                        6    Bahadýr ARSLAN
                        7    SenthilVel


Help needed in ASP.Net 2.0 Text Box Password Mode   
hi all,
i am running a ASP.Net 2.0 application.
in one of the pages i have a text box which is set as PASSWORD mode.
when the page is submitted or transfered , am not able to get the contents 
of this textbox which is in Password mode.

do we need to any more apart from setting to password mode to get the value 
present in the text box..?

do we need to do anything in specific with the viewstates if there is 
security with ASP.Net Password text boxes?

Please let me know

Thanks
Senthil
Date:Tue, 21 Aug 2007 20:21:42 +0530   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
A password box acts as normal, are you referring to the fact that the box 
isn't pre-populated after a postback?  If so then add a VALUE attribute to 
it with the value of txtYourPasswordBox.Text

"SenthilVel"  wrote in message 
news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...

> hi all,
> i am running a ASP.Net 2.0 application.
> in one of the pages i have a text box which is set as PASSWORD mode.
> when the page is submitted or transfered , am not able to get the contents 
> of this textbox which is in Password mode.
>
> do we need to any more apart from setting to password mode to get the 
> value present in the text box..?
>
> do we need to do anything in specific with the viewstates if there is 
> security with ASP.Net Password text boxes?
>
> Please let me know
>
> Thanks
> Senthil
>
>
> 
Date:Tue, 21 Aug 2007 16:09:37 +0100   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
Is your password textbox created programatically?
Check this.

As Aidy said, this can be about PostBack problems. For example in your 
Page_Load code

protected void Page_Load(object sender, EventArgs e)
{
// .. some other c# codes
txtPassword.Text  = "";
// .. some other c# codes
}
When postback the current value will be lost, so you have to control it like
protected void Page_Load(object sender, EventArgs e)
{
// .. some other c# codes
if(!Page.IsPostBack)
    txtPassword.Text  = "";
// .. some other c# codes
}

"SenthilVel" , iletisinde unu 
yazd, news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...

> hi all,
> i am running a ASP.Net 2.0 application.
> in one of the pages i have a text box which is set as PASSWORD mode.
> when the page is submitted or transfered , am not able to get the contents 
> of this textbox which is in Password mode.
>
> do we need to any more apart from setting to password mode to get the 
> value present in the text box..?
>
> do we need to do anything in specific with the viewstates if there is 
> security with ASP.Net Password text boxes?
>
> Please let me know
>
> Thanks
> Senthil
>
> 
Date:Wed, 22 Aug 2007 09:38:43 +0300   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
hi
thanks for the info ...
question:
to get the value of the password textbox , do we set the value in the 
Viewstate ? and then assign to the Value Attribute ?

Please let me know step by step ..

,,,
Senthil


"Bahadr ARSLAN"  wrote in message 
news:F0EB5D38-AD33-4D27-BFFD-DA9D8F2F38F8@microsoft.com...

> Is your password textbox created programatically?
> Check this.
>
> As Aidy said, this can be about PostBack problems. For example in your 
> Page_Load code
>
> protected void Page_Load(object sender, EventArgs e)
> {
> // .. some other c# codes
> txtPassword.Text  = "";
> // .. some other c# codes
> }
> When postback the current value will be lost, so you have to control it 
> like
> protected void Page_Load(object sender, EventArgs e)
> {
> // .. some other c# codes
> if(!Page.IsPostBack)
>    txtPassword.Text  = "";
> // .. some other c# codes
> }
>
> "SenthilVel" , iletisinde unu 
> yazd, news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...
>> hi all,
>> i am running a ASP.Net 2.0 application.
>> in one of the pages i have a text box which is set as PASSWORD mode.
>> when the page is submitted or transfered , am not able to get the 
>> contents of this textbox which is in Password mode.
>>
>> do we need to any more apart from setting to password mode to get the 
>> value present in the text box..?
>>
>> do we need to do anything in specific with the viewstates if there is 
>> security with ASP.Net Password text boxes?
>>
>> Please let me know
>>
>> Thanks
>> Senthil
>>
>>
> 
Date:Wed, 22 Aug 2007 12:35:48 +0530   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
in one of the blogs i saw a solution like :

setting txtbox.attributes("value") = txtbox.text
this was added in the preresender event of the text box...

Question:  Is this a limitation with the textbox that we need to this step 
maunally ?
is this a security feature ?

,,,
Senthil


"SenthilVel"  wrote in message 
news:OuwEirI5HHA.2752@TK2MSFTNGP06.phx.gbl...

> hi
> thanks for the info ...
> question:
> to get the value of the password textbox , do we set the value in the 
> Viewstate ? and then assign to the Value Attribute ?
>
> Please let me know step by step ..
>
> ,,,
> Senthil
>
>
> "Bahadr ARSLAN"  wrote in message 
> news:F0EB5D38-AD33-4D27-BFFD-DA9D8F2F38F8@microsoft.com...
>> Is your password textbox created programatically?
>> Check this.
>>
>> As Aidy said, this can be about PostBack problems. For example in your 
>> Page_Load code
>>
>> protected void Page_Load(object sender, EventArgs e)
>> {
>> // .. some other c# codes
>> txtPassword.Text  = "";
>> // .. some other c# codes
>> }
>> When postback the current value will be lost, so you have to control it 
>> like
>> protected void Page_Load(object sender, EventArgs e)
>> {
>> // .. some other c# codes
>> if(!Page.IsPostBack)
>>    txtPassword.Text  = "";
>> // .. some other c# codes
>> }
>>
>> "SenthilVel" , iletisinde unu 
>> yazd, news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...
>>> hi all,
>>> i am running a ASP.Net 2.0 application.
>>> in one of the pages i have a text box which is set as PASSWORD mode.
>>> when the page is submitted or transfered , am not able to get the 
>>> contents of this textbox which is in Password mode.
>>>
>>> do we need to any more apart from setting to password mode to get the 
>>> value present in the text box..?
>>>
>>> do we need to do anything in specific with the viewstates if there is 
>>> security with ASP.Net Password text boxes?
>>>
>>> Please let me know
>>>
>>> Thanks
>>> Senthil
>>>
>>>
>>
>
> 
Date:Wed, 22 Aug 2007 12:56:08 +0530   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
Hi,

No we don't need to set viewstate.
If you have a textbox like this

<asp:TextBox id="txtPass" runat="server" TextMode="Password" />

you can get its value by
txtPass.Text property.

You don't need to anything more..

"SenthilVel" , iletisinde unu 
yazd, news:OuwEirI5HHA.2752@TK2MSFTNGP06.phx.gbl...

> hi
> thanks for the info ...
> question:
> to get the value of the password textbox , do we set the value in the 
> Viewstate ? and then assign to the Value Attribute ?
>
> Please let me know step by step ..
>
> ,,,
> Senthil
>
>
> "Bahadr ARSLAN"  wrote in message 
> news:F0EB5D38-AD33-4D27-BFFD-DA9D8F2F38F8@microsoft.com...
>> Is your password textbox created programatically?
>> Check this.
>>
>> As Aidy said, this can be about PostBack problems. For example in your 
>> Page_Load code
>>
>> protected void Page_Load(object sender, EventArgs e)
>> {
>> // .. some other c# codes
>> txtPassword.Text  = "";
>> // .. some other c# codes
>> }
>> When postback the current value will be lost, so you have to control it 
>> like
>> protected void Page_Load(object sender, EventArgs e)
>> {
>> // .. some other c# codes
>> if(!Page.IsPostBack)
>>    txtPassword.Text  = "";
>> // .. some other c# codes
>> }
>>
>> "SenthilVel" , iletisinde unu 
>> yazd, news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...
>>> hi all,
>>> i am running a ASP.Net 2.0 application.
>>> in one of the pages i have a text box which is set as PASSWORD mode.
>>> when the page is submitted or transfered , am not able to get the 
>>> contents of this textbox which is in Password mode.
>>>
>>> do we need to any more apart from setting to password mode to get the 
>>> value present in the text box..?
>>>
>>> do we need to do anything in specific with the viewstates if there is 
>>> security with ASP.Net Password text boxes?
>>>
>>> Please let me know
>>>
>>> Thanks
>>> Senthil
>>>
>>>
>>
>
> 
Date:Wed, 22 Aug 2007 11:13:27 +0300   Author:  

Re: Help needed in ASP.Net 2.0 Text Box Password Mode   
hi,

i did the same way as u were saying ..just have the <asp:TextBox 
id="txtPass" runat="server" TextMode="Password" />

But once a post back is happeining or when the value in the text boz is 
accessed in a button click event , still the password is null !!

am not able to get the password value !!
do we need to do something like this ?

ViewState["Pwd"]=TextBox1.Text
TextBox1.Attributes.Add("value", ViewState["Pwd"].ToString ()) ;

,,,
Senthil

"Bahadr ARSLAN"  wrote in message 
news:D65F3B8C-523B-4600-BA3C-DC283621A459@microsoft.com...

> Hi,
>
> No we don't need to set viewstate.
> If you have a textbox like this
>
> <asp:TextBox id="txtPass" runat="server" TextMode="Password" />
>
> you can get its value by
> txtPass.Text property.
>
> You don't need to anything more..
>
> "SenthilVel" , iletisinde unu 
> yazd, news:OuwEirI5HHA.2752@TK2MSFTNGP06.phx.gbl...
>> hi
>> thanks for the info ...
>> question:
>> to get the value of the password textbox , do we set the value in the 
>> Viewstate ? and then assign to the Value Attribute ?
>>
>> Please let me know step by step ..
>>
>> ,,,
>> Senthil
>>
>>
>> "Bahadr ARSLAN"  wrote in message 
>> news:F0EB5D38-AD33-4D27-BFFD-DA9D8F2F38F8@microsoft.com...
>>> Is your password textbox created programatically?
>>> Check this.
>>>
>>> As Aidy said, this can be about PostBack problems. For example in your 
>>> Page_Load code
>>>
>>> protected void Page_Load(object sender, EventArgs e)
>>> {
>>> // .. some other c# codes
>>> txtPassword.Text  = "";
>>> // .. some other c# codes
>>> }
>>> When postback the current value will be lost, so you have to control it 
>>> like
>>> protected void Page_Load(object sender, EventArgs e)
>>> {
>>> // .. some other c# codes
>>> if(!Page.IsPostBack)
>>>    txtPassword.Text  = "";
>>> // .. some other c# codes
>>> }
>>>
>>> "SenthilVel" , iletisinde unu 
>>> yazd, news:%23dwxKLA5HHA.5212@TK2MSFTNGP04.phx.gbl...
>>>> hi all,
>>>> i am running a ASP.Net 2.0 application.
>>>> in one of the pages i have a text box which is set as PASSWORD mode.
>>>> when the page is submitted or transfered , am not able to get the 
>>>> contents of this textbox which is in Password mode.
>>>>
>>>> do we need to any more apart from setting to password mode to get the 
>>>> value present in the text box..?
>>>>
>>>> do we need to do anything in specific with the viewstates if there is 
>>>> security with ASP.Net Password text boxes?
>>>>
>>>> Please let me know
>>>>
>>>> Thanks
>>>> Senthil
>>>>
>>>>
>>>
>>
>>
> 
Date:Wed, 22 Aug 2007 14:59:41 +0530   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us