Connecting with OLE

Connecting with OLE



Code examples in VB / VBA OLE and Pascal Scripting OLE below show examples of OLE access to the API.



API Calls



VB/VBA (OLE)

Using IItem Object Model
Sub main()
    Dim planswift = CreateObject("PlanSwift9.PlanCenter")
    Dim settings = planswift.GetItem("\Settings")
    Dim property = settings.GetProperty("AllowExtenderDPI")
    Console.WriteLn(property.ResultAsBoolean());
End Sub
Using PlanSwift Object Model
Sub Main()
    Dim planswift = CreateObject("PlanSwift9.PlanCenter")
    Dim nameProperty = planswift.GetProperty("\Settings","AllowExtenderDPI")
    Console.WriteLn(property.ResultAsBoolean)
End Sub

Pascal Scripting (OLE)


Item Object Model
begin
    settings := getItem('\Settings');
    ShowMessage(GetResultAsBoolean(settings,'AllowExtenderDPI'));
end
Root Object Model
begin
   ShowMessage(GetResultAsBoolean('\Settings','AllowExtenderDPI'));
end


Copyright 2022 ConstructConnect