Visual Studio 2015 intellisense regression when editing XAML files

2»

Answers

  • ErosSteinErosStein BRMember

    @jonathanyates to be honest I've wondered that myself... about the road not taken xD
    about that I had the same problem, I think I had to do something related to my entitlements.plist... lemme check that and I'll get back to you

  • jonathanyatesjonathanyates GBMember ✭✭✭

    Fixed the signing keys issue. I had to revoke and request cos I have a new Mac. That works now, just with lots of spoof errors though.

  • ErosSteinErosStein BRMember

    @jonathanyates nice... good luck with the errors... but I think that's only gonna be fixed when Xamarin releases a new package, who knows...

  • jonathanyatesjonathanyates GBMember ✭✭✭

    Well, if we keep applying the pressure here then they might :)

    Any update on this Xamarin Guys?

  • opiantsopiants NZMember ✭✭
    edited July 2015

    @Marabunta @EroStein @jonathanyates I get those intellisense errors as well and frustratingly, that means that you don't get intellisense in your .cs files! Interestingly though, if you close your proj, delete the /obj folder for the Forms project then you reopen it, all those errors go away and you get your intellisense back.

    @BrendanZagaeski Any news? What's the new eta for that July 27 update?

    P.S. backup your obj folder just in case

  • AliBazziAliBazzi MYMember
    edited August 2015

    well, that solved the auto completion for me in Xaml files, but what about the code behind files ?
    I have many errors that all lead to the fact that the IntelliSense can't see the original Xaml files Elements, for example the IntelliSense reports an error about "The name 'InitializeComponent' does not exist in the current context".
    any help on that ?
    although, building the project works as expected.

  • AllisterAllister USMember ✭✭

    I had 87 errors which went away when I gave the App file the full name that included the PCL portable namespace, i.e. it went from being App.xaml (and App.xaml.cs) to "MyApp".Core.App.xaml etc.
    Mental.
    Lots of my content pages are derived from a basepage, and I had the base type in the xaml files, but not the codebehinds (as its redundant, they're partial files after all), then after an update on Friday I had 120 errors, until I put the derived base type back in the codebehind as well, i.e. simply added " : BasePage {" to the start of each code behind.
    Hanging out to see what the next update fixes...and hopefully doesn't break much.

  • RemmoRemmo ITMember

    Hi @VGA , thanks for the fix but it doesn't work on custom class, there's a way to fix it?

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    what about the code behind files

    Note that there is an unrelated issue in certain versions of the Xamarin.Forms NuGet package that causes problems for Intellisense in the code behind files (on all versions of VS):

    https://bugzilla.xamarin.com/show_bug.cgi?id=32341

  • opiantsopiants NZMember ✭✭

    @BrendanZagaeski Why is that marked as fixed? I'm on the latest nuget package and still have the same problem (and so is the last person that made a comment there). Should that be re-opened?

  • DavidSpeakDavidSpeak GBUniversity ✭✭

    @BrendanZagaeski Sorry still getting this problem (using VS2015, Forms 6392, VS 666). When I open a project, all references to additional PCL library projects in the solution are shown as 'cannot be found' (Intellisense errors, not Build). However "InitializeComponent()" is Ok.

    When I build the solution, "InitializeComponent()" (and any references to x:Name in the XAML) is then also shown as "cannot be found". I never get any actual Intellisense in XAML files.

    Still think Xamarin Forms is superb - just need to get these niggles fixed (asap please :wink:)

  • kzukzu USXamarin Team, Insider Xamurai

    @opiants could you provide a repro project please? Email [email protected] ;-)

  • opiantsopiants NZMember ✭✭
    edited August 2015

    @kzu this could be related to this workaround. Will try to create a clean project and see if I can replicate it. Will let you know. The ultimate fix would be getting the intellisense working back in vs 2015 so we don't have to apply the workaround.

  • Vinnie1991Vinnie1991 USMember ✭✭

    @JamesMontemagno there is an issue with this workaround: VS2015 Hangs/crashes most of the time.
    See thread: http://forums.xamarin.com/discussion/47166/vs2015-rtm-keeps-freezing

    When is the WORKING version with Xamarin.Forms Intellisense?!

  • jonathanyatesjonathanyates GBMember ✭✭✭

    @kzu Just create a new XF solution. The suggested workaround of deleting the bin and obj files doesn't fix this for long. Problem returned after a few minutes after I'd made some changes.

    Any ETA on a fix and a fix for the intellisense code errors that aren't errors for anything referencing another PCL ?

  • kzukzu USXamarin Team, Insider Xamurai

    C# intellisense is completely unrelated to XAML intellisense.

    The PCL issue was introduced by Roslyn in VS2015, with a fix coming out in the next Xamarin service release. @JamesMontemagno could you point the thread to the workaround we have for that too?

    Thanks!

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    Quick note: there is a new additional "accepted answer" at the top this thread now with a summary of the various Intellisense issues.

  • jonathanyatesjonathanyates GBMember ✭✭✭

    @BrendanZagaeski @kzu

    So we are waiting a new release of XF which will fix both these issues (XAml and code). Please could you provide an ETA on this release?

  • robbschieferrobbschiefer USMember, University

    XF Xaml Intellisense workaround didn't work for me either. What is the ETA for the official fix?

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai
    edited August 2015

    I believe both of the fixes in the Xamarin.Forms NuGet package are now included in the new Xamarin.Forms 1.5.0-pre1 prerelease. Unfortunately it sounds like the new Xamarin.Forms XAML Intellisense is still somehow leading to VS 2015 hangs. One initial suspicion is that this hanging behavior might be within VS 2015 itself. (Really all the Xamarin.Forms Intellisense files are doing is feeding metadata to the built-in WPF XAML Intellisense engine.)

    I haven't yet had a chance to try to reproduce the hanging behavior myself. It sounds like it is easy to reproduce even in a template app, so hopefully I will be able to see it quickly when I start experimenting. That said, if anyone would like to submit a test case and a set of steps that they know consistently demonstrates the problem, that would be perfect too. You can either attach the test case back on a new comment in this thread, email it to the VS team as mentioned earlier, submit it in a bug report (optionally marked private), or send it to the support team via email (and ideally also mention my name in the email). Thanks in advance.

  • jonathanyatesjonathanyates GBMember ✭✭✭

    @BrendanZagaeski @kzu

    The Xamarin.Forms 1.5.0-pre1 prerelease seems to fix the Blue underlining issues in the Xaml. That's great. I have R# installed to so I dunno how weill intellisense works with out this but for me it seems good now. Thanks.

    However, the other issue of intellisense errors appearing in code (which are not really errors) is not fixed. It all seems fine until the momemt I edit a Xaml file (thought it was fixed until this point) and then when I switch to a code file the errors all appear again. Note the errors are for any code that is referencing something in another PCL (my core PCL in my case). And also note that I think it only happens if I edit a Xaml file that is also referencing anything from my Core PCL, but I can't confirm this. Best way to replicate this is to create a new solution and add a second PCL with some stuff in it and then refence that from your main project PCL. Make sure you try this will stuff referenced in Xaml files as well as view model code.

    The above is all quite irritating but not nearly as bad as the fact the VS 2015 continues to regularly hang all the time, with a pop-up message saying Visual Studio Busy. Obviously very busy because it never comes back. I am also running using Parallels and Win8.1 (given up on W10). I read somewhere that the file sharing between Mac and Windows might have something to do with this. I need to test this but turning that off isn't really practical for me.

  • WilliamRaifordWilliamRaiford USMember ✭✭

    I am moving to a new Windows 10 VM (Hyper-V) and I'm also getting the red underlines that aren't really errors. It is saying it is unable to find the type 'Object', and since that involves pretty much every line it is quite unusable. I have not had it hang.

    I was really stoked to explore the new Windows 10 + VS 2015 + Xamarin landscape, but I'm gonna have to go back to Xamarin Studio for now. I figure this is just Roslyn analyzer jitters that used to be resolved with testing, but nowadays with the agile mindset it is tested on the fly.

    Looking forward to the fixes and I hope that Xamarin let's us know when this is resolved!

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    The last 2 comments sound like Bug 32622. That bug is mentioned briefly in one of the "answers" on the first page of the thread along with a workaround. Since we've started running into the problem where it's getting tricky to keep track of the various issues in this thread, I have created a new thread for discussion of any XamarinVS issues related to VS 2015. (The new thread uses the format of the Xamarin release announcements: all of the known issues will be kept up-to-date in the first post in the thread.)

    http://forums.xamarin.com/discussion/47943/upstream-release-microsoft-visual-studio-2015-rtm/p1

    I will now close this thread to direct all further discussion onto that thread.

This discussion has been closed.