Get full path of a file.
string GetFullPath( LPCSTR lpcszFileName, LPCSTR lpSubPath = NULL, BOOL bLocalized = FALSE )
If the file was found then a string containing the full path file name is returned else an empty string is returned.
EX1
void GetFullPath_ex1() { string strFile = "origin.ini"; string strFullPath = GetFullPath(strFile); if( !strFullPath.IsEmpty() ) { string strPath = GetFilePath(strFullPath); printf("File %s was found in %s folder.\n", strFile, strPath); } }
Search Origin's client and then server path to return the full path name of the specified file.
This function will separately look for server and client path only if Origin is a network version. For single user version, this function will simply return the full path from Origin's software path.
origin.h