This function is called each time HotDocs updates the list of items in the library window. For example, when an item is added or removed from the library, HotDocs updates the list of items and calls UpdateLibraryEntry for each item in the library.
UpdateLibraryEntry ( LibraryEntity pItem , bool bMultithreaded )
Parameters | Description |
pItem | The library item to update. |
bMultithreaded | Indicates whether the updates should occur on separate threads or consecutively on the same thread. |
The following Visual C# example adds an overlay icon to each HPT template in the library.
public void UpdateLibraryEntry(LibraryEntity pItem, bool bMultithreaded) { HotDocs.Icon icon = new HotDocs.Icon(); icon.LoadIcon(@"C:\images\hptIcon.ico"); HotDocs._LibraryEntity2 pItem2 = (HotDocs._LibraryEntity2)pItem; if (System.IO.Path.GetExtension(pItem2.TemplateFullPath.ToLower()) == ".hpt") { pItem2.OverlayIndex = 1; } else pItem2.OverlayIndex = -1; System.Runtime.InteropServices.Marshal.ReleaseComObject(icon); }