Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Document Subclasses
System
Has anyone ever tried via code to get to document subclasses? I'm running code that first gets the document class, which in my case is "CLIENT" and then tried to get the document subclasses for the CLIENT class. The count returns 0. I tried to pick "FIRM" and interestingly enough, it only returns 1 subclass called "FIRM_MANAGEMENT" which just happens to contain FIRM in the name. Unfortunately there are 8 subclases for "FIRM". We are not requiring subclasess either. Any ideas?? Thanks!
Dim DocClasses As IManage.NRTDocumentClasses
Dim DocClass As IManage.NRTDocumentClass
Dim SubDocClasses As IManage.NRTDocumentClasses
Dim SubDocClass As IManage.NRTDocumentClass
'cboclass.text contains the picked document class
Set DocClasses = Activedb.SearchDocumentClasses(cboClass.Text, nrSearchBoth, True, overflow)
Set DocClass = DocClasses.Item(1)
Set SubDocClasses = DocClass.GetSubClasses(vbNullString, nrSearchID, True, overflow)
'loop through subclasses of picked class
For Each SubDocClass In SubDocClasses
cboSubclass.AddItem SubDocClass.Name
Next
Find more posts tagged with
Comments
jny
The problem might be in using vbNullString. I used "" to indicate an empty string which is different from a Null string, and all the subclasses belonging to the class are returned.