Grrrrrrr

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

Moderator: SoftMaker Team

Post Reply
SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Grrrrrrr

Post by SteveF48 » Sun Jul 31, 2016 8:24 pm

I'm trying to convert a VBA macro for use with Planmaker and in 3 lines of coding have found 3 things that don't work as described in the Basicmaker manual.
Now I'm completely stuffed.

My (modified as a result of searching the code sample and BM help) is as follows:
Dim pm as Object
Set pm = CreateObject("PlanMaker.Application")

pm.Application.Visible = True
pm.Application.Activate

At which point the macro displayed the "Insert Function" dialog and I gave up.

If you really believe that Softmaker Office can replace M$ Office you need to work on this. I have loads of macros in my documents/spreadsheets and at present I can't use them
Help
Steve
Thanks in advance,
Steve

martin-k
SoftMaker Team
SoftMaker Team
Posts: 2961
Joined: Fri Nov 21, 2003 4:57 pm
Location: Nürnberg, Germany
Contact:

Re: Grrrrrrr

Post by martin-k » Mon Aug 01, 2016 2:48 pm

There is no logical explanation as to why PlanMaker should behave in the way you describe. Have you tried running the included sample script "Calendar.bas"? If yes, does it work?
Martin Kotulla
SoftMaker Software GmbH

SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Re: Grrrrrrr

Post by SteveF48 » Mon Aug 01, 2016 8:01 pm

Yes the calendar macro works.
When I copied the same code from a sample macro it worked:
Set pm = CreateObject("PlanMaker.Application")
pm.Visible = True 'Not sure why this is necessary, but the macro fails without it
pm.Activate 'Does what it says - activates PlanMaker

Curiouser and curiouser.

Now I'm stumped again.
I've called a subroutine, which should initialise my spreadsheet.

Sub Init
Dim myRange as Object
Set myRange = pm.ActiveSheet.Range("A2:K200")
The last line causes a Type Mismatch error, although it is similar to statements in the main body of the macro.

It appears as though BasicMaker has forgotten that I've activated PlanMaker, or is there another explanation?
Perplexed of Deal :?:

martin-k
SoftMaker Team
SoftMaker Team
Posts: 2961
Joined: Fri Nov 21, 2003 4:57 pm
Location: Nürnberg, Germany
Contact:

Re: Grrrrrrr

Post by martin-k » Mon Aug 01, 2016 8:02 pm

Post the full script, so we can try it.
Martin Kotulla
SoftMaker Software GmbH

SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Re: Grrrrr

Post by SteveF48 » Tue Aug 02, 2016 3:02 pm

Can I attach it to a PM, with data. I don't really want the data to be made public and the script won't work without it.
The problems that I mentioned yesterday have disappeared and I'm not sure why.

For some reason the init sub-routine is not initialising the 2nd and 6th cells that it is supposed to put zero in.
i.e. After it runs cell K3 and K6 still contain their original values.
Regards
Steve
Thanks in advance,
Steve

SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Re: Grrrrrrr

Post by SteveF48 » Tue Aug 02, 2016 3:05 pm

Just a thought...
After each test I press Ctrl-F2 to reset the program, aas I thought that this would clear everything and force BasicMaker to recompile.
Some of the errors that have frustrated me have disappeared when I returned to BasicMaker after closing the program, is it possible that my changes are not taking effect immediately?
Thanks in advance,
Steve

sven-l
SoftMaker Team
SoftMaker Team
Posts: 7782
Joined: Wed Apr 09, 2008 8:26 am
Location: Nuremberg
Contact:

Re: Grrrrrrr

Post by sven-l » Wed Aug 03, 2016 8:44 am

SteveF48 wrote:Just a thought...
After each test I press Ctrl-F2 to reset the program, aas I thought that this would clear everything and force BasicMaker to recompile.
Some of the errors that have frustrated me have disappeared when I returned to BasicMaker after closing the program, is it possible that my changes are not taking effect immediately?
You do not have to restart BasicMaker. Ctrl+F2 forces BasicMaker to restart the script starting from line 1.
Sven Leßmann
SoftMaker Software GmbH

Prelabaires
Posts: 1
Joined: Sat Aug 06, 2016 4:30 pm

Line Wrappìng

Post by Prelabaires » Sat Aug 06, 2016 4:38 pm

Hi, there,
How can I wrap lines in Basic Maker? Thanks

sven-l
SoftMaker Team
SoftMaker Team
Posts: 7782
Joined: Wed Apr 09, 2008 8:26 am
Location: Nuremberg
Contact:

Re: Grrrrrrr

Post by sven-l » Mon Aug 08, 2016 9:52 am

According to page 218 in the BasicMaker manual:
WrapText (property)
Data type: Long
Gets or sets the setting "Wrap text" for the cells in the cell range. Corresponds to the Word-wrap option in the dialog
box of PlanMaker's Format > Cell command.
Sven Leßmann
SoftMaker Software GmbH

SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Re: Grrrrrrr

Post by SteveF48 » Sat Aug 13, 2016 5:41 pm

martin-k wrote:There is no logical explanation as to why PlanMaker should behave in the way you describe. Have you tried running the included sample script "Calendar.bas"? If yes, does it work?
My latest script is also displaying the "Insert Function" dialog. It appears when I step through and it executes the pm.Activate statement.
Thanks in advance,
Steve

sven-l
SoftMaker Team
SoftMaker Team
Posts: 7782
Joined: Wed Apr 09, 2008 8:26 am
Location: Nuremberg
Contact:

Re: Grrrrrrr

Post by sven-l » Mon Aug 15, 2016 10:50 am

SteveF48 wrote:
martin-k wrote:There is no logical explanation as to why PlanMaker should behave in the way you describe. Have you tried running the included sample script "Calendar.bas"? If yes, does it work?
My latest script is also displaying the "Insert Function" dialog. It appears when I step through and it executes the pm.Activate statement.
Could you please send that script for a review to forum(at)softmaker.de? Thank you!
Sven Leßmann
SoftMaker Software GmbH

SteveF48
Posts: 20
Joined: Thu Jul 11, 2013 11:32 am
Location: Deal, Kent, UK

Re: Grrrrrrr

Post by SteveF48 » Tue Aug 16, 2016 12:55 pm

I think that it appears briefly every run, but disappears when I'm not debugging
Thanks in advance,
Steve

Post Reply

Return to “BasicMaker 2016 for Windows”