#how can i this to work properly

16 messages · Page 1 of 1 (latest)

raven lilyBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

royal bone
#

what do you expect that to do exactly?

#

what exactly do you want that line to do

#

why use << instead of =

#

try a + instead

#

ah right because it's a c-style array

#

hm

#

make path into a std::string or std::wstring first

#

whats the error

#

try this specifically ```cpp
std::string FileName = std::string(path) + "/Roaming/PopstarDevs/2take1Menu/scripts/melancholia-script-V4.luac";

#

std::wstring doesnt work either right?

#

huh

#

why do you use a wchar_t path[MAX_PATH] instead of a std::wstring in the first place?

#

well

#

heres an idea, maybe it'll work```cpp
std::wstring path;
HRESULT result = SHGetFolderPathW(NULL, CSIDL_APPDATA, NULL, 0, path.data());

if (result != S_OK) {
// ...
}
std::wstring FilePath = path + "/Roaming/PopstarDevs/2take1Menu/scripts/melancholia-script-V4.luac";
// ...
```im not sure if NULL can be replaced with nullptr

#

i give up