locked
Intellisense Stops Working - STILL (3/Feb/2008)

    Question

  •  

    I thought I had best start a new thread, as the one in which someone reported this before has been marked as solved. It isn't.

     

    As reported here: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1958370&SiteID=1

     

    If you put a xmlns reference to a namespace of your own, it totally hoses intellisense. I cannot believe that this has been overlooked, so I must assume there is a much more obvious way to get references to your own code into XAML.

     

    I am using:

    Microsoft Visual Studio 2008
    Version 9.0.21022.8 RTM
    Microsoft .NET Framework
    Version 3.5

    Installed Edition: C# Express

    Microsoft Visual C# 2008   91910-152-0000061-60495
    Microsoft Visual C# 2008

     

    the following example will allways break intellisense:

     

    <Window x:Class="CodeWords.CodeWordsPrintWindow"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:Interface="clr-namespace:CodeWords.Interface"

    Title="Test" Height="Auto" Width="Auto" x:Name="PrintWindow" WindowStartupLocation="CenterScreen" WindowState="Maximized">

     

    Remove the xmlns:Interface line

     

    <Window x:Class="CodeWords.CodeWordsPrintWindow"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    Title="Test" Height="Auto" Width="Auto" x:Name="PrintWindow" WindowStartupLocation="CenterScreen" WindowState="Maximized">

     

    Intellisense works! But the code doesn't. This gets really bad whenever your working on a bit actually using the namespace. Either way you can't get intellisense help.

     

    I'd appreciate it if someone can confirm that this is a known bug, or tell me what I should be doing instead, as this is driving me mad reming the line in/out and loosing intellisense.

     

    Thanks

     

    Ben

    Sunday, February 03, 2008 1:38 PM

Answers

  • Thanks very much for taking the time to report this issue to us and for providing the repro sample.  We have reproduced and fixed this bug.  This was happening due to an issue with the enums being used as objects in the XAML.  This caused our parsing of the file to fail and no intellisense to be shown for the document. The fix will appear in our next service pack (release date TBD).
    Wednesday, February 13, 2008 6:36 PM

All replies

  • Is it possible for you send me a project that demonstrates this issue so I can investigate?

    send it to mark(bou)@microsoft.nospam.com without the () and the .nospam

    thanks

    mark

     

     

     

     

     

     

    Wednesday, February 06, 2008 12:44 AM
    Owner
  • You should have mail.

    Let me know if you havn't received it.

     

    Thanks

    Saturday, February 09, 2008 4:38 PM
  • I have the same issue where if I try to reference a local class within the same namespace and assembly as my app by using xlmns:local="clr-namespace:<nameSpace>;assembly="
    It will show an error unless after I write that out I save it close all the windows and re-build the application!

    And another note: Usually I am forced to re-build quite often just to get the ToolBox to load the post setup stuff
    such as the General, Common, Controls; almost all the time the list in the ToolBox just disappears and I have to fiddle around by selecting parts of the Window in Design mode and unloading reloading the file as well as rebuilding the Application to get the Tools in there!  Sometimes it can take about 15 minutes of playing to get it done right this way!

    Has anyone else had these troubles?


    Here is a picture of the Intellisense messing up:: http://tinyurl.com/24zgpa

    ---
    William.
    Saturday, February 09, 2008 9:46 PM
  • Thanks very much for taking the time to report this issue to us and for providing the repro sample.  We have reproduced and fixed this bug.  This was happening due to an issue with the enums being used as objects in the XAML.  This caused our parsing of the file to fail and no intellisense to be shown for the document. The fix will appear in our next service pack (release date TBD).
    Wednesday, February 13, 2008 6:36 PM
  •  

    Cheers, I appreciate you sorting that out. It's still irritating until I get the fix, but it's good to know that I'm not going mad, there is a problem! Smile

     

     

    Ben

    Thursday, February 14, 2008 2:51 PM
  • I am having the same issue.  Is there a work around until SP1 is released?
    Tuesday, June 24, 2008 3:55 PM
  • I know it's been a while since the last post, but I'm seeing the exact same behavior, and I have SP1/.Net 3.5 installed.

    VStudio 2008
    Version 9.0.30829.1 SP

    .Net Framework
     Version 3.5 SP1

    Any thoughts?

    -pete-

    --EDIT--
    I found that using the complete syntax for the xmlns attribute, even though it shouldn't be needed, fixes the problem:
    xmlns:Foo="clr-namespace:Foo" causes Intellisense to break, but xmlns:Foo="clr-namespace:Foo;assembly=Foo" doesn't cause the issue

    -pete-
    Wednesday, November 19, 2008 7:52 PM
  • I found that using the full syntax for the clr-namespace attribute fixes, or at least doesn't cause the issue:

    xmlns:Foo="clr-namespace:Foo" 

    causes the issue, but

    xmlns:Foo="clr-namespace:Foo;assembly=Foo" 

    does not.

    -pete-
    • Proposed as answer by KrunalC Thursday, March 26, 2009 6:24 AM
    Wednesday, November 19, 2008 8:18 PM
  • Pete,

    I also had a similar problem as explained in the post but your solution worked for me.

    Life was very difficult without intellisense and i did reinstall/repair the studio in order to fix the problem but all in vain.

    your suggestion indeed helped me a lot.

    Thanks,

    Krunal

    Krunal C
    Thursday, March 26, 2009 6:24 AM