When we create drawing Paths in blend it gives us the Data in a special format with some letters which is not easily understandable at first look.
Here is a link which describes how the control letters M ,C, L etc are getting mapped.
http://msdn.microsoft.com/en-us/library/ms747393.aspx#paths
One more link to create paths simply using individual objects.
http://msdn.microsoft.com/en-us/library/ms745814.aspx
Wednesday, September 10, 2008
Wednesday, July 2, 2008
About pack uri style
As a WPF developer you might have seen the resource reference in the form
pack://application:,,,/somefile.xaml
and you might have used this style too.Actually what is this pack uri ?
This is a new method introduced in WPF to locate files in an assembly or in the current folder.Those files may be images,videos,audio and even another xaml file.
Parts
The first part identifies whether it points to an application or to the current folder where the file is located and the second part is the relative path to that file.
First part can be any one of the following
pack://application:,,,/somefile.xaml
and you might have used this style too.Actually what is this pack uri ?
This is a new method introduced in WPF to locate files in an assembly or in the current folder.Those files may be images,videos,audio and even another xaml file.
Parts
The first part identifies whether it points to an application or to the current folder where the file is located and the second part is the relative path to that file.
First part can be any one of the following
- application -> Tells that the file is located in the assembly as Content or Resource pack://application:,,,/ResourceFile.xaml
- siteoforigin -> Its in the current executing folder pack://siteoforigin:,,,/SiteOfOriginFile.xaml
Second part tells the assembly where the file is located.If the file locate in same assembly there is no need to mention it other wise use assembly name
Same assembly - pack://application:,,,/ResourceFile.xaml
Different assembly - pack://application:,,,/ReferencedAssembly;component/ResourceFile.xaml
Same assembly - pack://application:,,,/ResourceFile.xaml
Different assembly - pack://application:,,,/ReferencedAssembly;component/ResourceFile.xaml
pack://application:,,,/ReferencedAssembly;v1.0.0.1;component/ResourceFile.xaml
Fourth part is the path to file.
pack://application:,,,/Subfolder/ResourceFile.xaml
Advantage of pack uri style
- You may separate your styles from application and keep as dll.
- Design time support
Subscribe to:
Posts (Atom)
