Using the WPF Visualizer in Visual Studio 2010

Visual Studio 2010 now has a cool little feature I want to show you. When you’re debugging WPF applications, you sometimes need to see the controls and their hierarchy. Now with VS2010 this is easy. Simply use the magnifying class (the visualizer feature) and select the WPF Tree Visualizer:

image 

This will show you all the controls with their properties like this:

image 

In the left pane you get the tree view of controls with a rendering of the selected control, at the right side you get all properties of the control.

Comments (22) -

  • web tasarım

    2/1/2014 1:17:53 AM |

    It’s hard to find knowledgeable people on this topic, but you sound like you know what you’re talking about! Thanks

  • bursa web tasarım

    2/1/2014 1:18:29 AM |

    It’s hard to find knowledgeable people on this topic, but you sound like you know what you’re talking about! Thanks

  • bursa web tasarım

    2/2/2014 9:48:27 AM |

    There is noticeably a bundle to know about this. I assume you made certain nice points in features also.

  • Oz T-shirt Printing

    2/12/2014 12:34:11 PM |

    I have read this post and if I could I wish to suggest you some interesting things or suggestions. Maybe you could write next articles referring to this article. I wish to read more things about it!

  • Oz T-shirt Printing

    2/12/2014 12:42:47 PM |

    Hi would you mind stating which blog platform you’re using? I’m looking to start my own blog in the near future but I’m having a tough time making a decision between BlogEngine/Wordpress/B2evolution and Drupal. The reason I ask is because your design and style seems different then most blogs and I’m looking for something completely unique. P.S Apologies for being off-topic but I had to ask!

  • Phone Numbers

    3/17/2014 8:23:15 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    3/20/2014 11:53:45 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    3/21/2014 1:01:55 AM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    3/25/2014 9:49:36 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/1/2014 12:49:46 AM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/3/2014 9:04:39 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/6/2014 9:23:00 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/10/2014 8:32:45 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/27/2014 10:24:23 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • Phone Numbers

    4/28/2014 8:19:25 PM |

    The Numbers Helpline has sourced 1000's of customer service contact <a href="www.numbershelpline.co.uk/.../";>Phone numbers</a> in the UK. We know how hard it can be to find those <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> at times that why we have made a directory with them all in one place so you will never have waste long periods of time looking for a customer service contact <a href="www.numbershelpline.co.uk/.../";>Phonenumbers</a> again.

  • 0TXubiZD

    5/13/2014 4:35:40 AM |

    326991 389577This web-site is in fact a walk-through rather than the information you desired concerning this and didn�t know who to inquire about. Glimpse here, and you will definitely discover it. 778902

  • pengacara perceraian jakarta

    6/8/2014 2:40:26 AM |

    kunjungi kami azab

  • Kasy fiskalne Warszawa

    7/17/2014 6:08:57 AM |

    Mazowieckie Centrum Fiskalne poleca najlepsze kasy fiskalne Warszawa. Dobra kasa fiskalna Warszawa w Mazowieckim Centrum Fiskalnym.

  • Odtrucia Alkoholowe Warszawa

    7/17/2014 8:41:38 AM |

    Polecamy najlepsze Odtrucia Alkoholowe Warszawa. Najlepsze odtrucia poalkoholowe w Warszawie tylko u nas.

  • real racing 3 cheats youtube

    8/7/2014 10:38:13 PM |

    Thanks  for another informative site. Where else could I get that kind of info written in such an ideal way? I've a project that I'm just now working on, and I've been on the look out for such information.

  • DEBORA Laurence

    8/16/2014 4:54:31 AM |

    annuaires-gratuit.com/ vous propose de créer gratuitement un annuaire de sites internet pour un bon référencement.

  • shortcuts for emr systems

    8/21/2014 6:07:15 AM |

    I simply could not depart your website prior to suggesting that I actually loved the standard info an individual supply to your guests? Is gonna be back continuously in order to inspect new posts

  • link

    9/2/2014 2:22:00 AM |

    I take pleasure in, result in I discovered just what I used to be having a look for. You've ended my four day long hunt! God Bless you man. Have a nice day. Bye

  • porn

    9/3/2014 9:10:50 AM |

    Zune and iPod: Most people compare the Zune to the Touch, but after seeing how slim and surprisingly small and light it is, I consider it to be a rather unique hybrid that combines qualities of both the Touch and the Nano. It's very colorful and lovely OLED screen is slightly smaller than the touch screen, but the player itself feels quite a bit smaller and lighter. It weighs about 2/3 as much, and is noticeably smaller in width and height, while being just a hair thicker.

  • porn

    9/3/2014 12:15:18 PM |

    This is getting a bit more subjective, but I much prefer the Zune Marketplace. The interface is colorful, has more flair, and some cool features like 'Mixview' that let you quickly see related albums, songs, or other users related to what you're listening to. Clicking on one of those will center on that item, and another set of "neighbors" will come into view, allowing you to navigate around exploring by similar artists, songs, or users. Speaking of users, the Zune "Social" is also great fun, letting you find others with shared tastes and becoming friends with them. You then can listen to a playlist created based on an amalgamation of what all your friends are listening to, which is also enjoyable. Those concerned with privacy will be relieved to know you can prevent the public from seeing your personal listening habits if you so choose.

  • porn

    9/6/2014 12:42:24 AM |

    Apple now has Rhapsody as an app, which is a great start, but it is currently hampered by the inability to store locally on your iPod, and has a dismal 64kbps bit rate. If this changes, then it will somewhat negate this advantage for the Zune, but the 10 songs per month will still be a big plus in Zune Pass' favor.

  • Bennie Hyams

    9/21/2014 10:30:46 AM |

    Good work Smile cheers!

  • Erwin Sandager

    9/24/2014 3:15:53 AM |

    I was just seeking this info for a while. After six hours of continuous Googleing, at last I got it in your website. I wonder what's the lack of Google strategy that do not rank this kind of informative sites in top of the list. Generally the top websites are full of garbage.

  • readiris

    10/6/2014 10:49:55 AM |

    A person necessarily lend a hand to make seriously posts I'd state. This is the very first time I frequented your web page and thus far? I amazed with the research you made to create this particular post incredible. Magnificent task!

  • abby fine reader

    10/6/2014 1:18:39 PM |

    Thanks  for any other excellent article. Where else may anyone get that type of information in such a perfect way of writing? I've a presentation next week, and I'm on the look for such information.

  • interior

    10/7/2014 3:17:18 PM |

    Interior Design Company Renovation Company JM Interior M Sdn Bhd

  • here

    10/29/2014 12:41:47 PM |

    I simply want to say I'm all new to blogging and site-building and definitely savored your page. Very likely I’m likely to bookmark your blog post . You amazingly come with perfect posts. Kudos for revealing your website.

  • acai berry diet pills

    11/4/2014 4:10:03 AM |

    There is noticeably a bundle to know about this. I assume you made certain nice points in features also.

  • DEBORA Laurence

    11/12/2014 4:15:01 AM |

    Forum Annuaires-gratuit.com, annuaire de sites web et moteur de recherche sur annuaires-gratuit.com/annuaires/ .

  • idlife

    12/8/2014 6:18:44 AM |

    Nice post! Check out my site sometime!

  • Delmar Tavolario

    12/9/2014 7:36:18 AM |

    I was just roaming around to find an answer for my question, and now found another interesting answer here after reading the article..

  • Fidel Egas

    12/10/2014 3:41:31 AM |

    estupenda aportacion brillante sin más animo sigue así

  • Ulbricht, JŸrgen

    12/10/2014 3:58:23 AM |

    Toll Verkauf Wei§e Ware Nur Hier Kaufen Rabatt

  • Fidel Egas

    12/11/2014 12:41:54 AM |

    Creo que la info es buenísima brillante sin más muy crack!

  • Fidel Egas

    12/11/2014 6:46:48 AM |

    Creo que la info es buenísima merece un RT, gracias Smile genial

  • Mental Health Social Network

    12/14/2014 9:07:20 PM |

    Hello, nice post!

  • fishinglovers

    12/18/2014 3:29:00 AM |

    Looking forward to reading more. Great post.Really thank you! Want more.

