Mega Code Archive

 
Categories / Visual C++ .NET / Data Type
 

Remove text from strings

#include "stdafx.h" using namespace System; void main() {     String^ s1 = "This will ";     String^ s2 = "be a ";     String^ s3 = "String";     s1 = s1->Remove(4, 5);       s2 = s2->Remove(0, 3);       Console::WriteLine(String::Concat(s1, "is ", s2, s3)); }