WPF 3.5 SP1 App Model with Jennifer Lee
- Posted: May 16, 2008 at 12:51 AM
- 22,439 Views
- 23 Comments
Download
How do I download the videos?
- To download, right click the file type you would like and pick “Save target as…” or “Save link as…”
Why should I download videos from Channel9?
- It's an easy way to save the videos you like locally.
- You can save the videos in order to watch them offline.
- If all you want is to hear the audio, you can download the MP3!
Which version should I choose?
- If you want to view the video on your PC, Xbox or Media Center, download the High Quality WMV file (this is the highest quality version we have available).
- If you'd like a lower bitrate version, to reduce the download time or cost, then choose the Medium Quality WMV file.
- If you have a Zune, WP7, iPhone, iPad, or iPod device, choose the low or medium MP4 file.
- If you just want to hear the audio of the video, choose the MP3 file.
Right click “Save as…”
- Mid Quality WMV (Lo-band, Mobile)
- MP3 (Audio only)
- WMV (WMV Video)
I spoke with Jennifer Lee about what's new in the Application Model realm for WPF 3.5 SP1. Topics include the improved cold start, splash screen and a demonstration of HTML and XBAPs using the new WebBrowser control.
Looking for more than application model? Check out the WPF 3.5 SP1 Overview video
Looking for more than application model? Check out the WPF 3.5 SP1 Overview video
Comments Closed
Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation,
please create a new thread in our Forums,
or
Contact Us and let us know.
Follow the Discussion
Still can't help but wonder why they just didn't call it "WPF 3.6" it would be allot more clearer for developpers, because some things just don't run on 3.5 , most things are not updates/bug fixes but new features.
I know this seems to be the Microsoft way, but in this video almost every sentence Jennifer says begins so it.
Normally I don't notice these kind of things, but it was really off putting for me!
Sorry to rant - interesting information, but the delivery just grated on me.
Agreed -- or even just drop the whole SP and call it .Net 3.51
As hard as it may be to covince developers that its "a service pack with features" convincing users is even harder.
BTW I like the agility of the wpf team to come out with three really solid (looking) releases in such a short time frame. I just think that there is no reason to conflate a service pack with a release.
Why can't you guys remember to post a link to the LOW-RES file on every video that you do?
It's very irritating when downloading with BITS to have to wait on 600Mb files.
---dup---dup---
Beavis has spoken!
I've heard its a northwestern thing.
Will the WPF WebBrowser control be a DependencyObject and therefore bindable? Could I, for example, do this:
<WebBrowser DocumentText="{Binding MyHtmlProperty}" />
??

ps. You're right about the "so", guys - both Adam and Jennifer started almost every sentence with it!
I'm taking this to mean you want to be able to bind an HTML string to some property on the WebBrowser and cause the WebBrowser to navigate when the data bound to the property is updated.
A few things here -
Yes, the WebBrowser control is a DependencyObject. However, we would have to expose navigating to an HTML string as a property (specifically, a DependencyProperty) for the databinding to work, and for it to work in XAML, which we do not. The functionality of navigating to an HTML string is achieved by calling the WebBrowser.NavigateToString() method. You will need to implement your scenario in code by calling the NavigateToString() method.
Therefore, the answer is NO, you could not do this:
<WebBrowser DocumentText="{Binding MyHtmlProperty}" />
I can see how the above would be useful and convenient. The change would mean you could 'get' the html string loaded as well as 'set' it (which is what the method achieves). We may look into adding it for a future release. As always, your feedback and specific affected scenarios certainly help in these matters, so please keep it coming!
Thanks!
Jennifer
For my purposes I would only need to set the HTML string (a "OneWay" binding) since the browser control itself wouldn't be doing any updating. Perhaps I could define an attached property or something that called NavigateToString() when it was set?
I think the old example you often see of a WPF app that reads RSS feeds would be well-served by a simple property on WebBrowser that lets you bind directly to a string - that way the browser could be bound to the selected item in the feed and simply display it as the user navigates through the list of items.
Matt
Yes, that sounds like the right thing to do. You might also try writing a custom control that has a child WebBrowser, if you want encapsulation.
We are working on putting together some WebBrowser samples, and I think the RSS scenario would be a good one, as well.
Thanks!
Jennifer
need more wpf controls~~ anyway, nice video~
This works when using the browser normally (sans the embedded WPF behavior)
-----------------------------------
· Open Internet Explorer
· Go to Tools > Internet Options
· Click the Advanced tab
· Scroll down to the Security options
· Check the option that reads:
Allow active content to run in files on My Computer
Does the new webbrowser sp1 can be inside visualbrush ?
http://forums.msdn.microsoft.com/en-US/wpf/thread/9e89a10d-8d39-4f36-945b-f8777a6ef422 ?
A poor man's workaround for this problem is to create a user control that wraps the WebBrowser and offers the needed dependency properties. Here is a quick example:
XAML Defenition (MyWebBrowser.xaml):
<UserControl x:Class="RSSTest.MyWebBrowser"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="Auto" Width="Auto">
<WebBrowser Name="mWebBrowser">
</WebBrowser>
</UserControl>
C# code (MyWebBrowser.cs):
public partial class MyWebBrowser
{
public MyWebBrowser()
{
InitializeComponent();
}
public WebBrowser WebBrowser { get { return mWebBrowser; } }
public static readonly DependencyProperty StringHtmlProperty =
DependencyProperty.Register("StringHtml", typeof(string), typeof(MyWebBrowser),
new PropertyMetadata(new PropertyChangedCallback(OnStringHtmlChanged)));
public string StringHtml
{
get { return (string)GetValue(StringHtmlProperty); }
set { SetValue(StringHtmlProperty, value); }
}
private static void OnStringHtmlChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
MyWebBrowser me = (MyWebBrowser)d;
me.WebBrowser.NavigateToString(me.StringHtml);
}
public static readonly DependencyProperty UriProperty =
DependencyProperty.Register("Uri", typeof(Uri), typeof(MyWebBrowser),
new PropertyMetadata(new PropertyChangedCallback(OnUriChanged)));
public Uri Uri
{
get { return (Uri)GetValue(UriProperty); }
set { SetValue(UriProperty, value); }
}
private static void OnUriChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
MyWebBrowser me = (MyWebBrowser)d;
me.WebBrowser.Navigate(me.Uri);
}
}
Binding Examples:
<local:MyWebBrowser Uri="{Binding Path=Link}"/>
<local:MyWebBrowser StringHtml ="{Binding Path=HtmlString}"/>
<local:MyWebBrowser StringHtml="{Binding Path=Description, StringFormat={}<HTML><BODY\>\{0\}\<BODY\>\<HTML\>}"/>
Very nice sharing.thanks
<a href="http://www.medyum.info ">www.medyum.info</a></div>
nice share. thank you
Bedava dizi izle - http://www.dizikral.net
Thank you for sharing your article I would always follow.
<a href="http://www.askimchat.net" title="chat" target="_blank">chat siteleri</a>
Remove this comment
Remove this thread
close