Mombu the Microsoft Forum sponsored links

Go Back   Mombu the Microsoft Forum > Microsoft > running vbscript from VB.NET
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 16th March 08:16
draguvaso
External User
 
Posts: 1
Default running vbscript from VB.NET



Hi,

I want to run some vbscripts from a VB.NET application. Anybody knows how to
do this?

Thanks,

Pieter
  Reply With Quote


  sponsored links


2 16th March 08:16
cor
External User
 
Posts: 1
Default running vbscript from VB.NET



Hi Pieter,

In a webform or in a windowform?

Cor
  Reply With Quote
3 16th March 08:16
draguvaso
External User
 
Posts: 1
Default running vbscript from VB.NET


Hi Cor,

It's in a windowform :-)
  Reply With Quote
4 16th March 08:16
cor
External User
 
Posts: 1
Default running vbscript from VB.NET


Hi Pieter,

This is the only one I could find direct,

It uses the webbrowser

It was the first piece of code I got from Herfried and I find it still
greath.

(Do not think there was much after that)

:-))

\\\
AxWebBrowser.Navigate("about:<html><body
onload=javascript:window.external.addFavorite('" + textbox1.Text +
"')></body></html>")
///


Cor
  Reply With Quote
5 16th March 08:16
alex k. angelopoulos [mvp]
External User
 
Posts: 1
Default running vbscript from VB.NET


You need to host the VBScript within something; the simplest thing to do is
to put a reference the Microsoft Script Control into your windowform, then
run the script within the control.
  Reply With Quote
6 16th March 08:16
viatcheslav v. vassiliev
External User
 
Posts: 1
Default running vbscript from VB.NET


You have 2 options:

1. Run vbscript as standalone process - VB.Net has Shell() function. Execute

cscript.exe "C:\Path\FileName.vbs"

2. Host vbscript inside your application - the easest way is to use
Microsoft Script Control.

As another option you may let users write VB.Net code. In your application
you will need to compile and run it.

//------------------------------------
Regards,
Vassiliev V. V.
http://www-sharp.com -
Scripting/HTA/.Net Framework IDE

"DraguVaso" <pietercoucke@hotmail.com> сообщил/сообщила в новостях
следующее: news:%23DIhs%23r9DHA.3900@tk2msftngp13.phx.gbl...

to
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright ╘ 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666