Changes between Version 8 and Version 9 of Docs/Prog/Manual/ApplicationLibraries/lib825ev/String/StrFmt
- Timestamp:
- 04/13/23 06:59:25 (20 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Docs/Prog/Manual/ApplicationLibraries/lib825ev/String/StrFmt
v8 v9 4 4 {{{ 5 5 string StrFmt(const char* pszFmt, ...); 6 7 void StrFmt(string& str, const char* pszFmt, ...); 6 8 }}} 7 9 … … 29 31 }}} 30 32 33 The version of StrFmt shown below that takes a reference to the string as a parameter is more efficient. This is because it doesn't have to create the string, and pass it as a return value to tbe recreated. 34 {{{ 35 int nVal = 123; 36 string strID = "ABC"; 37 38 string strMsg; 39 StrFmt(strMsg, "Number: %d ID: %s", nVal, strID.c_str()); 40 }}} 41 31 42 32 43 == See Also ==