Thomas Stockbruegger
asked on
Need some help with a CString
I would like to build a CString like the following:
I want to fill the string with 2 numbers 1)doulbe 2)int
The string should always be 8 bytes long
I also want to fill the 4-6 bytes with " x "
CString A="1.50 x 1500"
or
"5.00 x 100"
"0.55 x 10"
"0.01 x 500"
|
length=8 012345678
In my old days with business basic I had a function like this one:
int y=200;
Y$ = y using "####"
double d=0.55
D$ = d using "##.##"
So I can easly build a String like this "0.55 x 200" String = D$+" x "+Y$
012345678
Is there anything in C++ that I can easy build a string with numbers?
So the string is trimed right?
Please let me know, thanks.
500 points.
Best regards,
Thomas
I want to fill the string with 2 numbers 1)doulbe 2)int
The string should always be 8 bytes long
I also want to fill the 4-6 bytes with " x "
CString A="1.50 x 1500"
or
"5.00 x 100"
"0.55 x 10"
"0.01 x 500"
|
length=8 012345678
In my old days with business basic I had a function like this one:
int y=200;
Y$ = y using "####"
double d=0.55
D$ = d using "##.##"
So I can easly build a String like this "0.55 x 200" String = D$+" x "+Y$
012345678
Is there anything in C++ that I can easy build a string with numbers?
So the string is trimed right?
Please let me know, thanks.
500 points.
Best regards,
Thomas
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Best regards from
Thomas