locked
Design time data not visible for Win8.0 apps on Win 8.1 RRS feed

  • Question

  • I cannot seem to get design time data for GridView to work in my Windows 8.0 app developed in Visual Studio 2012 on Windows 8.1 Pro.

    The exact same code and design data DOES work in Windows Phone.

    In addition, it starts working if I change the control in my Windows 8.0 app from gridview to listview.

    Seems like a bug, as also found here (the only other reference I could find to this problem): http://stackoverflow.com/questions/20594503/windows-8-store-gridview-design-time-doesnt-work

    Is this a limitation/bug? is there any way to workaround it? I need to update my 8.0 app and can't just jump straight to 8.1.

    Any ideas? thanks!

    Saturday, February 15, 2014 12:03 AM

Answers

  • I ended up fixing this and enabling the design-time data again by modifying the ItemsPanelTemplate of the GridView to be a VariableSizedWrapGrid. Simply adding this to the GridView:

    <GridView.ItemsPanel>
    	<ItemsPanelTemplate>
    		<VariableSizedWrapGrid />
    	</ItemsPanelTemplate>
    </GridView.ItemsPanel>

    seems to do the trick. Perhaps there is a bug in the regular WrapGrid when opening a Windows 8 app project on Windows 8.1? I'm sure the frequency of this is so low it's probably not worth doing anything about it, but hopefully someone who does search for this finds this helpful.

    PS regarding making the ListView look like GridView (or vice versa) it occured to me that this would be a nice way to handle changing from filled to "snap" view, instead of having to maintain two separate controls and templates, you could simply relay it out...

    I didn't have much luck with this, but it's something I've always wondered about. anyway that's another topic, thanks for your help and attention!

    Thursday, February 27, 2014 7:02 AM
  • Hi josh

    Sorry, currently there is no place to track WinRT bugs. Connect is the only site for bugs but they do not accept winrt bugs. However I already reported this to seniors.

    Make a ListView looks like GirdView? Take a look at this: Item templates for grid layouts, Is this what you need? By setting the following code we should be able to make ListView looks like GridView.

    <ListView.ItemsPanel>
            <ItemsPanelTemplate>
                <ItemsWrapGrid MaximumRowsOrColumns="8"/>                      
            </ItemsPanelTemplate>
        </ListView.ItemsPanel>
    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.


    Monday, February 24, 2014 6:04 AM
    Moderator
  • As I talked with our senior engineers, they could not identify if this is a WinRT bug or a IDE bug. For this reason, I will fire this bug in both places.

    Here I submitted a BugReport ticket for you on connect : https://connect.microsoft.com/VisualStudio/feedback/details/824688/win8-0-app-design-time-data-not-working-with-vs-2013#tabs

    Please vote it and track the state of this ticket, hope this helps.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Thursday, February 27, 2014 7:39 AM
    Moderator

All replies

  • Hi there,

    Thank you for reporting this to us. I could also reproduce the issue.

    I download the sample from http://irisclasson.com/2013/02/03/a-simple-design-time-data-example-with-windows-store-applications-for-beginners/ , a GirdView design time data sample on Win8.0 App.

    I will fire this to senior engineers as a bug. Thank you for reporting this.

    Working with ListView:

    Working with GirdView, Nothing:

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, February 17, 2014 11:18 AM
    Moderator
  • thank you for confirming this, did this actually get logged as a bug? if I'm doing something wrong, or if there's something I can do to make this work I'd sure like to know.

    Unfortuately I cannot update/retarget my app to 8.1, i need to first update the 8.0 version, but I'm doing it blind, because no matter what I try to do, I cannot get any data to show up in my gridview.

    Is it possible to simply replace the GridView with a ListView and have the listview lay the items out like a grid? I recall reading somewhere they are interchangeable, but can't find any specific resources telling me how to do it.

    last question: is there any place I can track the status of the bug (assuming that's what it is)?

    thank you again for your help

    josh

    Friday, February 21, 2014 11:58 PM
  • Hi josh

    Sorry, currently there is no place to track WinRT bugs. Connect is the only site for bugs but they do not accept winrt bugs. However I already reported this to seniors.

    Make a ListView looks like GirdView? Take a look at this: Item templates for grid layouts, Is this what you need? By setting the following code we should be able to make ListView looks like GridView.

    <ListView.ItemsPanel>
            <ItemsPanelTemplate>
                <ItemsWrapGrid MaximumRowsOrColumns="8"/>                      
            </ItemsPanelTemplate>
        </ListView.ItemsPanel>
    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.


    Monday, February 24, 2014 6:04 AM
    Moderator
  • I ended up fixing this and enabling the design-time data again by modifying the ItemsPanelTemplate of the GridView to be a VariableSizedWrapGrid. Simply adding this to the GridView:

    <GridView.ItemsPanel>
    	<ItemsPanelTemplate>
    		<VariableSizedWrapGrid />
    	</ItemsPanelTemplate>
    </GridView.ItemsPanel>

    seems to do the trick. Perhaps there is a bug in the regular WrapGrid when opening a Windows 8 app project on Windows 8.1? I'm sure the frequency of this is so low it's probably not worth doing anything about it, but hopefully someone who does search for this finds this helpful.

    PS regarding making the ListView look like GridView (or vice versa) it occured to me that this would be a nice way to handle changing from filled to "snap" view, instead of having to maintain two separate controls and templates, you could simply relay it out...

    I didn't have much luck with this, but it's something I've always wondered about. anyway that's another topic, thanks for your help and attention!

    Thursday, February 27, 2014 7:02 AM
  • As I talked with our senior engineers, they could not identify if this is a WinRT bug or a IDE bug. For this reason, I will fire this bug in both places.

    Here I submitted a BugReport ticket for you on connect : https://connect.microsoft.com/VisualStudio/feedback/details/824688/win8-0-app-design-time-data-not-working-with-vs-2013#tabs

    Please vote it and track the state of this ticket, hope this helps.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Thursday, February 27, 2014 7:39 AM
    Moderator