Remarks | Properties | Methods | Events | Samples |
ED
|
avaliable
|
RT
|
avaliable
|
The PfsEngine object is the entry point into the Pfs object model. With the property CountryName you can define the country for the holiday definition. The method events returns a list of the user-defined events. The Groups method returns the definition of the existing PFS equipments.
CountryName | Parent |
Events | Groups | Holidays |
Save |
''''''''''''''''''''''''''''''''''''''''''''' ''''''Define PFS Engine with Events!''''''''' ''''''''''''''''''''''''''''''''''''''''''''' Dim WithEvents myPFS As PfsEngine ''''''''''''''''''''''''''''''''''''''''''''' ''''''''Define Events for PFS Engine''''''''' ''''''''''''''''''''''''''''''''''''''''''''' Private Sub myPFS_OnCreateGroup(ByVal obNewGroup As IPfsGroup) Debug.Print "myPFS_OnCreateGroup " & " " & obNewGroup.Name & " was created!" End Sub Private Sub myPFS_OnCreateEvent(ByVal obNewEvent As IPfsEvent) Debug.Print "myPFS_OnCreateEvent " & " " & obNewEvent.Name & " was created!" End Sub ''''''''''''''''''''''''''''''''''''''''''''' ''''''''''Excecute the defined Events,''''''' '''''''''''by creating new objects''''''''''' ''''''''''''''''''''''''''''''''''''''''''''' Sub TestEvents() Set myPFS = MyWorkspace.ActiveDocument.Pfs myPFS.Groups.CreateGroup ("TestGroup1") myPFS.Events.CreateEvent ("TestEvent1") End Sub ''''''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''Creation of a PFS Engine object''''''''''''' '''''''''''''''Giving out Group Names'''''''''''''''' ''''''''''''''''''''''''''''''''''''''''''''''''''''' Private Sub EnumGroups() Dim i As Double Dim myPFS As PfsEngine Set myPFS = MyWorkspace.ActiveDocument.Pfs For i = 0 To myPFS.Groups.Count - 1 Debug.Print myPFS.Groups.Item(i).Name Next i End Sub