Where Are The Branches, Man?
I'm more interested in VB6 than scripting since the explanations for scripting provided with V9.3 were woefully inadequate.
Here is the question: where can we find the hierarchical breakdown and full explanations of all "btapp" methods and properties?
Here is the question: where can we find the hierarchical breakdown and full explanations of all "btapp" methods and properties?
0
-
I take it you mean automation programming rather than the use of VB scripting from within BarTender?
We have a full reference for this in the BarTender Help system, just as we did for v9.30, so I'm not sure about your comment.
It should be noted however that the code examples we give are using VB.NET and C# and so you will need to make changes to account for the different syntax. When using VB6 you should refer to the ActiveX (COM) reference.
Using Visual Basic 6.0
All of the examples in this help are for VB.NET or C#. If you are using Visual Basic 6.0, you will have to adapt the VB.NET examples to the Visual Basic 6.0 syntax. Here are some general points to keep in mind:
The Application object is a top level object in BarTender hierarchy. It references other BarTender objects and can be used to set application wide options.
To access the Application object from Visual Basic, you must perform the following steps.
Set a reference to the BarTender application.
This can be done from Visual Basic by selecting References from the Project menu, and selecting BarTender from the Available References list box. If you are using Visual Basic for Applications (i.e. supported by Microsoft Office Suite and other programs), the References dialog can be found in the Tools menu.
Declare an object variable of type BarTender.Application using the Dim command.
Start a new BarTender, or access a running BarTender, by creating (or getting) a reference to the BarTender Application object and setting it to the object variable defined in the step above.
Quit the BarTender application using the Application.Quit method of the Application object.
For example, the following Visual Basic 6.0 code will start a new copy of BarTender and quit:
[code]
Dim btApp As BarTender.Application
Set btApp = CreateObject("BarTender.Application")
btApp.Quit
[/code]
If you would like to reference a BarTender application that is already running then use the GetObject function in place of the CreateObject function.
Now that you have an application object with which to work, you can set many of its properties to control the global behavior of BarTender. For example, the following code makes BarTender visible after it has been started.
[code]
Dim btApp As BarTender.Application
Set btApp = CreateObject("BarTender.Application")
btApp.Visible = true
[/code]0
Vous devez vous connecter pour laisser un commentaire.
Commentaires
1 commentaire