Python Scripting in BasicMaker

Post your questions, bug reports and suggestions here for BasicMaker 2012 for Windows.

Moderator: SoftMaker Team

Posts: 17
Joined: Tue Jan 22, 2013 12:56 pm

Python Scripting in BasicMaker

Postby TonyDaly » Mon May 04, 2015 1:46 pm

The web site page for BasicMaker states "If you wish to create scripts for SoftMaker Office in languages other than BASIC, you can! TextMaker and PlanMaker can be scripted in many programming languages, including as Python, Perl, Ruby, C++, and Delphi." I've searched the manual and help, but can't find any guidance on scripting in Python. Is there any documentation available for this?

SoftMaker Team
SoftMaker Team
Posts: 57
Joined: Tue Nov 22, 2011 11:41 am

Re: Python Scripting in BasicMaker

Postby bwst » Tue May 05, 2015 4:19 pm

There is no special documentation for Python available.

SoftMaker Office uses OLE automation. To use this in Python, you need to install the pywin32 package for your Python version.

Running the following code in Python should type "Hello world" in your TextMaker:

Code: Select all

from win32com.client.dynamic import Dispatch

tm = Dispatch('Textmaker.Application')
tm.visible = True

doc = tm.documents.add()
doc.Selection.TypeText("Hello world")
Bodo Wöstmann
SoftMaker Software GmbH

User avatar
Michael Uplawski
Posts: 84
Joined: Thu Dec 11, 2014 11:43 pm
Location: Canton Magny (previously Canton Carrouges), Orne, Normandy (previously Lower Normandy)

Scripting in other languages than BASIC.

Postby Michael Uplawski » Tue Jun 16, 2015 10:48 pm

As OLE-scripts in Python may quite resemble those that you write in Ruby, it could help to retrieve some of those ol' Ruby-scripts from the *German*-speaking BasicMaker 2008 forum for reference... There had also been at least one example in (Borland-) C, if I am not erring.
People should go where they are not supposed to go, say what they are not supposed to say and stay, when they are told to leave.” (Howard Zinn)

Return to “BasicMaker 2012 for Windows”

Who is online

Users browsing this forum: No registered users and 1 guest