Integra for Notes Banner
  QuickReports Integra4Notes Integra Family of Products

Integra Script Library Documentation


Context:

General

Library/Class:

Sample Code



Default structure of advanced callback script explained As Integer, Read/Write

The default advanced callback script basically provides a select construct for the different Integra events. The developer can insert custom script coding beneeth each event case. The occurance of events depends on various settings of the Integra profile. The following 2 table show the availability and occurance of Integra's runtime events. Please refer to the Developers Manual for more detailed explanations to the events as such. Further down you will find the default code structure with a short explanation as to the use of each event.


Table 1 - Availability & Occurance

Event
Export
Import
Occurance
Since Version
CB_INITIALISE
ü
ü
Once
2.0
CB_ACTIONONLY
ü
Once
4.2
CB_BFOREXPORT
ü
Once
3.0
CB_BFORIMPORT
ü
Once
3.0
CB_INVALID
ü
For every invalid view entry
4.3
CB_CATEGORY
ü
For every category entry
4.3
CB_TOTAL
ü
Once, if view shows totals
4.3
CB_CONFLICT
ü
For every conflict entry
4.3
CB_BFORREADNOTES
ü
For every document entry
2.0
CB_BFORREADCOM
ü
For every Excel row or Word document
2.0
CB_BFORWRITECOM
ü
Once for Single Document exports, otherwise
for every Notes document entry.

Note: usefulness of this event is limited when NOT using the Advanced COM export method
2.0
CB_AFTERWRITECOM
ü
Once for Single Document exports, otherwise
for every Notes document entry.

Note: usefulness of this event is limited when NOT using the Advanced COM export method
4.1
CB_BFORWRITENOTES
ü
For every Notes document created during the import
2.0
CB_BFORCOMACTION
ü
Once

Note: usefulness of this event is limited for Word profiles using the Advanced COM export method with the Print option. The event will be called for the last printed Word document only!
2.0
CB_BFORNOTESACTION
ü
See table 2
2.0
CB_TERMINATE
ü
ü
Once
2.0


Table 2 - Occurance of the CB_BFORNOTESACTION event (precedence on order of Setting)

SettingOccurance
Excel ExportOnce
Normal ExportOnce
Single DocumentOnce
Send To, Confirm or MemoOnce
Merge Option = Collect...Once
OtherwiseFor every Notes document entry


' Default advanced script for export profiles
Const CB_INITIALISE = 3
Const CB_ACTIONONLY = 16
Const CB_BFOREXPORT = 10
Const CB_INVALID = 12
Const CB_CATEGORY = 13
Const CB_TOTAL = 14
Const CB_CONFLICT = 15
Const CB_BFORREADNOTES = 6
Const CB_BFORWRITECOM = 1
Const CB_AFTERWRITECOM = 9
Const CB_BFORCOMACTION = 5
Const CB_BFORNOTESACTION = 2
Const CB_TERMINATE = 4

select case stats.cbstatus
case CB_INITIALISE
case CB_ACTIONONLY
case CB_BFOREXPORT
case CB_INVALID
case CB_CATEGORY
case CB_TOTAL
case CB_CONFLICT
case CB_BFORREADNOTES
case CB_BFORWRITECOM
case CB_AFTERWRITECOM
case CB_BFORCOMACTION
case CB_BFORNOTESACTION

    if not stats.savdoc is nothing then
      ' before save as...
    else
      ' before send to
    end if

case CB_TERMINATE
end select


' Default advanced script for import profiles
Const CB_INITIALISE = 3
Const CB_BFORIMPORT = 11
Const CB_BFORREADCOM = 7
Const CB_BFORWRITENOTES = 2
Const CB_TERMINATE = 4

select case stats.cbstatus
case CB_INITIALISE
case CB_BFORIMPORT
case CB_BFORREADCOM
case CB_BFORWRITENOTES
case CB_TERMINATE
end select

Note: in earlier versions of Integra for Notes the event CB_BFORWRITENOTES was called CB_BFORNOTESACTION. However, the value of the constant is the same and therefore both event names (constants) can be used.


Using the following properties of the stats, import & export objects a profile developer can not only manipulate the data being imported or exported, but can control whether and how Integra continues its processing:

Export ProfilesImport Profiles
export.continue
stats.procstat
import.continue
stats.procstat
 
QUICK LINKS
 
 

 

  © Shireburn Software Ltd. 2008 - 2024