|
| WB19 - Can't create the Files |
| Iniciado por guest, 06,feb. 2015 04:38 - 1 respuesta |
| |
| | | |
|
| |
| Publicado el 06,febrero 2015 - 04:38 |
Hi All - can't figure out why this doesn't work - the OpenConnection creates the Database, but It won't create the file. HCreationIfNotFound responds as TRUE in the debugger, but HFileExist returns as False. I am using the HFSQL control center to look at the database, I can create the database, but not the file. Any ideas?
Thx, J
//Get the studio Code to assign Data directories gpoDB:m_sStudioID = EDT_StudioID //Studio Code like "73" IF Length(gpoDB:m_sStudioID) = 0 THEN Info("No Studio ID - Enter ID First!") RETURN END
//Connection Settings to Studio Database gpoDB:m_cnxStudioDbase..Provider = hAccessHFClientServer gpoDB:m_cnxStudioDbase..User = "Admin" gpoDB:m_cnxStudioDbase..Password = "mafa123admin" //"MAFAADMIN123" gpoDB:m_cnxStudioDbase..Database = "MAFA_MOM_"+gpoDB:m_sStudioID gpoDB:m_cnxStudioDbase..CryptMethod = hCryptNo gpoDB:m_cnxStudioDbase..Access=hOReadWrite gpoDB:m_cnxStudioDbase..Server = "<a class="ExternalLink" rel="nofollow" target="_blank" href="http://www.MartialArtsForAmerica.net">www.MartialArtsForAmerica.net</a>"
//Open Connection - Also seems to create the database itself IF HOpenConnection(gpoDB:m_cnxStudioDbase)=False THEN gpoError:CaptureError("Couldn't open connection") EndProgram END
sListOfFiles is string = HListFile("","",hLstNormal) //Creates List of files found in Analysis sFile is string iIndex is int iIndex=1 LOOP sFile=Upper(ExtractString(sListOfFiles,iIndex,CR))//extract each file
IF sFile=EOT OR sFile="" THEN BREAK END
IF NOT HCreationifNotFound(sFile) THEN gpoError:CaptureError("Error creating File") //Create File if not found in database ELSE IF HFileExist(gpoDB:m_cnxStudioDbase, sFile) THEN Trace(sFile+" Exists") END END END |
| |
| |
| | | |
|
| | |
| |
| Publicado el 06,febrero 2015 - 05:55 |
I figured it out every - Had to change the connection of the file before trying to create it!
Duh! |
| |
| |
| | | |
|
| | | | |
| | |
|