I am working on the WPF application and i have created an exe file.
When i run the exe file on my computer,it works perfectly.But when i try using my exe with another system.It throws an exception and when i debug the exception it says…
Cannot find type
‘Microsoft.Windows.Controls.DataGrid’.
The assembly used when compiling might
be different than that used when
loading and the type is missing.
Error at object ‘MyWork.App’ in
markup file ‘MyWork.App;component/app.xaml’ Line 15
Position 6.
Any idea ?
Regards,
Sangram Nandkhile.
It sounds like you haven’t installed the dll that contains
Microsoft.Windows.Controls.DataGrid. This is part of the WPF Toolkit so you will need to either install that on the target machine or include the dll in your installation program.If you don’t want to create an installer then you can merge assemblies using ILMerge which: