---
title: "how to use mask textbox in C#?"  
description: "how to use mask textbox in C#?"  
author: "Kate Smith"  
published: 2013-06-15  
updated: 2013-07-08  
canonical: https://www.mindstick.com/forum/1142/how-to-use-mask-textbox-in-c-sharp  
category: "c#"  
tags: ["c#"]  
reading_time: 1 minute  

---

# how to use mask textbox in C#?

Hi [Expert](https://www.mindstick.com/articles/13120/an-expert-financial-advice-will-improve-your-finances),\
how to use [mask](https://answers.mindstick.com/qa/39777/who-wrote-the-man-in-the-iron-mask) [textbox](https://www.mindstick.com/forum/12714/dynamic-textbox-in-gridview) in C#?\
Thanks in advance.

## Replies

### Reply by Vijay Shukla

Hi Kate!\
Drag and drop Mask **Textbox** from the toolbox and set the **Mask Property** as per your requirement. E.g. if you want to set number as input format then set the 00000 (length as your required) mask property.\
You can get the help from the following link\
[http://msdn.microsoft.com/en-us/library/system.windows.forms.maskedtextbox.validatingtype.aspx](http://msdn.microsoft.com/en-us/library/system.windows.forms.maskedtextbox.validatingtype.aspx)\
I hope it resolve your problem.


---

Original Source: https://www.mindstick.com/forum/1142/how-to-use-mask-textbox-in-c-sharp

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
