Hi,
I have issue with constructing file object. The Construct result is E_INVALID_ARG even for read only purpose. But file exists and contains in data fodlder.
This issue comes from SDK 2.1 in SDK 2.0 it were work fine.
Step to reproduce:
1. Star new native project with scene manager
2. When button clicked set code to create file
There code example:
String LoadFileToString(const String& filePath)
{
String buffer;
String str;
bool b = File::IsFileExist(filePath); //b is true
// Create a StringTokenizer instance
File* file = new File;
// Create file
result r = file->Construct(filePath, "r"); //Try to open it, file encoding - UTF8
AppLog("%s", GetErrorMessage(r)); //E_INVALID_ARG
// Write to the file
if (r == E_SUCCESS)
{
while (file->Read(str) == E_SUCCESS)
{
AppLog("=%S", str.GetPointer());
buffer.Append(str);
}
}
delete file;
return buffer;
}
Any advice would be appreciable.
THanks,
Nick