Home Forums WPF controls Xceed DataGrid for WPF Using DataGrid in WPF Control in WinForm in DLL

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #26066 |

    I am trying to create a DLL that wraps a WinForm around a WPF Control using ElementHost and then compile that to a DLL. it compiles fine, but when I try and load the DLL and show the WinForm inside I get the following Exception.

    I would appreciate any help, thanks 😀

    System.Windows.Markup.XamlParseException occurred
    Message=”‘/Xceed.Wpf.Controls;component\\themes/generic.xaml’ value cannot be assigned to property ‘XceedSource’ of object ‘Xceed.Utils.Wpf.Markup.XceedResourceDictionary’. Could not load file or assembly ‘Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6’ or one of its dependencies. The system cannot find the file specified. Error at object ‘Xceed.Utils.Wpf.Markup.XceedResourceDictionary’ in markup file ‘Xceed.Wpf.DataGrid;;;component/themes/Luna/TableView.Luna.normalcolor.xaml’.”
    Source=”PresentationFramework”
    LineNumber=0
    LinePosition=0
    NameContext=”MergedDictionaries”
    StackTrace:
    at System.Windows.Markup.XamlParseException.ThrowException(String message, Exception innerException, Int32 lineNumber, Int32 linePosition, Uri baseUri, XamlObjectIds currentXamlObjectIds, XamlObjectIds contextXamlObjectIds, Type objectType)
    at System.Windows.Markup.XamlParseException.ThrowException(ParserContext parserContext, Int32 lineNumber, Int32 linePosition, String message, Exception innerException)
    at System.Windows.Markup.BamlRecordReader.ThrowException(String message, Exception innerException)
    at System.Windows.Markup.BamlRecordReader.ReadPropertyRecordBase(String attribValue, Int16 attributeId, Int16 converterTypeId)
    at System.Windows.Markup.BamlRecordReader.ReadPropertyConverterRecord(BamlPropertyWithConverterRecord bamlPropertyRecord)
    at System.Windows.Markup.StyleBamlRecordReader.ReadPropertyConverterRecord(BamlPropertyWithConverterRecord bamlPropertyRecord)
    at System.Windows.Markup.BamlRecordReader.ReadRecord(BamlRecord bamlRecord)
    InnerException: System.IO.FileNotFoundException
    Message=”Could not load file or assembly ‘Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6’ or one of its dependencies. The system cannot find the file specified.”
    Source=”mscorlib”
    FileName=”Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6″
    FusionLog=”=== Pre-bind state information ===\r\nLOG: User = BKMGTSRV\\Wally.Nelson\r\nLOG: DisplayName = Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6\n (Fully-specified)\r\nLOG: Appbase = file:///C:/Program Files/Microsoft Visual FoxPro 9/\r\nLOG: Initial PrivatePath = NULL\r\nCalling assembly : PresentationCore, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35.\r\n===\r\nLOG: This bind starts in default load context.\r\nLOG: No application configuration file found.\r\nLOG: Using machine configuration file from C:\\WINDOWS\\Microsoft.NET\\Framework\\v2.0.50727\\config\\machine.config.\r\nLOG: Post-policy reference: Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6\r\nLOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual FoxPro 9/Xceed.Wpf.Controls.DLL.\r\nLOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual FoxPro 9/Xceed.Wpf.Controls/Xceed.Wpf.Controls.DLL.\r\nLOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual FoxPro 9/Xceed.Wpf.Controls.EXE.\r\nLOG: Attempting download of new URL file:///C:/Program Files/Microsoft Visual FoxPro 9/Xceed.Wpf.Controls/Xceed.Wpf.Controls.EXE.\r\n”
    StackTrace:
    at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
    at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
    at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
    at System.Reflection.Assembly.Load(AssemblyName assemblyRef)
    at System.Windows.Navigation.BaseUriHelper.GetLoadedAssembly(String assemblyName, String assemblyVersion, String assemblyKey)
    at MS.Internal.AppModel.ResourceContainer.GetResourceManagerWrapper(Uri uri, String& partName, Boolean& isContentFile)
    at MS.Internal.AppModel.ResourceContainer.GetPartCore(Uri uri)
    at System.IO.Packaging.Package.GetPartHelper(Uri partUri)
    at System.IO.Packaging.Package.GetPart(Uri partUri)
    at System.IO.Packaging.PackWebResponse.CachedResponse.GetResponseStream()
    at System.IO.Packaging.PackWebResponse.GetResponseStream()
    at System.IO.Packaging.PackWebResponse.get_ContentType()
    at MS.Internal.WpfWebRequestHelper.GetContentType(WebResponse response)
    at MS.Internal.WpfWebRequestHelper.GetResponseStream(WebRequest request, ContentType& contentType)
    at System.Windows.ResourceDictionary.set_Source(Uri value)
    at Xceed.Utils.Wpf.Markup.XceedResourceDictionary.set_XceedSource(String value)
    InnerException:

    Imported from legacy forums. Posted by Wally (had 3965 views)

    Xceed Support
    Member
    Post count: 5658

    The error message mentions:

    Could not load file or assembly ‘Xceed.Wpf.Controls, Version=1.3.7570.10530, Culture=neutral, PublicKeyToken=ba83ff368b7563c6’ or one of its dependencies. The system cannot find the file specified.

    Is the Xceed.Wpf.Controls assembly version 1.3.7570.10530 available to the application?

    Imported from legacy forums. Posted by Marcus [Xceed] (had 824 views)

    User (Old forums)
    Member
    Post count: 23064

    Thanks for the reply Marcus.

    I found the problem. The Xceed dlls didn’t exist in the debug working directory. As soon as I copied the dlls to that directory it worked fine.

    Thanks again for the quick response.

    Imported from legacy forums. Posted by Wally (had 4093 views)

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.