简体   繁体   中英

How to access the “Title” of a file from a BIM 360 “Plans” folder

We need to get the "Title" as seen here in the Plans folder of the Document Management page of BIM 360.

So far I can only find it at version.Value.attributes.extension.data.viewableName where version is initialized as follows

ItemsApi itemApi = new ItemsApi();
itemApi.Configuration.AccessToken = Credentials.TokenInternal;
var versions = await itemApi.GetItemVersionsAsync(projectId, itemId);
foreach (KeyValuePair<string, dynamic> version 
    in new DynamicDictionaryItems(versions.data)) 
{
    var vieawbleName = version.Value.attributes.extension.data.viewableName
    ...
}

But it isn't always there. If it is there, viewableName will contain something like "A1.00 - SITE SURVEY", where "A1.00" is the "Number" of that item/version, and "SITE SURVEY" is the "Title". The issue is that most of the time, viewableName will only contain "Number" not "Number - Title".

Is there a way to get the "Title" consistently? Ideally, we would like to see the title for each version, in case it is changed from one version to the next.

Unfortunately, the title attribute is built via BIM360 custom attributes feature, and there is no API available to fetch it currently as I know. Sorry for the bad news.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM