In the SNAP Library there's a method that allows me to save a file in my pc here it is:
TSnap::SaveEdgeList(G, q, "Edge list format");`
In this function the 2nd argument its type is TStr which represents string types in SNAP library
I have a string^
variable that contains a full directory of where I want to put my file like this (P.S: it contains only one backslash so i have to replace it with double backslash)
string^ filename = openFileDialog1->FileName;
Then i convert filename variable of type string^
to std::string
like this:
std::string s = filename->ToString;
What I want to do is to give the content of the string variable s
to a TStr variable and with the help of of fellow members here i did like this:
TStr q = s.c_str();;
But unfortunately it still gives an error:
error C3867: 'System::String::ToString': non-standard syntax; use '&' to create a pointer to member
Does anyone have a suggestion, or an alternative solution, or something?