Skip to content

EmptyKeys.UserInterface not found when using GeneratedBindings #20

@SirDragonClaw

Description

@SirDragonClaw

I am trying to use generated bindings but there is no simple sample for it so I cannot figure out why this isn't working.

Using this :

<Grid ek:GeneratedBindings.Mode="Reflection" ek:GeneratedBindings.DataType="{x:Type data:ItemEndGameUI}">

I get this error :
1>------ Rebuild All started: Project: GameData, Configuration: Debug Any CPU ------ 1> GameData -> C:\Desktop\2.0 Projects\Games\Hazzah Engine\WPF UI\GameData\bin\Debug\GameData.dll 2>------ Rebuild All started: Project: ControlLayoutsWPF, Configuration: Debug Any CPU ------ 2> ControlLayoutsWPF -> C:\Desktop\2.0 Projects\Games\Block Games\ControlLayoutsWPF\bin\Debug\ControlLayoutsWPF.dll 2> Empty Keys (c) 2016 User Interface Generator Console v3.0.0.0 2> System.Windows.Markup.XamlParseException: 'Failed to create a 'Type' from the text 'data:ItemEndGameUI'.' Line number '1' and line position '591'. ---> System.Xaml.XamlParseException: Type reference cannot find type named '{clr-namespace:GameData;assembly=GameData}ItemEndGameUI'. 2> at MS.Internal.Xaml.Context.ObjectWriterContext.ServiceProvider_Resolve(String qName) 2> at MS.Internal.Xaml.ServiceProviderContext.System.Windows.Markup.IXamlTypeResolver.Resolve(String qName) 2> at System.Xaml.Replacements.TypeTypeConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value) 2> at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateObjectWithTypeConverter(ServiceProviderContext serviceContext, XamlValueConverter1 ts, Object value)
2> at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateFromValue(ServiceProviderContext serviceContext, XamlValueConverter1 ts, Object value, XamlMember property) 2> at System.Xaml.XamlObjectWriter.Logic_CreateFromValue(ObjectWriterContext ctx, XamlValueConverter1 typeConverter, Object value, XamlMember property, String targetName, IAddLineInfo lineInfo)
2> --- End of inner exception stack trace ---
2> at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri)
2> at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, Boolean skipJournaledProperties, Uri baseUri)
2> at System.Windows.Markup.XamlReader.Load(XamlReader xamlReader, ParserContext parserContext)
2> at System.Windows.Markup.XamlReader.Load(XmlReader reader, ParserContext parserContext, XamlParseMode parseMode)
2> at System.Windows.Markup.XamlReader.Load(Stream stream, ParserContext parserContext)
2> at EmptyKeys.UserInterface.Generator.UserInterfaceGenerator.GenerateCode(String inputFileName, String inputFileContent, RenderMode renderMode, String desiredNamespace, String header) in E:!Prog\TFS\LogicMarbles\UIGenerator\UIGenerator\UserInterfaceGenerator.cs:line 57
2> System.Windows.Markup.XamlParseException: 'Failed to create a 'Type' from the text 'data:ItemEndGameUI'.' Line number '1' and line position '591'. ---> System.Xaml.XamlParseException: Type reference cannot find type named '{clr-namespace:GameData;assembly=GameData}ItemEndGameUI'.
2> at MS.Internal.Xaml.Context.ObjectWriterContext.ServiceProvider_Resolve(String qName)
2> at MS.Internal.Xaml.ServiceProviderContext.System.Windows.Markup.IXamlTypeResolver.Resolve(String qName)
2> at System.Xaml.Replacements.TypeTypeConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value)
2> at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateObjectWithTypeConverter(ServiceProviderContext serviceContext, XamlValueConverter1 ts, Object value) 2> at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateFromValue(ServiceProviderContext serviceContext, XamlValueConverter1 ts, Object value, XamlMember property)
2> at System.Xaml.XamlObjectWriter.Logic_CreateFromValue(ObjectWriterContext ctx, XamlValueConverter1 typeConverter, Object value, XamlMember property, String targetName, IAddLineInfo lineInfo) 2> --- End of inner exception stack trace --- 2> at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri) 2> at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, Boolean skipJournaledProperties, Uri baseUri) 2> at System.Windows.Markup.XamlReader.Load(XamlReader xamlReader, ParserContext parserContext) 2> at System.Windows.Markup.XamlReader.Load(XmlReader reader, ParserContext parserContext, XamlParseMode parseMode) 2> at System.Windows.Markup.XamlReader.Load(Stream stream, ParserContext parserContext) 2> at EmptyKeys.UserInterface.Generator.UserInterfaceGenerator.GenerateCode(String inputFileName, String inputFileContent, RenderMode renderMode, String desiredNamespace, String header) in E:\!Prog\TFS\LogicMarbles\UIGenerator\UIGenerator\UserInterfaceGenerator.cs:line 63 2> at ekUiGen.Program.Generate(String xamlFile, String outputFile, RenderMode renderMode, String desiredNamespace, String defaultAssembly, String header) in E:\!Prog\TFS\LogicMarbles\UIGenerator\ekUiGen\Program.cs:line 217 2> at ekUiGen.Program.Main(String[] args) in E:\!Prog\TFS\LogicMarbles\UIGenerator\ekUiGen\Program.cs:line 152 2>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(5074,5): error MSB3073: The command "CD "C:\Desktop\2.0 Projects\Games\Block Games\packages\EmptyKeysUI_Generator*\tools" 2>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(5074,5): error MSB3073: ekUIGen.exe -i="C:\Desktop\2.0 Projects\Games\Block Games\ControlLayoutsWPF\\" -o="C:\Desktop\2.0 Projects\Games\Block Games\ControlLayoutsWPF\..\Craft World\Source\WPF UI" -oa="C:\Desktop\2.0 Projects\Games\Block Games\ControlLayoutsWPF\..\Craft World\Source Content\WPF Content" -rm=MonoGame /generate-bindings" exited with code -2. ========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions