Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8856789
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T14:26:11+00:00 2026-06-14T14:26:11+00:00

I add a ScatterViewItem dynamically as so, noting that I am not creating a

  • 0

I add a ScatterViewItem dynamically as so, noting that I am not creating a ScatterViewItem specifically as they should be wrapped in one when added as per the docs:

VideosProducts videosProducts = VideosProducts.GetVideoProductsControl();
videosProducts.Name = "VideosProducts";
main.Items.Add(videosProducts);
ScatterViewItem item = main.ItemContainerGenerator.ContainerFromItem(videosProducts) as ScatterViewItem;
item.ApplyTemplate();
item.Background = new SolidColorBrush(Colors.Transparent);
item.ShowsActivationEffects = false;
item.Center = new Point(430, 820);
SurfaceShadowChrome ssc = item.Template.FindName("shadow", item) as SurfaceShadowChrome;
ssc.Visibility = Visibility.Hidden;

But now when I try to remove them as follows:

Window window = Application.Current.Windows.Cast<Window>().SingleOrDefault(x => x.IsActive);
ScatterView main = UIHelper.FindChild<ScatterView>(window, "MainScatterView");
List<ScatterViewItem> svItems = main.Items.Cast<ScatterViewItem>().Where(svi => svi.Name != "MenuControl").ToList();

I get an invalid cast exception. What gives? I thought these items were added as ScatterViewItems?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T14:26:12+00:00Added an answer on June 14, 2026 at 2:26 pm

    use the same ItemContainerGenerator.ContainerFromItem mechanism as in the above code for each item in the second code.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How add some style only to GWT container, not to all widget that container
add to cart not working in mozila firefox but it is working in internet
add value to one-dimentional array in php is: $arr1[] = $value; how to add
Add non monospace font, tab space in container, etc... So how does one derive
I add a bunch of FragmentTransactions to the back stack in one Tab, and
Add service reference to Amazon service fails, saying Could not load file or assembly
I add 3 views for an application and they need to switch from 1-2-3.
I add that to my header <%@ Page Language=C# MasterPageFile=~/Views/Shared/Site.Master Inherits=System.Web.Mvc.ViewPage %> and am
add(new CustomLabelField (Please enter your credentials:, Color.WHITE, 0x999966, 0)); What is that 0x999966? I
Add multiple items to text-area with duplicate items. I have one text-area which store

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.