Solved

VB.net/VBA Typing password into text box (making it invisible)

Posted on 2013-01-16
4
637 Views
Last Modified: 2013-01-21
Hi

I have two text boxes  in my application that the user uses to log in
In the second password box I don't want the password to be visible but
instead I'd like dots or x's to appear.

How should do this?

Thanks
0
Comment
Question by:murbro
4 Comments
 
LVL 16

Assisted Solution

by:Imran Javed Zia
Imran Javed Zia earned 167 total points
ID: 38786053
Hi,
If you are working in Winforms then you can either use textmast of textbox control or better to use PasswordBox control
Thanks
0
 
LVL 11

Assisted Solution

by:Deepak Lakkad
Deepak Lakkad earned 167 total points
ID: 38786072
For ASP.Net there is TextMode property for TextBox. You can use it in following way.

<asp:TextBox id="tb2" TextMode="password" runat="server" />

Open in new window


For WinForms, there is PasswordChar Property for TextBox. You can set any character in this property. The character will appear in textbox in place of your actual text.

- Deepak Lakkad
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 166 total points
ID: 38786145
Set the PasswordChar property of Textbox to any character you want such as * or x

http://msdn.microsoft.com/en-us/library/system.windows.forms.textbox.passwordchar.aspx
0
 

Author Closing Comment

by:murbro
ID: 38800626
thanks for the help
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction This Article is a follow-up to my Mappit! Addin Article (http://www.experts-exchange.com/A_2613.html), it was inspired by an email posting I made to EUSPRIG (http://www.eusprig.org/index.htm), I will briefly cover: 1) An overvie…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now