CalebH

ProcessBook Add-In, display.Close(False) not working in ProcessBook 2012 SP1

Discussion created by CalebH on May 23, 2013
Latest reply on Dec 3, 2014 by CalebH

Hello,

 

I have a ProcessBook Add-In that opens and closes embedded displays in a PIW workbook via a VB.NET windows form opened from a toolbar button.  This add-in works fine in ProcessBook 3.2:  clicking a button on the form will open and close the desired displays behind the still-open form, as designed.

 

In ProcessBook 2012 Sp1 (3.3.1.1160), however, the displays will not close while my Add-In form is open.  Once I close the Add-In form, all the displays that were supposed to already be closed then start to close.  Is there a reason why the behavior would be different in these two versions of ProcessBook?  Is there a known workaround for getting the behavior seen in ProcessBook 3.2 to work in ProcessBook 2012?

 

Here are some code excerpts from the project (VB.NET 3.5):

 
Dim entries as Entries = procBook.Entries
Dim entry As Entry = Nothing
For index as Integer = 1 to entries.Count
    entry = entries.Item(index)
    Dim display As Display = Nothing
    If CType(entry.Type, pbEntryLinkType) = pbEntryLinkType.pbEntryPDIEmbeddedInLocalPIW Then
        entry.Execute(True)
        display = procBook.Application.ActiveDisplay
        display.Close(False)    'doesn't work in PB 2012 SP1 until after Add-In form is closed
        display = Nothing
    End If
Next

 Thanks,
Caleb

Outcomes