Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > running ASP inside VBscript

Reply
Thread Tools

running ASP inside VBscript

 
 
Jacques Koorts
Guest
Posts: n/a
 
      05-02-2004
hi,

is it possible?

i tried this and it does not work:

sub main()

<%

%>

end sub


I want to run ASP in a subroutine if that is possible.

thanks
jacques


 
Reply With Quote
 
 
 
 
Steven Burn
Guest
Posts: n/a
 
      05-02-2004
VBScript IS ASP (in a sense anyway)...... tis what you use to write asp
pages ;o)

--

Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Personal favourites

WebGrid - www.webgrid.co.uk
Freeware Arena - www.freewarearena.com
Freeware Home - www.freewarehome.com
Freeware Outpost -
http://free.hostdepartment.com/f/fre...st/index2.html
ZeroPlus2 - http://zp2.it-mate.co.uk
Fort Freeware - http://freeware.quantum.2ya.com/
Pricelessware - http://www.pricelessware.org
El-Mambo - http://www.el-mambo.net/
Practically Nerded - http://mvps.org/PracticallyNerded/
Bugs, Glitches n stuff - http://mvps.org/inetexplorer/Darnit.htm
Calendar of Updates - http://www.dozleng.com/updates/index.php?&act=calendar
Seniority - http://www.seniority.co.uk
Remembering Dunblane - http://www.dunblane.braveheart.com/
Echo Echo - http://www.echoecho.com/


"Jacques Koorts" <> wrote in message
news:...
> hi,
>
> is it possible?
>
> i tried this and it does not work:
>
> sub main()
>
> <%
>
> %>
>
> end sub
>
>
> I want to run ASP in a subroutine if that is possible.
>
> thanks
> jacques
>
>



 
Reply With Quote
 
 
 
 
Chris Barber
Guest
Posts: n/a
 
      05-02-2004
In what context?

ASP code is only executed by a webserver processing an .asp page - it recognises the extension and
passes it to the ASP script parser that then executes the code and passes the resultant document
back for further processing and to be served to the web client.

Chris,

"Jacques Koorts" <> wrote in message news:...
hi,

is it possible?

i tried this and it does not work:

sub main()

<%

%>

end sub


I want to run ASP in a subroutine if that is possible.

thanks
jacques



 
Reply With Quote
 
Aaron Bertrand [MVP]
Guest
Posts: n/a
 
      05-02-2004
You can't mix server- and client-side script like that. In addition, this
has absolutely NOTHING to do with databases. Please use more care in
choosing your groups.

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/


"Jacques Koorts" <> wrote in message
news:...
> hi,
>
> is it possible?
>
> i tried this and it does not work:
>
> sub main()
>
> <%
>
> %>
>
> end sub
>
>
> I want to run ASP in a subroutine if that is possible.
>
> thanks
> jacques
>
>



 
Reply With Quote
 
SpaceGirl
Guest
Posts: n/a
 
      05-03-2004

"Steven Burn" <> wrote in message
news:%...
> VBScript IS ASP (in a sense anyway)...... tis what you use to write asp
> pages ;o)
>
> --
>
> Regards
>
> Steven Burn
> Ur I.T. Mate Group
> www.it-mate.co.uk


Well... no... Vbscript is one language that ASP supports. There are two...
VBS and JScript. With ASP.NET, you have C#.NET, J++.NET, VB.NET, C++ and C
to play with as well.


 
Reply With Quote
 
Aaron Bertrand [MVP]
Guest
Posts: n/a
 
      05-03-2004
> Well... no... Vbscript is one language that ASP supports. There are two...
> VBS and JScript.


Actually, it is more than two (e.g. perlscript, basically any COM-compliant
language)... but only those two are in mainstream use.


 
Reply With Quote
 
Andy Dingley
Guest
Posts: n/a
 
      05-03-2004
On Sun, 2 May 2004 17:28:32 -0400, "Jacques Koorts"
<> wrote:

>is it possible?


Yes.

>i tried this and it does not work:
>
> sub main()
>
> <%
>
> %>
>
> end sub


You have the ASP code markers the wrong way round. Here's an example
that works. :


<html>
<body>

<p>With Response.Write
<%

Sub f1
Response.Write "Woof bark donkey"
End Sub

f1
%>


<p>With nesting
<%

Sub f2
%>
Woof bark donkey
<%
End Sub

f2
%>

</html>


Be warned though that this coding style can esily become unreadable.

PS - and ditch VBScript in favour of JScript

--
Smert' spamionam
 
Reply With Quote
 
Aaron Bertrand - MVP
Guest
Posts: n/a
 
      05-03-2004
> PS - and ditch VBScript in favour of JScript

You might want to explain why. Or else you might as well tell him to ditch
his ranch for a colonial and his Toyota for a Honda.

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/


 
Reply With Quote
 
Steven Burn
Guest
Posts: n/a
 
      05-03-2004
hehe Aaron, such a lovely (and rather polite) way of putting it ;o)

--

Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

"Aaron Bertrand - MVP" <> wrote in message
news:...
> > PS - and ditch VBScript in favour of JScript

>
> You might want to explain why. Or else you might as well tell him to

ditch
> his ranch for a colonial and his Toyota for a Honda.
>
> --
> Aaron Bertrand
> SQL Server MVP
> http://www.aspfaq.com/
>
>



 
Reply With Quote
 
Aaron Bertrand - MVP
Guest
Posts: n/a
 
      05-03-2004
Well, I really see no convincing argument that dictates that everyone
running VBScript should ditch it for JScript.
http://www.aspfaq.com/2176

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Pass XMLDoc from ASP.NET to asp page (vbscript) Joe ASP .Net 2 04-25-2009 10:06 AM
VBSCript inside ASP page pjglick ASP General 3 11-04-2005 08:26 AM
Setting Terminal Services settings using ASP.NET (or... calling Server-side vbscript from ASP.NET) Roja Doja ASP .Net 2 04-14-2005 02:30 PM
ASP + ASP.NET + VBScript + C#? Gabriele Zannoni ASP .Net 4 09-08-2004 07:10 PM
ASP JavaScript versus ASP VBScript John Davis ASP General 5 09-07-2003 12:42 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57