For some reason I don't get intellisense in aspx/ascx files in WSPBuilder projects, normal web projects work fine, does anyone know how I can resolve this?
|
Not sure if this will work, but try right clicking on the file and open with web form editor. It is the default editor but sometimes this makes a difference. |
|||||
|
|
I have seen intermittent issues with intellisense as well - here are the key things I have noticed: 1) Sometimes the project/file opens in Visual Studio 2005 - where the intellisense is garbage compared to the 2008/2010 editions. Make sure it is the correct version of visual studio. 2) For the intellisense to work right you need to let it know what libraries it needs to load and parse. You can add the Microsoft.Sharepoint.dll as a reference to the project, and some files (like .ashx, .ascx, etc. ) need to have the import information declared at the top of the file:
I don't remember the specifics, but I think for .ashx files the Assembly directive must be the first line for intellisense to work as well. |
|||
|
|
|
You can edit the web item templates to the project file itself. To add to *.csproj:
To add *.vbproj file:
I'm pretty sure that these are the VS08 GUIDs. I don't know if they'll work in other versions but the idea would be the same. Find out the web item templates GUID and add it in. |
|||
|
|