i can't find Forms ContentPage Xaml

IlayarajaCIlayarajaC USMember
edited September 2015 in Xamarin.Forms

i created PCL Xamarin forms application, in xamarin studio i was able to add Forms (Forms ContentPage Xaml), in Visual Studio i was able to see only code page. i cant add xaml page at all. i use VS 2013 Update 2.

Screenshots attached, look at those three forms option i'm able to add only code file. not xaml and associated desinger and code file.

please can anybody help me to resolve this?

Posts

  • JasonAwbreyJasonAwbrey USInsider, University, Developer Group Leader mod

    What happens when you try to use the XAML option? Does it give you an error message or exception?

  • IlayarajaCIlayarajaC USMember
    edited September 2015

    Hi Jason,

    Not sure what has happened, i tried adding first two option..was not successful, i was only able to add a cs file.
    now i added the xaml page (though the extension comes still as.cs which i confused with that earlier).

    Thanks a lot.

    Thnx,
    Ilayaraja

  • MayFlowerMayFlower USUniversity ✭✭

    I was not able to add Xaml file but only C# file for both content page and content view when adding a new item, using VS Pro 2013. There is no issue to add Xmal page/view with C# from Xamarin Studio

  • RodyRody USMember ✭✭

    @IlayarajaC said:
    Hi Jason,

    Not sure what has happened, i tried adding first two option..was not successful, i was only able to add a cs file.
    now i added the xaml page (though the extension comes still as.cs which i confused with that earlier).

    Thanks a lot.

    Thnx,
    Ilayaraja

    The problem is the name that Xamarin uses for the Xaml option is confusing. That third option does actually create a xaml ContentPage and the c# code behind page for it as well with the extension.

  • MrEdMorteMrEdMorte USMember
    edited June 2016

    Hello IlayarajaC,

    I have the same problem that you reported, but in VS 2015.

    Try to do this:
    1) save your project.
    2) close the Visual Studio IDE.
    3) open the IDE and your PCL project again.
    4) in the Solution Explorer right-click the Portable project, select Add > New Item from the menu. At the left of the Add New Item dialog, select Visual C# and Cross-Platform, and in the center area choose Forms Xaml Page or another one that you need.

    Best regards,
    MrEdMorte

  • MikeleFMikeleF USMember

    Hello, i know this topic is old, but if someone nowaday has the same problem, i suggest (as i had) to try this:

    copy XamlPage.zip from

    C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Xamarin\Xamarin\4.0.3.214\T\IT\Cross-Platform\Code

    to

    C:\Users\your name here\Documents\Visual Studio 2015\Templates\ItemTemplates\Visual C#

    Then you should find the Forms Xaml Page from the left menù under "Cross-Platform"

    Solution found here:
    https://damianblog.com/2016/04/08/vs2015-xaml-forms-xaml-missing/

  • gyanvermagyanverma INMember

    not worked for me

    to many problems with xamarin

  • ajaxerajaxer AUMember ✭✭

    If you are interested to modify the Xamarin templates that are actually installed, you may need to try a few different directories to locate the templates that the current Xamarin version is using.
    As mentioned above, you can find the templates somewhere under the directory C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions.
    What you are looking for is a directory named ? "\T\~IC\I\CSharp\Cross-Platform".
    I did not find this in the folder "Xamarin\Xamarin\4.0.3.214\T" (your version number may vary).

    However by dint of looking at every folder in the Extensions directory I did find several folders (with obscure names like "nbuy5gms.zve" or some other random letters) that contain Xamarin files. Under these you will find the Cross-Platform folder and the template files.
    Try modifying those for your desired customisations.
    You will need to close and reopen VS for the changes to be found.

Sign In or Register to comment.