Original questions was quite abstract and as you can see solution based on string replace will fail if parameter would be string with '%' character inside. We don't know what is the real intention and maybe building another strFmt is what he really needs. Solution proposed by me does not looks so short and nice but it does not have this issues as well. So what do you prefer nice but limited solution or big and fully functional ?
↧