DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Using PsPad to edit/run/debug BasicCAD macros

Started by Dempsey, October 26, 2013, 02:50:54 PM

Previous topic - Next topic

0 Members and 0 Guests are viewing this topic.

Dempsey

Here are  the files and documentation how to use PSPad as BasicCAD macro editor and the OLE tool to initiate running/debugging of the macro on an open DesignCAD drawing. Have been tested on Windows 7 Pro (64 bits) with DesignCAD 23.0.

All the credit goes to prl; I only recreated the documentation based on information from an old forum.

27-Jan-2014 -- added instructions how to use macros17.hlp as help while editing BasicCAD macros. With thanks to prl for this tip.
Dempsey

js

Nice documentation Dempsey.  Moving the BasicCAD.ini file to PsPad editor/Syntax produced a user-defined highlighter specification, BasicCAD. Running PsPad.exe as administrator allowed me to save the user highlighter.  High hopes now.

In PsPad>Settings>Highlighter settings>External applications I browsed to the DcBasicCadRun.exe in Program Files (x86)/ PsPad editor/BasicCAD and added that .exe and defined F9 to call DcBasicCADRun

In PsPad I hit F9 and get the message "To use this interface DesignCAD.....neeeds to be running with an active drawing available."

The macro is in a directory other than the drawing directory.  Design Cad is in the default IMSI directory. 

My system is W7 pro 64 bit with DC v23.  You have tested the files on exactly that system so I must have some setting or file arrangement screwed up.

Again, the new zip, with the BasicCAD.ini file and your instructions, was very helpful.  Thanks for your work on this problem.  Where to go from here?

Dempsey

js,

Progress. PSPad is configured.

Next you have to start DesignCAD, and open a drawing!!! Go back to PSPad and then hit F9.

Keep me posted.
Dempsey

js

#3
I started PsPad and then opened a DC drawing back to PsPad and F9.  I get the message:

"To use this interface DesignCAD (v15..22) needs to be running with an active drawing available."

In the PsPad editor\BasicCad there is a file: DcBasicCadRun.ini  I'm not sure where this configuration file comes into the process.  I guess DcBasicCADRun.exe uses it.  But the file is very small only 3 lines:
[Form]
Top=100
Left=100

Is this the entire configuration file?  I know prl recompiled the DcBasicCADRun.exe to eliminate the offending message.  We are using that new compilation so I don't know what the trouble might be.


Dempsey

DcBasicCadRun.ini contains the position where the run-time menu should be displayed.

You have done everything the same as I do.

It looks as if DesignCAD is not properly registered. Do the following:
Exit DesignCAD
Start Command Prompt
    go to directory were Dcad23.exe is
    Dcad23.exe /regserver
    exit
Start DesignCAD and open a drawing
Try PSPad with open macro and F9.

If that fails then try to run DesignCAD with "Run as Administrator".

Dempsey

js

#5
Dempsey,

I now report great joy in newbieville.
I registered DC as you suggested and I set both DC Max and PsPad to x86 compatibility and ran both as administrator.
F9 in PsPad now works beautifully

I imagine there is great joy in Heroville - now that your full-time tutor work has ended.

Thank you very much for staying with this problem and for your excellent documentation and complete files for the connection of DC and PsPad.  Of course, thanks to prl for the terrific programming.

PsPad is still intimidating but I look forward to working with it.  Thanks.

Dempsey

js,

I am glad to hear that everything is working now. PSPad is very handy when you do editing of programming language files, but I have not used it very much either other then for the occasional BasicCAD macro editing and testing.

If you run into another problem down the road then feel free to come back to the forum. There is always someone who can help you.

Cheers
Dempsey

prl

Hi Dempsey, 

Thanks for doing this.  It has been so long, I hardly remember the steps involved in configuring PsPad.    On your page two, the user can also link PsPad to a help file.  In our case, Macros17.hlp.

With this, the user can place the cursor on a keyword and hit Alt F1 for a lookup.

Dempsey

#8
Hi prl,

That is a neat trick. I will give that a try and then update the zip file. It may take a few days before I get to it though; retirees are always too busy  ;D

Thanks

27-Jan-2014 -- above zip file contains the instructions how to use macros17.hlp to get help while editing macros.
Dempsey