Lambdas In A VB .NET (2.0) Project In VS 2008?
Aug 13, 2010
I built a small chunk of code based around lambdas in a VB Windows form project earlier which works perfectly, but it gives me "expression expected" warnings (which block compiling... should probably be considered errors, no?) when I copy the code to an ASP.NET project. The only difference I can see is if I make a Windows form project vs a Web project... works in one, doesn't work in another.
Even something basic like this doesn't work:
delegate function stringify(byval x as object) as string
public sub test()
dim f as stringify = Function(x) x.ToString()
dim s as string = f(5)
end sub
Is there a way to get Lambdas to work in ASP.NET? Or is there a setting somewhere yanking my version of VB down a level or two (since they apparently only work in 9.0 or later, but I don't know how to tell which version I'm using)?
Edit: Bah! LinqBridge doesn't seem to work for me. I get the objects (Func(Of TResult)), but no lambda support. I suppose that's the death-knell to my hopes? Or is there something obvious I'm missing to use it (drag to bin, target in references, Imports System.Linq) ?
View 1 Replies
Similar Messages:
Jul 17, 2010
I have downloaded a project from the internet called the SMS Source example. I wanted to open this project in VS2010, so a conversion wizard has popped up prompting for the conversion. But it has errors in converting.
Error msg:
Conversion Report - SMSSend.csproj:
Error converting project file. MSB0001: Internal MSBuild Error: Missing resource 'MissingAttribute'
View 3 Replies
Apr 6, 2010
I have two projects in my solution
1- asp.net web project.
2- wcf serivce project.
3- other common projects between two listed above
Current on the local dev machine I have to run two visual studio instance to run both projects in debug mode. That makes the system run out of resources as these projects share some other project in the soultion which are heavy in files.
Is there a way i can hookup the wcf project on a sinlge visual stodio instance and also be able to debug my asp.net web project. ? I do not want to combine the web and wcf project in to one. Have already considred this option.
View 2 Replies
Mar 18, 2010
we can not add .mdf file to the project in vs2008 and sql server2008 when i am adding .mdf file its displaying an error message so it is not possible to add
View 2 Replies
Sep 9, 2010
I recently bought a new computer, so I want to copy the projects into current system which has visual studio. I have a project developed in VWD 2008. I copied the folder into a flash drive and copied it back into the new system.
Knowing the location, how I do import the project into new system?
View 1 Replies
Apr 27, 2010
I have a project that I developed in VS2005 and that has been put into VSS. I am trying to "get" it on a new machine and convert it to VS2008 because that is what is installed on the new machine. I am having problems with it that I think originate in its working folder. So my basic question is, when you try to work with a solution that's in VSS should you maintain the same folder structure that it had when it was originally checked in? I'm not particularly happy with its original structure because it goes on and on seven levels deep, and I wanted to just cut it down to C:ProjectsResNew, but if that's what it takes to get it to work, I'll do it.
View 10 Replies
Mar 3, 2010
I'm trying to set up a new project (Web Application, not Web Site) in such a way as the web root is in a different location to the "supporting files" (ie. .sln, .vbproj and My Project folder). I'd like to keep the web site root clear of these files.
It seems to be possible when creating a new "Web Site", as the project files are put in VS's "projects" folder, and only web.config and default.aspx end up in the web root, which is good.
For a Web Application, however, I'm having trouble. It seems to require web.config in the same location as the project file. I've tried this sort of arrangement:
As you can see, when I run it with F5, VS complains and creates a new web.config in the same folder as the .vbproj file. However I can run it in IIS without a problem (the IIS app path is configured for the wwwroot folder). But VS doesn't like it.
Is there an established, proper way of separating project files from the web site content with a Web Application?
View 18 Replies
Jun 8, 2010
here's what i did. on my desktop computer, i first installed VS 2005.. after few weeks i installed VS 2008.. i created a project on VS 2008. on my laptop, i installed VS 2008. i transferred the project from my desktop to my laptop but i can't open it.. one of my clasm8s said told me that even if i created it on VS 2008 on my desktop, it still uses framework 3.0 because VS 2005 was the first installed.. is he correct? what should i do?
View 1 Replies
Apr 16, 2010
I have a Visual Studio solution created in 2005 and I want to start working with it in 2008. I opened it and it was run through the wizard. My first error is a message that says: The Web Applicatin Project is configured to use IIS. You must install the following IIS components: IIS 6 Metabase and IIS 6 Configuration Compatibility.So, I googled that and found this:IIS 7.0 is included with Windows Vista. However, when you first install Windows Vista, by default IIS 7.0 is not enabled. This topic describes how to enable IIS and configure it so that in Visual Studio you can create local IIS ASP.NET Web sites. This enables you to use a local copy of IIS to run and debug the Web site instead of using the ASP.NET Development Server.The bold is mine, because I want to know why I can't just use the ASP.NET Development Server? I always have in the past. Oh, and I'm not running Vista, I'm running Windows 7, but I don't think that matters.
View 18 Replies
Apr 27, 2010
I am not sure if I am using the correct terms. But it is possible to create an asp.net website at least three ways.
1) Where the form and code behind code are in the same file
2) Where the form and code behind code are in separate files, resulting in 2 files for each page (*.aspx, and *.aspx.vb)
3) Where you upon the site up as a project, but insert web pages. This approach results in three files per page (*.aspx, *.aspx.designer.vb, and *.aspx.vb)
My problem is I have a site which is done the third way and I would like to switch it to the second. Is there any automated way to do this, or do I have to do it page by page. What I can do is Open a new site with Create Website, insert a page, and then do some copy and paste.
View 5 Replies
Feb 11, 2010
here is simple:
I have a windows project and a web project within the same solution. I want to share the classes from the Windows project with the Web project. I do that by adding them as a linked component.
The problem is that the classes calls forms, controls and other things that when in Web project makes error.
Is there a way to ignore that kind of error? I mean, I won't even use those functions on the project, they just work on the Windows one.
View 3 Replies
Feb 24, 2011
I had to move an asp.net website from Windows 2003 to another server with Windows 2008. Now when I run the website after setting everything up the images will not load. It is a logo that is in a folder named Images. The file is there along with the folder just like on the other site. Any reason this would not work now? Everything else is working except images. Is there something else I missed in the setup?
View 4 Replies
Apr 27, 2010
i created a web setup project for my asp.net application. am trying to create an upgrade MSI that will only replace some few files in my initial installation (very minor upgrade). right now, am not getting it right because the whole initial set of files is been replaced. i guess i only need to change the package code, but i cant do this in VS.NET 2008.
View 6 Replies
Sep 8, 2010
i have created asp.net web application which use Crystal report 2008. Now i want to publish this project. i have installed full version of Crystal report 2008 on server. And all works good. But my bosh does not want Full Crystal Report 2008 to be installed on server. now my question: what i can do?
View 1 Replies
Jun 29, 2010
I just completed converting my vs 2005 web app to Vs 2008. Question:After I make changes to the app and before I move the changes out to our web server, what must I consider for the web server?1) During conversion I allowed the project to convert from 2.0 framework to 3.5. On the web server, I assume it needs to be upgraded to 3.5 as well. Can I upgrade directly from a site or would you recommend I install VS 2008 on the web server as well (which comes with 3.5)? 2) Do I need to change the application name or virtual name on the web server or can I keep it the same?
View 3 Replies
Jan 10, 2011
I have a custom gridview control which is a class library project.I want to be able to specify the css class for the gridview which I can do.But I also want to set a default css stylesheet to the gridview. So if I don't override it using the cssclass property it must get it's cssclass from the default stylesheet I have in my project.
How can I specify the default stylesheet. I have a stylesheet in a folder called "Styles" in my project.
View 4 Replies
Feb 12, 2011
I am moving from one laptop (WinXP Pro) to another (Win7 Pro). I have re-installed VS 2008 (which wasn't straightforward BTW).
On copying one of my web projects, now when I choose "view in browser" to look at my handiwork, Firefox now requires authentication. I use my windows username/password.
But IE8 doesn't require authentication.
I don't need authentication if I run VS 2008 as Administrator.
It's not a show-stopper, but it could prove irritating.
View 1 Replies
Nov 24, 2010
why Visual Studio is not showing the last project open. Actually it's not showing any that I have had open. If there a clitch.
View 2 Replies
Jan 8, 2010
My desktop management team have just installed visual studio 2008 and there is no plugins for asp.net. Is this missed out while they installed visual studio? Can this to be installed again?
View 2 Replies
Mar 5, 2010
When working with an ASP.Net application, when I rebuild the solution, I would like it to automatically refresh the current version thats running through the integrated server in the browser.
I have looked through post build commands and afterbuild targeting but I have not been successful so far. I would like to do this straight through VS2008 if possible without needing to install anything extra, put if thats not possible then any solution would do!
View 1 Replies
May 11, 2010
I have a website build with .Net 2.0 Framework, I tried to deploy it in iis 7 ( Windows Server 2008 ). I get the following error when i browse the project. Server Error in '/' Application. Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: Your application is not running with full trust. Please call AspxLab.WebControls.Runtime.Initialize to manually initialize AspxLab Controls runtime environment. Source Error:
[Code]....
Stack Trace:
[Code]....
[SecurityException: Your application is not running with full trust. Please call AspxLab.WebControls.Runtime.Initialize to manually initialize AspxLab Controls runtime environment.]
a..ctor() +540
az..cctor() +140
Version Information: Microsoft .NET Framework Version:2.0.50727.4927; ASP.NET Version:2.0.50727.4927
View 3 Replies
Mar 25, 2010
In VS 2005 we need to install patch or VS2005 SP1 to create "ASP.Net Web Application" project.
how to create "ASP.Net Web Application" project in VS 2008? (Not Website)
View 5 Replies
Apr 9, 2012
I'm using VS 2008, .NET 3.5. I need to redirect to a specific page if a requested file for a certain directory is not found.
Here's the example:
http://mysite/myproject/
is the directory. I want it where if you try to navigate to a page that doesn't exist in that directory, it goes to a specific page, ie:
http://mysite/myproject/badpage.aspx
this page doesn't exist, I want it to automatically redirect to:
http://mysite/myproject/myNotFoundpage.aspx
View 3 Replies
Apr 20, 2010
I started working on an Asp.net MVC website using Visual Web Developer Express 2008 a while ago. Just recently, I managed to get my hands on a copy of Visual Studio 2008 Professional (through DreamSpark ). I installed the Service Pack, and also the MVC2 files for Visual Studio.
However, now I can't open my project anymore. When I try to open the solution in Visual Studio, it tells me that the project type is not supported. Does this mean that I have to resort to using VWD Express again? Is there perhaps some way that I can edit the project file so that it will load and compile correctly?
Note: I installed MVC2 through the Web Platform Installer, and it says that it installed successfully. However, I notice that MVC references in my unit-test project don't seem to be resolved either - is this perhaps because MVC2 isn't actually installed properly?
View 2 Replies
Mar 17, 2011
In a Web Application project in VS08, how do you create an assembly? E.g. you derive a class based on HtmlGenericControl to form your own div, override the ClientId and UniqueId properties, so as not to get screwed up id's on the client-side, and then you want to use/reference this control in an aspx page.
refer to David Lively's answer (c# control names) regarding the same thing. I have tried his solution but I keep getting "could not load assembly file".
View 1 Replies