473,394 Members | 1,866 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Trouble compiling HelloWorld with vbc

Hi,

I can't compile anything with vbc, so i am asking for help please.

I have a file helloworld.aspx written in asp.net using vb, here it is:

<script runat="server" language="vb">
'================================================= ============================
'================================================= ============================
' HelloWorld.aspx
'================================================= ============================
'================================================= ============================
' ================================================== ===
' Begin
' ================================================== ===

Private Sub Page_Load()
' Print "Hello World !"
Response.write ("Hello World !")
End Sub
' ================================================== ===
' End
' ================================================== ===

</script>

Then i have a file compilehelloworld.bat, here it is:

C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\vbc.e xe helloworld.aspx
/target:library /out:helloworld.dll /reference:System.dll > comp.log

The file helloworld.aspx works great when i don't compile it, but when
i execute compilehelloworld.bat, here is the result:

Microsoft (R) Visual Basic .NET Compiler version 7.10.3052.4
for Microsoft (R) .NET Framework version 1.1.4322.573
Copyright (C) Microsoft Corporation 1987-2002. All rights reserved.

D:\dev\jct\source\helloworld.aspx(1) : error BC30636: '>' expected.

<script runat="server" language="vb">
~~~~~
D:\dev\jct\source\helloworld.aspx(13) : error BC30001: Statement is
not valid in a namespace.

Private Sub Page_Load()
~~~~~~~~~~~~~~~~~~~~~~~
D:\dev\jct\source\helloworld.aspx(21) : error BC30203: Identifier
expected.

</script>
~
Can anyone tell me what is wrong ? Thanks.
Nov 19 '05 #1
3 1681
You should use "code behind" if you do this. For now you can't compile ASPX
page, they are compiled on the fly and are pre-processed before compilation
(for example <script> is not part of the VB.NET language).

Patrice

--

"Mister.programmer" <mi********@laposte.net> a écrit dans le message de
news:16**************************@posting.google.c om...
Hi,

I can't compile anything with vbc, so i am asking for help please.

I have a file helloworld.aspx written in asp.net using vb, here it is:

<script runat="server" language="vb">
'================================================= ==========================
== '================================================= ==========================
== ' HelloWorld.aspx
'================================================= ==========================
== '================================================= ==========================
==

' ================================================== ===
' Begin
' ================================================== ===

Private Sub Page_Load()
' Print "Hello World !"
Response.write ("Hello World !")
End Sub
' ================================================== ===
' End
' ================================================== ===

</script>

Then i have a file compilehelloworld.bat, here it is:

C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\vbc.e xe helloworld.aspx
/target:library /out:helloworld.dll /reference:System.dll > comp.log

The file helloworld.aspx works great when i don't compile it, but when
i execute compilehelloworld.bat, here is the result:

Microsoft (R) Visual Basic .NET Compiler version 7.10.3052.4
for Microsoft (R) .NET Framework version 1.1.4322.573
Copyright (C) Microsoft Corporation 1987-2002. All rights reserved.

D:\dev\jct\source\helloworld.aspx(1) : error BC30636: '>' expected.

<script runat="server" language="vb">
~~~~~
D:\dev\jct\source\helloworld.aspx(13) : error BC30001: Statement is
not valid in a namespace.

Private Sub Page_Load()
~~~~~~~~~~~~~~~~~~~~~~~
D:\dev\jct\source\helloworld.aspx(21) : error BC30203: Identifier
expected.

</script>
~
Can anyone tell me what is wrong ? Thanks.

Nov 19 '05 #2

Patrice wrote:
You should use "code behind" if you do this. For now you can't compile ASPX page, they are compiled on the fly and are pre-processed before compilation (for example <script> is not part of the VB.NET language).

Patrice


Thank you for this information. Could you give me the equivalent in
"code behind" for this helloworld.aspx and compilehelloworld.bat ?

Thanks.

Nov 19 '05 #3
Me again: For anyone having the same question and coming to this
thread, here is a good link.

http://www.samspublishing.com/articl...le.asp?p=25468

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Martin Petzold | last post by:
Hello, i have got a small problem while compiling my helloworld.c where i include a driver class (comm.c). i compile under winXP with minGW and have got this error: ...
4
by: jester.dev | last post by:
I am learning c through an online tutorial currently. And I am running Linux, but the tutorial does not deal specifically with linux. I'm not sure if I am compiling correctly or not because I get...
3
by: Alex | last post by:
Hi, The following article describes how to compile CSharp code programmatically http://support.microsoft.com/default.aspx? scid=http://support.microsoft.com:80/support/kb/articles/Q3...
2
by: carolineb2005 | last post by:
I have compiled this simple program which accept arguments on line using System; class HelloWorld { public static void Main(string args) { Console.WriteLine("Hello ", args); } }
7
by: Marcelo | last post by:
Hi, I am getting a very strange error ubuntu:~/docs/jni/jniexamples/chap2/HelloWorld$ gcc -I/usr/local/share/jdk1.5.0_05/include -I/usr/local/share/jdk1.5.0_05/include/linux HelloWorld.c...
3
by: Olivier BESSON | last post by:
Hello, I have a web service of my own on a server (vb.net). I must declare it with SoapRpcMethod to be used with JAVA. This is a simple exemple method of my vb source : ...
1
by: Papanii Okai | last post by:
Hi Guys, I am trying to use the command line to compile a .cs file to a dll. I am using the Windows SDK command shell for this. Below is the command.. C:\Documents and Settings\Papanii...
10
by: Tomás Ó hÉilidhe | last post by:
I'd post this on a gcc newsgroup but I'd be more productive talking to the wall. Anyway, let's say someone throws some source code at you for a particular program and says, "Just compile it, it...
6
by: Oliver Graeser | last post by:
Ok, stupid question.... I used to write programs all into one text files and compile them. Works, fine. Then I discovered XCode (or IDEs in general) which appear to be really increasing my...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.