Article Details
Id: | 10311 |
Product: | finPOWER Connect |
Type: | NEW |
Version: | 1.06.00 |
Opened: | 13/07/2012 |
Closed: | 13/07/2012 |
Released: | 01/08/2012 |
Job: | J010001 |
Scripting; Summary Text Scripts enhanced
Summary Text type Scripts have been enhanced so that they can control more formatting details on form headers.
The following can now be set:
- Background Colour
- Title
- Title Colour
- Title Bold
- Summary
- Summary Colour
- Summary Bold
The template Script has been updated to provide an example of using the new functionality.
The following forms have been updated to support this new functionality:
- Accounts
- Clients
- Security Statements
- Workflows
The following Script will update the Accounts form header if the Account Notes start with the text '<critical>':
Public Function Main(ByVal source As Object, _
ByVal target As iseSummaryTextTarget, _
ByVal contextData1 As Object, _
ByVal contextData2 As Object, _
ByRef text As String) As Boolean
Dim Account As finAccount
Dim SummaryText As ISSummaryText
' Assume Success
Main = True
' Initialise
Account = DirectCast(source, finAccount)
SummaryText = finBL.CreateSummaryText()
' Critical Message
If StrComp(Left(Account.Notes, 10), "<CRITICAL>", CompareMethod.Text) = 0 Then
With SummaryText
.BackgroundColour = "orange"
.TitleColour = "red"
.Summary = Mid(Account.Notes, 11)
.SummaryColour = "yellow"
text = .ToXmlString()
End With
End If
End Function