void TakeData(myStruct &structRef)
CString str = TmpFileMgr->TmpFilePathName() ; //Returns file path
structRef.cstrFilePath = str ; //Crashes at this point on Windows 7
in a dll which takes Temporary folder path and assign it in a CString variables. This CString variable is member of structure object which is passed as a reference to TakeData(myStruct &structRef)function.
I am able to print temporary folder path in TakeData function and CString assigment works perfectly on Windows XP. But when I run this code on Windows 7 it crashes at the point where I am doing assigment of temp folder path in a CString variable. I have all admin rights on Windows 7 System , also I have put UAC to OFF.