Click here to Skip to main content
15,887,596 members
Home / Discussions / C#
   

C#

 
GeneralRe: Unmanaged DLL: C# variable for C++ char** Pin
Luc Pattyn13-Jul-09 10:04
sitebuilderLuc Pattyn13-Jul-09 10:04 
GeneralRe: Unmanaged DLL: C# variable for C++ char** Pin
belier113-Jul-09 11:07
belier113-Jul-09 11:07 
GeneralRe: Unmanaged DLL: C# variable for C++ char** Pin
Luc Pattyn13-Jul-09 11:12
sitebuilderLuc Pattyn13-Jul-09 11:12 
GeneralRe: Unmanaged DLL: C# variable for C++ char** Pin
belier114-Jul-09 1:10
belier114-Jul-09 1:10 
QuestionGet local groups and users from server remotely with console app Pin
briancollins3213-Jul-09 6:50
briancollins3213-Jul-09 6:50 
QuestionHow do you count the number of decimals in a decimal datatype Pin
Nathan Revka13-Jul-09 6:26
Nathan Revka13-Jul-09 6:26 
AnswerRe: How do you count the number of decimals in a decimal datatype Pin
Luc Pattyn13-Jul-09 6:34
sitebuilderLuc Pattyn13-Jul-09 6:34 
AnswerRe: How do you count the number of decimals in a decimal datatype Pin
musefan13-Jul-09 6:51
musefan13-Jul-09 6:51 
well if you are using a textbox then you will need a number of different validations...

1. Check the currency symbol exists only once and is the first character, if not present you should auto add it
2. Check there is only 1 decimal point
3. Check for any , symbols you may want to include and insure they are in the right places
4. Check only two digits after the decimal place...

if(text.LastIndexOf('.') != text.Length - 3)
//not two digits after the decimal point

...there are other validations you may want to try and other methods to calculate the number of digits after a decimal.

you could also use a NumericUpDown control which has a property to set how many decimal places you wish to use, in addition to choosing if you want to you commas for thousand seperators

Life goes very fast. Tomorrow, today is already yesterday.

AnswerRe: How do you count the number of decimals in a decimal datatype Pin
TheGreatAndPowerfulOz13-Jul-09 6:51
TheGreatAndPowerfulOz13-Jul-09 6:51 
QuestionDccg Pin
peishen8813-Jul-09 5:47
peishen8813-Jul-09 5:47 
AnswerRe: Dccg Pin
Luc Pattyn13-Jul-09 5:54
sitebuilderLuc Pattyn13-Jul-09 5:54 
GeneralRe: Dccg Pin
DoctorMick13-Jul-09 5:58
DoctorMick13-Jul-09 5:58 
GeneralRe: Dccg Pin
peishen8813-Jul-09 6:10
peishen8813-Jul-09 6:10 
GeneralRe: Dccg Pin
Luc Pattyn13-Jul-09 6:33
sitebuilderLuc Pattyn13-Jul-09 6:33 
QuestionHorizontal scrollbar broken in datagrid after migrating to VS2008 Pin
smcirish13-Jul-09 4:47
smcirish13-Jul-09 4:47 
Question2 dimensional byte array Pin
Vivek Vijayan13-Jul-09 4:19
Vivek Vijayan13-Jul-09 4:19 
AnswerRe: 2 dimensional byte array Pin
harold aptroot13-Jul-09 4:51
harold aptroot13-Jul-09 4:51 
GeneralRe: 2 dimensional byte array Pin
Vivek Vijayan13-Jul-09 5:07
Vivek Vijayan13-Jul-09 5:07 
GeneralRe: 2 dimensional byte array Pin
0x3c013-Jul-09 5:13
0x3c013-Jul-09 5:13 
GeneralRe: 2 dimensional byte array Pin
Vivek Vijayan13-Jul-09 5:51
Vivek Vijayan13-Jul-09 5:51 
GeneralRe: 2 dimensional byte array Pin
Luc Pattyn13-Jul-09 5:56
sitebuilderLuc Pattyn13-Jul-09 5:56 
Questionhow to log activity on windows based systems Pin
tamamm13-Jul-09 4:00
tamamm13-Jul-09 4:00 
AnswerRe: how to log activity on windows based systems Pin
Mirko198013-Jul-09 4:09
Mirko198013-Jul-09 4:09 
GeneralRe: how to log activity on windows based systems Pin
Dave Kreskowiak13-Jul-09 4:38
mveDave Kreskowiak13-Jul-09 4:38 
GeneralRe: how to log activity on windows based systems Pin
tamamm13-Jul-09 5:11
tamamm13-Jul-09 5:11 

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.