Want an HTA Form Designer? Try ActiveX Control Pad...



I was thinking that the hta help-o-matic ought to have a form designer.

They're not hard to write, there are several code samples available,
showing how to do it.  (And of course, Microsoft has tons of them
sitting around their offices).

I wrote one myself, years ago, (but that's another story).

If the "scripting guys/gals" ain't going to write one, anybody wanting
a "form designer" for hta's might consider Microsoft's (free) "ActiveX
Control Pad".  You can design your form (er, IE-based scripting dialog)
using the ActX Control Pad, and then copy/paste the html into your hta
file.

Now, I know what you are thinking: A.C.P. is ancient.  Yes, it dates
back to 1997 (gasp!) but it is still available, and it still works
(at least on win98se).  Also, the "controls" are not html controls,
rather they are "fm20.dll" controls (the same ones used by vba forms).
You will get "fm20.dll" (free) with ActX Control Pad.  (If you have
any Microsoft Office App with vba, then you most likely already have
"fm20.dll" installed).  You may download A.C.P. here:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaxctrl/html/cpad.asp

Even if you don't want the "fm20.dll" controls on your hta, you can
convert the geometry to positioning information for regular html
controls.

Just a note for anybody not already familiar with A.C.P., it's not
immediately obvious how to get into the graphical designer.  The
answer is that you first install an "HTML Layout" control on the
opening html page (menu item: Open HTML Layout).  You will be
asked to select a file name for the "alx" file (which contains the
HTML Layout html).  Then you click on the html layout control's
icon in the left margin, and the graphic designer opens up.  You
are presented with a "form" and a "toolbox" with the usual visual
basic controls, and then some.  You then can add your controls to
your form, just like in the vb form designer.

When you are finished, you can just insert the html generated
into your hta file.  Or else, you can use the geometry (coordinates)
for positioning normal html controls.

Have fun.

cheers, jw

.