Sunday, 16 January 2022

How To Convert/Change Number 1 To 0000001 In C#.Net | Add Prefix With Zero In C#.Net

1/16/2022 - By Pranav Singh 0

In this article i will show how you can convert a number like 1 to 00001 or add prefix with zero using c#.net.  Now here is the tip to perform one liner code to convert 1 to 00001 using c#.net.

  int number = 1;

  string newvalue = String.Format("{0:D6}", number);

Now here is the output.

Output: 0000001

About the Author

We are the group of people who are expertise in different Microsoft technology like Asp.Net,MVC,C#.Net,VB.Net,Windows Application,WPF,jQuery,Javascript,HTML. This blog is designed to share the knowledge.

Get Updates

Subscribe to our e-mail newsletter to receive updates.

Share This Post

0 comments:

Please let me know your view

Free Ebooks


About Us

We are the group of people who are expertise in different Microsoft technology like Asp.Net,MVC,C#.Net,VB.Net,Windows Application,WPF,jQuery,Javascript,HTML. This blog is designed to share the knowledge.

Contact Us

For writing article in this website please send request by your

GMAIL ID: dotnetpools@gmail.com

Bugs and Suggestions

As we all know that this website is for sharing knowledge and providing proper solution. So while reading the article is you find any bug or if you have any suggestion please mail us at contact@aspdotnet-pools.com.

Partners


Global Classified : Connectseekers.com
© 2014 aspdotnet-pools.com Designed by Bloggertheme9.
back to top