Here's a c++ library snippet that could be useful for string formatting (sorry, can't find how to add code tags):

#ifndef STRINGFORMAT_H
#define STRINGFORMAT_H

const char newln    { '\n' };
const char tab      { '\t' };
const char bs       { '\b' };
const char apo      { '\'' };
const char quote    { '\"' };
const char questn   { '\?' };
const char bslash   { '\\' };

#endif

You insert code by using the </> tool or by indenting everything one tab (or four spaces).

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.