Hi All.
What I need is to create a folder inside LiveLink project using LAPI in C++. I use "LL_CreateObjectEx" function for creating project and "LL_CreateFolder" for folder. The expected result is the folder as child of project, but it is displayed as a subproject object.
Here is the source:
LL_Initialize( LL_HEADER_VERSION );
LL_SessionAllocEx( &session, m_repositoryName, m_nPort, _T("livelink"), m_userName, m_password, NULL );
LL_ValueAlloc( &objectInfo );
LL_ValueAlloc( &createInfo );
LL_ValueSetAssocInArgs( createInfo );
LL_AccessEnterpriseWS( session, objectInfo );
LL_AssocGetInteger( objectInfo, "ID", &parentID );
LL_AssocGetInteger( objectInfo, "VolumeID", &parentVol );
LL_CreateObjectEx( session, parentVol, parentID, LL_OBJECTTYPE, LL_PROJECTSUBTYPE, "Project1", createInfo, objectInfo ); //// project is created correctly
LL_AssocGetInteger( objectInfo, "ID", &parentID );
LL_CreateFolder( session, parentVol, parentID, "Folder1", objectInfo ); //This creates a subproject folder
If I create the folder manually it appears as simple subfolder. The question is what should I do to create a folder in a project that is not a subproject?
Thanks in advance,
Alexander.
What I need is to create a folder inside LiveLink project using LAPI in C++. I use "LL_CreateObjectEx" function for creating project and "LL_CreateFolder" for folder. The expected result is the folder as child of project, but it is displayed as a subproject object.
Here is the source:
LL_Initialize( LL_HEADER_VERSION );
LL_SessionAllocEx( &session, m_repositoryName, m_nPort, _T("livelink"), m_userName, m_password, NULL );
LL_ValueAlloc( &objectInfo );
LL_ValueAlloc( &createInfo );
LL_ValueSetAssocInArgs( createInfo );
LL_AccessEnterpriseWS( session, objectInfo );
LL_AssocGetInteger( objectInfo, "ID", &parentID );
LL_AssocGetInteger( objectInfo, "VolumeID", &parentVol );
LL_CreateObjectEx( session, parentVol, parentID, LL_OBJECTTYPE, LL_PROJECTSUBTYPE, "Project1", createInfo, objectInfo ); //// project is created correctly
LL_AssocGetInteger( objectInfo, "ID", &parentID );
LL_CreateFolder( session, parentVol, parentID, "Folder1", objectInfo ); //This creates a subproject folder
If I create the folder manually it appears as simple subfolder. The question is what should I do to create a folder in a project that is not a subproject?
Thanks in advance,
Alexander.