HDI: Insert VB Code into FrntPg

M

Matthew

Well, now that the CA election has been suspended, I can
do a little debugging. What I want to do is post a
control for site visitors to launch a server-stored VB
program that collects some preferences, and customizes
the next page view.

I inserted a Command Button into a webpage, and linked it
to a simple program on my network. To get the button
there, I had to use Tools>Advanced>ActiveX Control. The
button is there, and clicks properly. It neither
generates errors nor runs the program, so I must ask:

1. Can I execute VB code in FrontPage?

2. Can I exchange data with a site visitor through VB
MsgBoxes and UserForms?

3. How do I insert VB code into the HTML code to do this?

4. Is ActiveX an acceptable option to provide this
functionality?

Thank you for considering. Anyone with insight regarding
any of these issues should feel encouraged strongly to
respond!

Matthew =}
 
M

Mike Berger

Matt,
First, I'm a semi-informed FP newbie, but know a lot about VB. I think you
might need to look into ActiveX documents if you want to execute a "VB
program". But, this will limit you to IE only. ActiveX Documents have been
described as "a technology looking for a solution", in other words, not
widely accepted/used. By the way, I speak of VB 6.

You can execute VB code via the <script> tags, these will be code fragments,
not an entire program.

Mike
 
L

Lisa Wollin \(Microsoft\)

Hi, Matthew,

As Mike pointed out, using VB (or VBScript) inside the SCRIPT element in a
Web page limits you to IE, and won't work in Netscape or Mozilla or any of
the other browsers. If you know that all of your clients will be using IE,
for example if this is on an intranet site, then using VBScript will
probably be fine.

However, if this is for an external Internet site, then you should use ASP
if you are using VB. With ASP, processing is done on the server not the
client. Then use JavaScript to do anything, such as validation, that needs
to be done on the client side. (JavaScript is relatively simple and easy to
learn. If you know VB, the jump to JavaScript isn't that huge.)

Alternatively, you could create a Web application and code it in VB .NET,
but you would need to make sure that you have the .NET Framework installed
on the Web server as well as other issues related to .Net Web applications.

Lisa Wollin
Programmer Writer
Microsoft Corporation
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top