How to use StrFmt in Borland C++ Builder

I've beent trying to format a postcode of the form B17 9BN as B017 9BN using StrFmt.
Could somebody show me how to do this with C++ Builder?

Regards
Mark Tindill
MTindillAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
RideOnConnect With a Mentor Commented:
Why do you use StrFmt?
Do you HAVE to use this function?
0
 
RideOnCommented:
if i'd be you, i would take sprintf
0
 
MTindillAuthor Commented:
Whatever works.
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
MTindillAuthor Commented:
How do I use "sprintf" then to accomplish the above without having to specify each individual element a character array to match the format specifiers.
i.e sprintf(buffer, "%c0%c%c%c%c%c%c%c\0", <what-goes-here?>);
0
 
LoungeLizardCommented:
In what format is the postcode? Is it a string of individual characters?
0
 
MTindillAuthor Commented:
Yes.
0
 
MoondancerCommented:
Has this been resolved or is more needed here?

Moondancer
Community Support Moderator @ Experts Exchange
0
 
MTindillAuthor Commented:
Thanks RideOn. Profuse apologies for the "small" delay in awarding points.

Regards
mtindill
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.