Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / December 2004

Tip: Looking for answers? Try searching our database.

PasswordChar  on TextBox in DataGridTextBoxColumn

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Brandon Owensby - 03 Dec 2004 21:09 GMT
I have used PasswordChar on a TextBox that is on a form and it works great.
You see * instead of the password and you can't cut or copy the password
out.  It doesn't work as well for a DataGrid.  If you want to look a list of
users it would be the natural thing to want to hide the password.  The setup
seems to indicate you can set the PasswordChar propery even on a TextBox in
the DataGridTextBoxControl so I assumed it would be ok.  When you go to edit
the value for that column it will show up as the character you provided and
it won't let you cut the value out...but it will let you copy  it...that is
unless you use the context menu to do it.  Is this a known problem?  Will it
be fixed in the next release?  What do I do?  Also...this isn't as big of a
problem because I have the columnstyle overridden and I was able to fix this
myself...the chosen character only masks the value when you are trying to
edit it. If you move the cursor to another cell then that cell that was
previously masked becomes unmasked.

   Thanks in advance for any help you may provide,
                                                                       Brandon
Claes Bergefall - 06 Dec 2004 08:35 GMT
Tha's because the textbox (with the password character) is only visible
for the current cell. As soon as you leave a cell the content is simply
painted by the DataGridTextBoxColumn.Paint method

.NET 2.0 provides a new grid control that might work
better in this scenario.

  /claes

> I have used PasswordChar on a TextBox that is on a form and it works great.
> You see * instead of the password and you can't cut or copy the password
[quoted text clipped - 12 lines]
>
>     Thanks in advance for any help you may provide,

Brandon
Brandon Owensby - 06 Dec 2004 15:32 GMT
Thanks for your message but I already knew what you told me about the
painting.  If you read my message again you will see I have already fixed
that part of the problem.  I was just wanting to say I noticed that problem
too so that I might find out if microsoft has already done something about
it.  I wondered if 2.0 would help with either of my two problems but I had
no proof.  The main problem is the copying and pasting.  Whats the point in
masking the password if someone can just copy it then paste it anywhere to
see it...like notepad.  This is an issue we'd like dealt with sooner than
later so we can deliver this to the client.

       Thanks,
           Brandon

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.