Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Extended WPF Toolkit - How to add reference to project?

Tags:

I am new to WPF. I want to use datetime picker. I have downloaded the "Extended WPF Toolkit - 1.9.0" from below site.

http://wpftoolkit.codeplex.com/releases/view/96972

I have unzip file and found two dll. One is "WPFToolkit.dll" and "Xceed.Wpf.Toolkit.dll".

Now How to add these two dll in my project? and How to use datetime control in my project.

like image 684
Mahesh Alle Avatar asked Feb 11 '13 09:02

Mahesh Alle


People also ask

How do I add Extended WPF Toolkit to Toolbox?

Go to the toolbox tab (ctrl+alt+x), right click on it and "Add Tab", type the name you want for it (ex: "WPF Extended Toolkit"). And.. that's it. Glad to hear that, enjoy the extended toolkit.

What is Extended WPF Toolkit?

Extended WPF Toolkit is the number one collection of WPF controls, components and utilities for creating next generation Windows applications. Provides 48 controls, all offered under the Xceed Software Inc Community License. v4. 4.0 provides 17 bug fixes and improvements, including the . NET5/6 dlls.

What is control in WPF?

WPF SDK continues to use the term "control" to loosely mean any class that represents a visible object in an application, it is important to note that a class does not need to inherit from the Control class to have a visible presence.


2 Answers

First, reference those dlls in your project.
Right click on References in the Solution Explorer and click Add Reference, now browse and add the two dlls.

Second, build the project once to enable intellisense in XAML for the newly added dlls.

Third, in your XAML file add the following namespace

    xmlns:wpfTool="clr-namespace:Xceed.Wpf.Toolkit;assembly=Xceed.Wpf.Toolkit" 

Tip: Type xmlns:customName="wpftool" and you should be able to see the intellisense list all the relevant namespaces.

Heres the XAML code:

<Window x:Class="WpfApplication1.MainWindow"         xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"         xmlns:wpfTool="clr-namespace:Xceed.Wpf.Toolkit;assembly=Xceed.Wpf.Toolkit"         Title="MainWindow" Height="350" Width="525">     <Grid>         <Grid.RowDefinitions>             <RowDefinition Height="*"/>             <RowDefinition Height="*"/>         </Grid.RowDefinitions>         <Grid.ColumnDefinitions>             <ColumnDefinition Width="*"/>             <ColumnDefinition Width="*"/>         </Grid.ColumnDefinitions>         <wpfTool:DateTimePicker Grid.Row="0">          </wpfTool:DateTimePicker>     </Grid> </Window> 
like image 162
Anand Murali Avatar answered Oct 06 '22 02:10

Anand Murali


Graphical Way to add the controls in VS 2013

  1. First, reference those dlls in your project.
  2. Right click on References in the Solution Explorer and click Add Reference, now browse and add the two dlls.
  3. Right Click to toolbox > General Area and Choose "Add Tab" - Give the name to the Tab say "WPF Toolkit Controls"!
  4. Now Clcik on Choose Items..It opens choose toolbox Items dialog box...!
  5. In WPF Component tab - Now Click on Browse button and locate the downloaded dll and click on open
  6. WPF Component Tab will show all the control
  7. By Clicking on OK "WPF Toolkit Controls" will populate all the controls of the WPF Toolkit
  8. Now Drag and Drop the Required Control - It will automatically add the namespace reference required.
like image 23
Sawarkar vikas Avatar answered Oct 06 '22 01:10

Sawarkar vikas