Click here to Skip to main content
15,918,706 members
Home / Discussions / C#
   

C#

 
QuestionHow to hide the black console window Pin
Rajdeep.NET is BACK25-May-09 22:31
Rajdeep.NET is BACK25-May-09 22:31 
AnswerRe: How to hide the black console window Pin
stancrm25-May-09 22:45
stancrm25-May-09 22:45 
AnswerRe: How to hide the black console window Pin
Tuwing.Sabado25-May-09 22:54
Tuwing.Sabado25-May-09 22:54 
GeneralRe: How to hide the black console window Pin
Rajdeep.NET is BACK25-May-09 23:32
Rajdeep.NET is BACK25-May-09 23:32 
AnswerRe: How to hide the black console window Pin
Pete O'Hanlon25-May-09 23:06
mvePete O'Hanlon25-May-09 23:06 
GeneralRe: How to hide the black console window Pin
Rajdeep.NET is BACK25-May-09 23:34
Rajdeep.NET is BACK25-May-09 23:34 
GeneralRe: How to hide the black console window Pin
EliottA26-May-09 2:48
EliottA26-May-09 2:48 
QuestionStore neutral date in database Pin
Casper Hansen25-May-09 21:33
Casper Hansen25-May-09 21:33 
AnswerRe: Store neutral date in database Pin
stancrm25-May-09 21:35
stancrm25-May-09 21:35 
GeneralRe: Store neutral date in database Pin
Casper Hansen25-May-09 21:41
Casper Hansen25-May-09 21:41 
GeneralRe: Store neutral date in database Pin
Eddy Vluggen25-May-09 21:55
professionalEddy Vluggen25-May-09 21:55 
Question[Message Deleted] Pin
vishal moharikar25-May-09 20:59
vishal moharikar25-May-09 20:59 
AnswerRe: Message Handling in C# Pin
stancrm25-May-09 21:13
stancrm25-May-09 21:13 
GeneralRe: Message Handling in C# Pin
vishal moharikar25-May-09 21:34
vishal moharikar25-May-09 21:34 
GeneralRe: Message Handling in C# Pin
stancrm25-May-09 21:51
stancrm25-May-09 21:51 
GeneralRe: Message Handling in C# Pin
vishal moharikar25-May-09 23:31
vishal moharikar25-May-09 23:31 
QuestionHelp me with formatted int32 strings. [modified] Pin
Solid Green25-May-09 20:50
Solid Green25-May-09 20:50 
AnswerRe: Help me with formatted int32 strings. Pin
stancrm25-May-09 21:05
stancrm25-May-09 21:05 
GeneralRe: Help me with formatted int32 strings. Pin
Solid Green25-May-09 21:11
Solid Green25-May-09 21:11 
GeneralRe: Help me with formatted int32 strings. Pin
stancrm25-May-09 21:15
stancrm25-May-09 21:15 
GeneralRe: Help me with formatted int32 strings. Pin
Solid Green25-May-09 21:29
Solid Green25-May-09 21:29 
AnswerRe: Help me with formatted int32 strings. Pin
Tuwing.Sabado25-May-09 21:27
Tuwing.Sabado25-May-09 21:27 
Your going to format your interger to a predefine format.

Example 1
<br />
string outputString = (12345).ToString("ABCDE-0000000000");<br />
//Output: "ABCDE0000000000"<br />



Example 2
<br />
string outputString = (12345).ToString("ABCDED-0000000000");<br />
//Output: "ABCDED-0000012345"<br />


If your are expecting that the output of Example 1 is ABCDE-0000012345 you are wrong because "E-0" means Scientific notation.

Note: If any of the strings "E", "E+", "E-", "e", "e+", or "e-" are present in the format string and are followed immediately by at least one '0' character, then the number is formatted using scientific notation with an 'E' or 'e' inserted between the number and the exponent. The number of '0' characters following the scientific notation indicator determines the minimum number of digits to output for the exponent. The "E+" and "e+" formats indicate that a sign character (plus or minus) should always precede the exponent. The "E", "E-", "e", or "e-" formats indicate that a sign character should only precede negative exponents.

See Custom Numeric Format String[^ for more details.

Happing Coding...
GeneralRe: Help me with formatted int32 strings. Pin
Solid Green25-May-09 21:35
Solid Green25-May-09 21:35 
GeneralRe: Help me with formatted int32 strings. Pin
Tuwing.Sabado25-May-09 21:54
Tuwing.Sabado25-May-09 21:54 
GeneralRe: Help me with formatted int32 strings. Pin
stancrm25-May-09 21:58
stancrm25-May-09 21:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.