Today morning I came across one news that, one of my another article on “Tips & Tricks: Customizing Visual Studio 2010 Start Page” came as “Articles of the Day” in Microsoft’s official WPF site: WindowsClient.net. I am really thankful to the entire team who gave my articles such honour. | |
Read the Original Article @ DotNetSpark.com. |
One of my other article “What’s New in Visual Studio 2010” came as “Articles of the Day” in Microsoft’s official WPF site: WindowsClient.net. I am really thankful to the team who are choosing my articles to publish in various forums. This time by DotNetSpark team.
Read the Original Article @ DotNetSpark.com
Silverlight 4 now supports printing functionality using the Printing APIs. Using the APIs, you can now print your whole application screen or a portion of the application. Also, you can customize the look while you printing your part/full application.
In this post, I will step you guys to the depth of the printing API. Don’t forget to share your thoughts. Suggestions are always welcome. This will help me to improve my articles.
It’s another great day when one of my other article on “Windows 7 Multi-touch Application Development” has been selected in Microsoft official WPF site: WindowsClient.net. It’s a great pleasure for me. Thanks to DotNetFunda Team for the honour.
Read the Original Article @ DotNetFunda.com
Microsoft has just released the Silverlight 4 RC with several changes in the Silverlight runtime & in the Silverlight tools. Though there are couple of changes since Silverlight 3 & since Silverlight 4 Beta but it supports most of the Silverlight 3 applications by using Quirks mode. In some cases your earlier application will break or behave differently.
In this post I will describe you both the breaking changes in Silverlight 4 since Silverlight 3 & Silverlight 4 Beta. But before going to the discussion on the breaking changes, let me tell you what is Quirks mode. Quirks mode is a behaviour by which your previous application will work on the new runtime. Simple example is that, if you have Silverlight 3 compiled application it will try to run in Silverlight 4 (some cases it will fail) using quirks mode but if you compile the same application in Silverlight 4 it will not use the quirks mode and through errors on the changes.
What’s new in Silverlight 4:
- XAP Signing
- Custom Chrome Window
- WebCam/Mic Configuration Preview
- Text position and Selection API
- Pinned full screen mode on secondary display
- Support for Private Browsing
- RichTextBox XAML clipboard format
- Elevated apps doesn’t have Sockets Security Restrictions
- Support for querying printer page size and printable area
- XmlnsPrefix & XmlnsDefinition attributes has been added
Breaking Changes since Silverlight 3:
So, lets start with describing the breaking changes in Silverlight 4 since Silverlight 3.
- Mouse Wheel Support - Silverlight 4 controls (ListBox, TextBox, ComboBox, ScrollViewer, Calendar, DatePicker, DataGrid) now have support for Mouse Wheel.
- Shared BitmapImage Source – Now Silverlight 4 will render the images properly if more than one Image controls are sharing the same BitmapImage source.
- ImageBrush.ImageSource returns ImageSource – ImageBrush.ImageSource in Silverlight 4 now returns ImageSource instead of UriSource which could be WritableBitmap or BitmapImage.
- Keyboard Navigation in TabControl – Keyboard navigation in TabControl was a feature in Silverlight 3 having an issue with the TabItem activation. Previously pressing Up Arrow activated the next TabItem and pressing Down Arrow activated the previous TabItem. In this release they fixed it to properly activate the TabItem. In Silverlight 4 if you press Up Arrow it will activate the previous TabItem & pressing Down Arrow will activate the next TabItem.
- Automation focus in DataGridCell - DataGridCell now receives automation focus when currency changes in the DataGrid, rather than focusing on the other part of the DataGrid.
- Hit Test while Toggling Full Screen Mode – While toggling full screen mode Silverlight 4 will now rerun hit testing. This allows controls that were under the mouse before toggling to update the MoouseEnter state if necessary.
- Whitespace handling with Span tag – TextBlock and RichTextArea now accepts text content & creates implicit runs generating whitespaces between inlines separated by CRLF.
- DisplayMemberPath & ItemTemplate recreates all containers – Silverlight 4 now recreates all containers by invalidating them while there is any change in DisplayMemberPath or in ItemTemplate properties of the ItemControl.
- New XAML Parser – Silverlight 4 now includes all new XAML Parser along with the previous XAML Parser. As per the runtime version detected in the application manifest it will parse the XAML in the appropriate parser. Apart from that, it has now additional benefits like “Better XAML compatibility”, “Greater parsing correctness & consistency”, “Better feedback error mechanism”, “Performance improvement”.
- Panels Clear() method calls InvalidateMeasure – If you call the Clear() method of the Silverlight 4 panel it will now explicitly call InvalidateMeasure.
- Virtualizing Stack Panel now scrolls by 3 lines – Mouse Wheel scroll in Silverlight 4’s Virtualizing Stack Panel will scroll by three (3) lines instead of one (1) line.
Breaking Changes since Silverlight 4 Beta:
If you were exploring Silverlight 4 Beta this section will be most important for you. There are some changes in both the runtime & tool since the beta release. So before starting with that please read the same carefully.
- Removed TextSelection.CanInsert – TextSelection.CanInsert is now no longer available in Silverlight 4.
- RichTextArea changed to RichTextBox – RichTextArea now renamed to RichTextBox.
- RichTextBox.TextDecorations no longer exists – RichTextBox.TextDecoration is not available now. Instead of it you can use Inline.TextDecorations.
- Default value to RichTextBox.TextWrapping – Silverlight 4 now has a default value of RichTextBox.TextWrapping to Wrap. If you don’t want to wrap your content you have to explicitly set it to NoWrap.
- HtmlBrush renamed to WebBrowserBrush – In Silverlight 4 HtmlBrush now renamed to WebBrowserBrush.
- COM Interoperability – COM Interoperability types are now moved to System.Runtime.InteropServices instead of System.Windows.Interop namespace.
- WebCam/Output Protection Support – There has been a huge changes in the webcam/output protection support:
- CanEnableHDCP renamed to CanEnableHdcp
- CanEnableCGMSA renamed to CanEnableCgmsa
- VGA, DVI, HDMI, LVDS, SDI, UDIExternal, UDIInternal also renamed to similar naming convention
- VideoFormat.Height and VideoFormat.Width renamed to VideoFormat.PixelHeight and VideoFormat.PixelWidth respectively
- AsyncCaptureImage call now changed to CaptureImageAsync
- NotificationWindow – NotificationWindow.Visible property has been changed to NotificationWindow.Visibility
Today morning when I checked my mail, I saw one mail regarding “Article of the day” from DotNetFunda.com mentioning one of my article titled “Windows 7 Multitouch Application Development (Part – I)” has been selected as “Article of the day” in Microsoft WPF site WindowsClient.Net.
Thank you DotNetFunda team.
Multi-targeting Application Development:
Using Visual Studio 2010 you can not only develop applications for the .Net 4.0 but also can use it for the development of earlier versions of the framework. While creating a new project in the IDE you will see the option to select between different types of .Net Framework (i.e. 2.0, 3.0, 3.5 & 4.0).
Depending upon your choice it will filter the project templates in the New Project dialog. If you select “.Net Framework 4.0” it will show all the project types but if you select “.Net Framework 2.0” it will only show the projects supported by .Net Framework 2.0.
Not only this, as Visual Studio 2010 builds on top of Windows Presentation Foundation (WPF), you will find it more useful while searching for a specific project type. Suppose, you want to develop an application for your client in WPF & you are finding it very difficult to search within a huge collection of project types. Don’t worry. There is a “Search Box” right to the dialog for you to help finding the same. Just enter the keyword (in this case “WPF”) & see the magic. While typing, it will auto filter based on the keyword you entered.
Faster Intellisense Support:
Visual Studio now came up with faster intellisense support. It is now 2-5 times faster than the earlier versions. The IDE will now filter your intellisense as you type. Suppose, you want to create an instance of “WeakReference” & due to the search algorithm of the VS2010 IDE, you don’t have to write the full word of the Class. Just type “WR” and it will automatically filter out that & show you “WeakReference” in the intellisense. Try it out.
Editor Zoom Functionality:
You will find this feature useful while you are showing some presentation or doing a webcast. Earlier VS2010 you have to open the options panel & then you have to change the font size of the editor, which was little bit troublesome. Now that issue is gone. You don’t have to follow where to go to change the text size. While inside the editor window, just press the control key (CTRL) and use your mouse wheel to increase/decrease the zoom level.
Faster Assembly loading in “Add Reference”:
In Visual Studio 2010 loading of assemblies in the “Add Reference” dialog is pretty fast. In earlier versions, it freezes the dialog for some time to load all the assemblies. In 2010 IDE, by default it focuses on the “Project” tab & in the background loads the other tabs. In case it is opening the dialog focusing on the “.Net” tab you will notice that instead of loading all the assemblies at a time, it loads those in a BackgroundThread. Thus improving the loading time a bit faster.
As you can see, I don’t have a class named “Person” in my project and hence it is marking it as UNKNOWN by highlighting it in Red. If you look into the first snapshot in depth you can find out that though the class is not present in my namespace or even in the project, it is creating the class reference in the intellisense. Great, right? Wait a minute. If you now place you cursor on top of “Person” and press F10 while holding down ALT+Shift, you will see a dropdown comes up in the screen with two menu item asking you to either generate the class for you or generate a new type.
Box Selection:
Here in the example, the public keywords of the properties has been marked using the Box Selector and when typing, it is actually changing in all the lines. Have a look into the second snap where I am typing “internal” to replace “public” and that’s populating in all the lines where I marked.
Easy Navigation:
IntelliTrace:
Microsoft has released two hot fixes till now for Visual Studio 2010 RC crash related to intellisense. The people who are currently using Visual Studio 2010 RC in a machine having UI Automation 3.0 APIs, touch screen, screen reader etc. have to download & install the following two HotFixes:
If you need any more information on the fixes then get it here at MSDN Blog.
In this post I will talk for one of the new feature in C# 4.0 – Named and Optional Parameter. Actually these are not a single feature but two different feature. You can get more benefit if you work with them together. So, what are those? Named parameter is a way to provide an parameter to the method using the name of the corresponding parameter instead of its position in the parameter list. Whereas, optional parameter allows you to omit arguments to member invocation.
- Sophisticated Authentication & Security (includes client certificates as credentials for web service call) - [Vote] – alexander.biskop
- More encryption algorithm - [Vote] – alexander.biskop
- More flexible way to do localization in DataForm/DataGrid - [Vote] – sladapter
- Application patching functionality - [Vote] – Haathen
- Better Local Messaging API - [Vote] – ksleung
- Better drawing API - [Vote] – ksleung
- Support for Report Viewer - [Vote] - mlonny
- Real time printing support - [Vote] – ksleung
- Support for iPod/iPhone - [Vote] - microsoft_kc
- Android support - [Vote] – ksleung
- Better 3D support like WPF - [Vote] - microsoft_kc
- An embedded database component like SQL-CE that can be used in OOB mode - [Vote] – Joeyw
- Better support for WritableBitmap - [Vote] – Joeyw
- Vector Printing - [Vote] – Joeyw
- Support for IObservable for databinding - [Vote] – Joeyw
- Rich Text Editor which allows Word Wrapping around images or other elements - [Vote] - Erwin Beckers
- BMP and GIF image support - [Vote] - Erwin Beckers
- More advanced controls like Outlook Agenda/Calendar control - [Vote] - Erwin Beckers
- Transparency Support in Out-Of-Browser Mode - [Vote] - microsoft_kc
- Improved SaveFileDialog with DefaultName option - [Vote] - Neha
- ChildWindow with NON-modal support - [Vote] - Amantha
- Flash video playback - [Vote] - Erwin Beckers
- A working webbrowser control in a non-out-of-browser scenario - [Vote] - Peter Gfader
- Support tooltip better for transparent, init delay, show delay, tiling image brush - [Vote] - Anonymous
Also, you can post them & vote in Silverlight Uservoice.
I think this is now-a-days a common issue for all the developers who are currently exploring both Visual Studio 2010 RC and Silverlight 4 Beta. Microsoft has removed the bits of Silverlight in the RC version of Visual Studio 2010. To work with that lots of people are now asking the same question.
Today I found a link which is written in a different version. I thought to share this thru my blog which may help the fellow developers (who are keeping a eye to my blog posts) to explore both simultaneously. Here is the original link of the post: http://sorokoletov.com/2010/02/hate-2-wait-silverlight-4-beta-2-vs-2010-rc/
Use the below link to translate it in English: http://tinyurl.com/SL4inVS2010RC-en
If you follow the steps provided in that blog post, you can install the Silverlight 4 Beta in your Visual Studio 2010 RC environment & start working on it till Microsoft releases the RC version of Silverlight. Go ahead and enjoy.
Remember: WCF RIA Services doesn’t work with this hack. I strongly recommend you to work with Visual Studio 2010 Beta 2 & Silverlight 4 Beta.