Quantcast
Channel: Visual Studio and Visual Web Developer Express
Viewing all articles
Browse latest Browse all 3509

Third-party controls affecting intellisense with user controls in .Net 4.0 only

$
0
0

Hi,

I have a weird intellisense problem, when I no longer see in intellisense my user control and this issue is affected by third party controls. When i reference devxpress/telerik controls in my user control, there are cases when intellisense stops working for that user control. I have managed to find a simple case to illustrate the problem. In the test below the devxpress/telerik control breaks intellisense only when the ValidateRequestMode property is used. Please note that the problem only exists in .Net 4.0. I tried the same test in .Net 4.5 and the issue does not exist.


Step 1

I have contacted the specified control vendors and after analysing the problem stated that this is VS problem rather than their assemblies. 

This is the test:


1. An empty asp.net solution in .Net 4.0
2. In user control (ascx file):

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="WebUserControl1.ascx.cs" Inherits="Test.WebUserControl1" %>
<devxEditors:ASPxHyperLink ID="test1" runat="server" ValidateRequestMode="Disabled"></devxEditors:ASPxHyperLink>

4. Clean the solution. Rebuild the solution. Restart VS. Try to find the user control in intellisense on an empty form. It doesn't work. 


Please find the project sample at the following url:

http://www.sendspace.com/file/v6k394



Step 2

The vendor controls are descendants of the standard WebControl class and do not override the Control.ValidateRequestMode Property.

To show you that this issue is related to the Visual Studio functionality, I removed all our references from the previous project. After that, I tested the project. The same problem is reproduced when using a custom control in the WebUserControl.

Attached is the modified sample along with a screencast demonstrating the incorrect behavior. You can check the project yourself to see what I mean.

http://www.sendspace.com/file/w5uv0b

The problem is related to the VS functionality.




Viewing all articles
Browse latest Browse all 3509

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>