Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Enabling and disabling custom fields using SDK
David_ISA
Is there any way, using the Worksite SDK, to enable and disable the custom field values? eg. custom1 and custom2.
I know you can set the enabled flag on a custom field value when you create it using the imanadmin.dll but you can't seem to enable or disable an existing value.
Thanks in advance.
Find more posts tagged with
Comments
jny
Below is a sample code snippet that uses the ModifyParentCustomField method to make changes to the specified custom attributes. The last Boolean Parameter is used to enable/disable the field.
You must have IManAdmin.dll v8.0.4 and forwards in order to be able to consume these methods.
[VB.NET]
Dim aDMS As New IMANADMIN.NRTDMS
Dim aSess As NRTSession = aDMS.Sessions.Add("")
aSess.Login("", "")
Dim adb As NRTDatabase = aSess.Databases.Item("")
'Dim adb As INRTDatabase2 = aSess.Databases.Item("")//Use in 8.0.4 and 8.1
' Update parent field; arbitrary example values
Dim curClient = "MY_CLIENT"
Dim newClient = "AUTO"
Dim newClientDesc = "Automobile"
adb.ModifyParentCustomField(AttributeID.nrCustom1, curClient, newClient, newClientDesc, True)
' Update child field
Dim curMatter = "MY_MATTER"
Dim newMatter = "SUV"
Dim newMatterDesc = "Sports Utility Truck"
adb.ModifyChildCustomField(AttributeID.nrCustom2, curClient, curMatter, newClient, newMatter, newMatterDesc, True)
TestReport.rptdesign
David_ISA
Ahh, i was using version 8.0.3 of the imanadmin.dll. I'll try these methods in 8.0.4.
Many thanks.
David_ISA
Where exactly do i get version 8.0.4 of iManAdmin?
I've used ModifyParentCustomField with version 8.2.11 of iManAdmin successfully but this version does not work with 8 server.
On the Interwoven partner site you can download the 8 iToolkit but it has 8.0.3 of iManAdmin and not 8.0.4.
Thanks.
jny
I believe it's in the 8.0SP1 SDK. Best to check with Tech Support.