Asp.net mvc view engine - to roll my own intellisense - asp.net

I'm creating a little special purpose view engine for asp.net mvc. That goes well enough. But i've been looking around to find information on how to somehow add intellisense for the C# code embedded in my view.
I can see Spark does that, but going through the sources, I still can't see how. And WebForms view engine does it - not surprisingly - to perfection. Does anyone have any suggestions or links or anything related on how to do that?
Update: Just to let readers know, I'm still looking for a solution! So keep the answers coming :) ... I will post back here too, whenever I find out more.
/Asger

Looking at the Spark source, it appears that he is hosting his editor within the Visual Studio 2008 IDE, in a way that he is getting the C# intellisense for free.
You might want to check out the Visual Studio 2008 SDK 1.1, and see if there's something in there that will help you.
http://www.microsoft.com/downloads/details.aspx?familyid=59EC6EC3-4273-48A3-BA25-DC925A45584D&displaylang=en

You might find some clues here:
How do I add intellisense to my application?
Googling this is maddeningly difficult, as you get all kinds of hits on enabling intellisense, how wonderful intellisense is, how bad intellisense is, etc.

Related

Can't find the ASP.NET Configuration tab in the Website menu in Visual Studio

I'm going crazy because I can't find the ASP.NET configuration tab in Visual Studio 2017.
I'm following Microsofts ASP.NET tutorial on how to create a login page with members.
This is what the tutorial tells me.
And this is what my menu looks like.
Please help me. I've been looking after it for an hour now without any luck.
Link to the relevant chapter.
This menu item was removed some time ago (VS2013 or VS2015, I can't remember). It's unfortunate that the documentation hasn't been updated.
Anyway, you should check out ASP.NET Identity instead. It's now preferred over the old Membership provider model you're looking at. Give it a go at asp.net/identity
I assume you were on this page, yes? If you click the other versions link, you can see its meant for Visual Studio 2010. Nice of them to make that obvious, eh? Anywho, if you want built in authentication you can still use it, you just have to pick the Individual Accounts option for authentication when creating an account. This is not using the old school Membership Provider though, as that is outdated. Detailed instructions can be found here.
If you still really really want the old MembershipProvider, I would suggest just downloading Visual Studio 2010 from here and going to town. Enjoy!

ASP.NET Web Sites Examples

We plan to develop a ASP.NET ( VS 2010 ) web site.
We need to know if there are any ready made startup ASP.NET web sites so we can get them and adjust / upgrade according to our needs.
Thank you for your quick reponse
John.
There are lots of examples out there, and even VS 2010 has some templates that will get you started. There isn't really much detail about what kind of website you are starting up, so beyond that you probably won't get much in the way of answers here to your question. Most of the questions on here are of a more technical nature, and without showing that you are attempting something specific and that you have tried it on your own, answers will likely be few and far between.
You can check out some of the starter kits posted on asp.net:
http://www.asp.net/community/projects#jm_starter_kits_and_samples

Where can I find a clean API for Visual Basic development?

I am completely new to ASP.NET programming, and was asked to work on a small project involving ASP.NET, VB (which I am new to as well) and Microsoft SQL Server 2005.
Being used to php/java I was hoping to find some kind of similar API to php.net and the javadoc. It would be very useful to have as I would prefer to work with a text editor, instead of using DreamWeaver or Visual Web Developer.
In the project I basically only need to use ASP.NET to read from a SQL 2005 database and write to JSON files. Could anyone please give me some pointers on where to find a clean and decent API to work with? I would also appreciate any input and tips I could get to get started working on this.
I would prefer to work with a text editor, instead of using DreamWeaver or Visual Web Developer.
Imo this is a mistake in .Net. The platform was built with the IDE in mind. You really will be able to get a lot more done, and do it better, if you let yourself learn to use Visual Studio.
That said, the place to look for .Net documentation is, of course, the MSDN Library. Maybe start on this page:
http://msdn.microsoft.com/en-us/library/w0x726c2.aspx
only need to use ASP.NET to read from a SQL 2005 database and write to JSON files
You might want to take a look at ASP.NET MVC.
You controllers can return a JsonReasult which will automatically result in JSON being sent. No need to define any markup.
"Could anyone please give me some
pointers on where to find a clean and
decent API to work with?"
If you want to develop a VB.NET application, you have to use the VB.NET programming language; there are no other APIs available.
Where does javadoc fit into this? That's just markup you apply to your source code to create documentation. .NET has its own system which works in the same way but is built on XML.
As Joel says, Visual Studio has everything you need. It features a visual editor but also gives you access to all the source code.
you will need to have the IDE to develop ASP.Net application. It will be much easier using it. You can find docs and articles on developing on ASP.Net in this site. its a nice one.
https://web.archive.org/web/20211027112438/https://aspnet.4guysfromrolla.com/default.aspx#Tools2
https://web.archive.org/web/20210513213529/http://aspnet.4guysfromrolla.com/articles/042705-1.aspx
https://web.archive.org/web/20210802161558/https://aspnet.4guysfromrolla.com/articles/110905-1.aspx
work on a small project involving ASP.NET, VB (which I am new to as well) and Microsoft SQL Server 2005
It might not be VB, it might be VB.Net?

Error: "Failed to map the path '/'" when I add a Telerik ReportViewer to web page

I've just built a crap load of Telerik reports for my web site project, and they all work nicely. I have to demonstrate them tomorrow, and tried to build a viewing page that hosts their web ReportViewer. I have asked this question on their forums as well, but expect less response than from SO late on a Friday night.
Whether I use GAC or bin references, as soon as I add the ReportViewer control to my page, even without trying to load a report, I get the error Failed to map the path '/'. Other Telerik controls, from the Web.UI library work fine. I'm not expecting a Telerik specific answer here, although that would ease the pain of my all-nighter, but I can see nothing meaningful in the stack trace for this error.
How can I go about diagnosing what Telerik is looking for and can't find, or something of that ilk? This is a serious emergency, and I will sort a 'dereferenced' bounty for anyone that can offer any suggestions tonight. I'm going to reinstall Reporting so long.
UPDATE: Foolishly wary of excess complicating factors, I always try new things like this in a small, dedicated project separate from my main one. Yesterday I quickly tried a small web site project when I encountered my problem. I then tried a small web application project, with local, not GAC references to telerik, all telerik refs set to copy to local, and it all worked. Naturally I was quite ecstatic, as my main project is a web app, not site.
so you have a webpage running without problems.
Than you add a telerik ReportViewer controls - run the things again and get an error:
...Failed...'/'...
The control simply sits in the page and does nothing.
So like womp I would ask you to provide the full error output!
One other question:
Does the error also occure on the development machine (running the project from VS with webdev server)?
And a hint meanwhile (not sure if you'v already checked this):
http://www.telerik.com/support/kb/reporting/general/deploying-telerik-reporting.aspx
One last thing - maybe it con help you. I made up a little web site doing what you have told your site does.
You can download it here: www.pp-p.com/rvsite.zip
Maybe a look at web.config or so can help you to find what's missing in your site.
One thing - in the BIN folder are two txt files - replace them with the DLLs from telerik reporting to have the project work.
Maybe this helps (for the weekend till the telerik support guys are back at work)..

Suggestions for migrating ASP.net app from 1.1 forward

I am recently in charge of an older app written in C# using asp.net 1.1.
Are there any resources to guide me in converting the application to a newer version of of the .NET Framework.
My main pause is that there are ton's of customized DataGrids in the app as it is written now and since so much of the code needs to be rewritten to use GridViews ...
is it worth trying to convert the grids in the application to use Silverlight in the attempt to move this code into the future.
I had a similar experience, and the only thing that we had to replace was a third-party control that we were using in the 1.1 app, and the vendor had gone out of business an never released a version that worked with .NET 2.0. We ended up replacing it fairly easily with an AJAX Control Toolkit control.
Other than that, the compiler does a pretty good job of telling you what to do with respect to deprecated method calls.
I'd suggest making a copy of the code and upgrading the site in Visual Studio and see what happens. Just open the solution in Visual Studio 2005 or 2008, the IDE will walk you through the upgrade automatically. Get it to compile, then if you have any documented tests you should run through them. If not, you'll want to plan testing to make sure all your functionality still works like it did before the upgrade.
Migrating to Silverlight sounds like fun, but if you can get it upgraded and working, I'd probably push that off until a later release -- my experience tells me that you might get into trouble if you bite off too much at once if there is no show-stopping technical reason.
This MSDN document may be useful to you as you upgrade your application, it contains lists of breaking changes between 1.1 and 2.0, and work arounds for resolving them:
Breaking Changes in .NET Framework 2.0
I would suggest that as part of the upgrade you opt to move to a Web Application Project rather than a Web Site Project, as the former is conceptually similar to the VS2003 web project model.
Here's a nice short post summarising the differences:
http://maordavid.blogspot.com/2007/06/aspnet-20-web-site-vs-web-application.html
As others have said, don't worry too much about the DataGrids, the upgraded site should be backwards-compatible in this respect.
Regarding DataGrids - I don't think you have too much to worry about, DataGrids still work in current versions. It's just that going forward, you should use GridViews.
I am sure there are other things you may want to check into though, deeper framework issues. But I don't know enough about those things to speak to that particular point.

Resources