473,398 Members | 2,120 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,398 software developers and data experts.

asp.net uses the wrong compiler

i am writing a web project running under IIS on VS 2008. on a standard
exe if i write a line that uses one of the new language features of
VB.NET 2008, the IDE uses the .net 3.5 compiler to compile the code
(although i am targeting .net 2) and all is working well. however, on
an asp.net site the iis and/or the .net worker process uses the .net 2
compiler for a site and the line of code i used does not work. (again
i am targeting .net 2 so the IIS is set to run the site as .net 2)

my question: how can i make the iis compile the site using the .net
3.5 compiler?

for example:
run this on vs 2008 on an exe targeting .net 2 framework
Dim x As New System.Collections.ArrayList() With {.Capacity = 20}

try to use the line above on a web site targetign .net 2 framework and
it will not work
giving only an error when you access the page and not a compiler error
on the IDE

thanks
Jun 27 '08 #1
1 1017
I am confused. Do you want to use 2.0 or 3.5? You keep saying you are
"targeting .NET 2.0", but you also say "How can i make the iis compile the
site using the .NET 3.5 compiler?". The first thing I would do is make sure
that VS2008 is using the version you want while you write your code. I am
assuming the runtime for that version is also installed on your IIS. I am
not a server expert, but I believe that you need to specify somewhere in the
site settings on IIS which version you are using. You may also want to try
the newsgroup microsoft.public.inetserver.iis, they may be of some use as
well.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

<Av******@gmail.comwrote in message
news:b0**********************************@26g2000h sk.googlegroups.com...
>i am writing a web project running under IIS on VS 2008. on a standard
exe if i write a line that uses one of the new language features of
VB.NET 2008, the IDE uses the .net 3.5 compiler to compile the code
(although i am targeting .net 2) and all is working well. however, on
an asp.net site the iis and/or the .net worker process uses the .net 2
compiler for a site and the line of code i used does not work. (again
i am targeting .net 2 so the IIS is set to run the site as .net 2)

my question: how can i make the iis compile the site using the .net
3.5 compiler?

for example:
run this on vs 2008 on an exe targeting .net 2 framework
Dim x As New System.Collections.ArrayList() With {.Capacity = 20}

try to use the line above on a web site targetign .net 2 framework and
it will not work
giving only an error when you access the page and not a compiler error
on the IDE

thanks

Jun 27 '08 #2

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

Similar topics

12
by: RoSsIaCrIiLoIA | last post by:
On Mon, 07 Feb 2005 21:28:30 GMT, Keith Thompson <kst-u@mib.org> wrote: >"Romeo Colacitti" <wwromeo@gmail.com> writes: >> Chris Torek wrote: >>> In article <4205BD5C.6DC8@mindspring.com> >>>...
15
by: XZ | last post by:
Hi everyone, this is really confusing to me: #include <stdio.h> main(int argc, char **argv) { printf("argv = %f\n",(double)atof(argv)); printf("argv = %d\n\n",atoi(argv)); } $ a.out a argv...
0
by: Sam | last post by:
Hi there, For some very bizzare reason I can't get ASP.NET to read an XSLT stylesheet properly. I always get a the message below. Any ideas as to how to get around this problem? Thanks in...
2
by: mark.e.nelson | last post by:
Hi, I am trying to pass a pointer to a struct to a function that uses the data in the struct, and also happens to use ncurses. I always get a segmentation violation when the program exits. I...
83
by: Anonymous | last post by:
Came across some code summarized as follows: char const* MyClass::errToText(int err) const { switch (err) { case 0: return "No error"; case 1: return "Not enough"; case 2: return "Too...
24
by: Francine.Neary | last post by:
Just out of personal curiosity :) What do people use offsetof() for? I mean, I can understand why you'd want to be able to take the address of a member of a struct, but you can do that with just...
1
by: napi | last post by:
Does anyone know of any public domain C++ compiler that uses CFront as its front end? If you do would appreciate the links or other related info. p.s. Info on any commercial C++ compiler that...
5
by: kris | last post by:
Hi I have written a program which prints the hostid on a linux system. The programm uses gethostid() function call which is defined in the library file unistd.h. But my programm gets compiled...
11
by: coomberjones | last post by:
I have a few std::strings that I am using to store raw binary data, each of which may very well include null bytes at any point or points. I want to slap them together into a single string, so I...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.