Click here to Skip to main content
15,884,388 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hello guys,

I am confused here in the coding part of automatic number generation, and also tell me how can I combine the numbers with alphabets and current date.
I need the code. Can anyone help me out?
Posted
Updated 29-Nov-11 21:29pm
v2
Comments
Savalia Manoj M 30-Nov-11 3:33am    
Plz Specify which format you want? like 0001-Acc-11/30/2011 etc.

1 solution

I agree: you are confused.
What kind of 'automatic number generation' are you talking about?
Should the numbers be unique?
Should they be ordered, or, maybe, sequential?
If you need to combine 'alphabets and current date' then you probably have to generate (possibly unique) identifiers, i.e. strings not numbers.
Why don't you just use an available tool for generating unique id, like for instance guidgen[^]?
 
Share this answer
 
Comments
jus coding 30-Nov-11 3:54am    
i want to generate it in sequence so can u jus help me out.i need the complete coding
CPallini 30-Nov-11 4:00am    
You should produce complete code. We may just help you a bit.
Generating a sequence of numbers is pretty straightforward (a counter is enough). If you need the application remembering the last generated number then you should add persistence to it, see, for instance
http://www.developer.com/tech/article.php/2222431/Building-Persistence-into-NET-Programs.htm

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900