Loading

File IO in Windows 8

File IO in Windows 8

Let’s leave Windows Phone for a moment, and let’s have a look at Windows 8. Recently the U2U-team was present at the Microsoft Build-convention in Anaheim, California, where Microsoft unveiled Windows 8. Now, what we saw is still just a preview, but it clearly shows the direction in which Windows is evolving. Have a look at this video, to see Windows 8 in action :

 

The “new style” applications Windows 8 offers are “Metro”-applications (yes, like in Windows Phone Metro style), and these can be made using Xaml and managed code, or even using HTML5 + Javascript. Metro-apps will have to be installed through a marketplace, and are kind of sandboxed (Comparable to Silverlight, but different ;-)  ). One of the effects of this sandboxing is that your options for working with files are limited. You cannot just access any folder on your machine ! Unfortunately you’re also unable to use Isolated Storage. So what can you use ? Let’s start by writing info into the “Local Folder”.

Windows.Storage.ApplicationData appData = Windows.Storage.ApplicationData.Current;
 
StorageFile file = await appData.LocalFolder.CreateFileAsync("EmployeeList.u2u");
Windows.Storage.Streams.IRandomAccessStream stream = await file.OpenAsync(FileAccessMode.ReadWrite);

 

No ordinary File here, but a StorageFile which I have to open to write in. The IRandomAccessStream I get back gives me the possibility to create an input- (for reading) or output-stream (for writing).

