I've commandLine arguments in a C++/CLI program denoted by char* argv[]. I want to transfer all the contents getting concatenated to a String^ class.
Code:
String ^masterString = "Commands=>";
for(int i=0; argv[i] != nullptr; ++i)
masterString += String(argv[i]);
However, I find the above not working in the last statement where I use +=
operator.
What's the wrong usage here? Error here is No operators match the operands.
Any other better ways to store contents into String^ from char*?
Look into MSDN, mostly into this:
btw: I didn't check this. Just googled it. But, I think, this would work, cause it posted in MSDN.