IOutputStream output = stream.GetOutputStreamAt(0);

 

And then I got stuck. The IOutputStream gives me a WriteAsync-function, but it ask me for an IBuffer-object. How to write data ? Luckily there’s already some MSDN-documentation available. That tells me to use a DataWriter which takes the IOutputStream as a constructor-argument.

DataWriter writer = new DataWriter(output);
writer.WriteString("HERE GOES DATA");
output.FlushAsync();

 

Not there yet ! The code I wrote starts fro; the assumption that File IO is much like the “ordinary” file IO: flush the stream and done. In Metro we have to ”commit” the data in the writer, and I have to start the flushing, so this is the working code :

   1:  DataWriter writer = new DataWriter(output);
   2:  writer.WriteString("HERE GOES DATA");
   3:   
   4:  await writer.StoreAsync();
   5:  output.FlushAsync().Start();    
   6:  statusTxt.Text = "File Saved";

 

They could have made it simpler Smile.
By localfolder I assumed the bin/debug-folder. Nothing there. It seems my file is located in C:\Users\michael\AppData\Local\Packages\d64899f1-9800-470a-9cb3-fa89210f4941_qs0a8q7rnpy8j\LocalState.

How about reading the file ? Well, simply reverse your writing-logic (writer becomes reader, output becomes input, store becomes load, …)

   1:  Windows.Storage.ApplicationData appData = Windows.Storage.ApplicationData.Current;
   2:   
   3:  var file = await appData.LocalFolder.GetFileAsync("EmployeeList.u2u");
   4:  Windows.Storage.Streams.IRandomAccessStream stream = await file.OpenAsync(FileAccessMode.Read);
   5:   
   6:  IInputStream input = stream.GetInputStreamAt(0);
   7:   
   8:  DataReader reader = new DataReader(input);
   9:   
  10:  var size = stream.Size;
  11:  await reader.LoadAsync((uint)size);
  12:  var data = reader.ReadString((uint)size);

 

There you go!

What about other folders than the “local” ? The KnownFolders=clqss gives me access to following locations :

  • Documents Library
  • Home Group
  • Media Server Devices (DLNA – Digital Living Network Alliance Devices, sounds interesting)
  • MusicLibrary
  • Pictures Library
  • Removable Devices
  • Videos Library

Let’s change the first 2 lines of my writing-code for using the documents library :

StorageFolder doclib = Windows.Storage.KnownFolders.DocumentsLibrary;
 
StorageFile file = await doclib.CreateFileAsync("EmployeeList.u2u");

 

As soon as you start running your code, it will fail on the first line (no exception though, simply stops). That’s because you explicitly have to give the app the capability to access the Document library. Double-clicking on Package.appxmanifest allows you to do that :

image

Still: this time your app will stop on the second line. You also need to associate your app with the u2u-fileextension. This is also done in the appxmanifest-file in the declarations-tab where we add a filetype association declaration :

image

There you go: the app works and saves my u2u-file in the doclibrary.

Loading