{"action":"created","issue":{"url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/3013","repository_url":"https://api.github.com/repos/AvaloniaUI/Avalonia","labels_url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/3013/labels{/name}","comments_url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/3013/comments","events_url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/3013/events","html_url":"https://github.com/AvaloniaUI/Avalonia/issues/3013","id":495492541,"node_id":"MDU6SXNzdWU0OTU0OTI1NDE=","number":3013,"title":"Extending Panel caused \"Exception has been thrown by the target of an invocation.\" error","user":{"login":"edOasiot","id":54422142,"node_id":"MDQ6VXNlcjU0NDIyMTQy","avatar_url":"https://avatars1.githubusercontent.com/u/54422142?v=4","gravatar_id":"","url":"https://api.github.com/users/edOasiot","html_url":"https://github.com/edOasiot","followers_url":"https://api.github.com/users/edOasiot/followers","following_url":"https://api.github.com/users/edOasiot/following{/other_user}","gists_url":"https://api.github.com/users/edOasiot/gists{/gist_id}","starred_url":"https://api.github.com/users/edOasiot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edOasiot/subscriptions","organizations_url":"https://api.github.com/users/edOasiot/orgs","repos_url":"https://api.github.com/users/edOasiot/repos","events_url":"https://api.github.com/users/edOasiot/events{/privacy}","received_events_url":"https://api.github.com/users/edOasiot/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2019-09-18T22:57:23Z","updated_at":"2019-09-18T23:58:30Z","closed_at":null,"author_association":"NONE","body":"I was able to Extend TextBox and CheckBox, but not Panel:\r\n\r\n**OAS_Panel.xaml**\r\n```\r\n<Panel xmlns=\"https://github.com/avaloniaui\"\r\n             xmlns:x=\"http://schemas.microsoft.com/winfx/2006/xaml\"\r\n             xmlns:d=\"http://schemas.microsoft.com/expression/blend/2008\"\r\n             xmlns:mc=\"http://schemas.openxmlformats.org/markup-compatibility/2006\"\r\n             mc:Ignorable=\"d\" d:DesignWidth=\"800\" d:DesignHeight=\"450\"\r\n             x:Class=\"OASAvalonia.OAS_Panel\">\r\n</Panel>\r\n```\r\n**OAS_Panel.xaml.cs**\r\n\r\n```\r\nusing Avalonia;\r\nusing Avalonia.Controls;\r\nusing Avalonia.Markup.Xaml;\r\nusing Avalonia.Media;\r\nusing Avalonia.Styling;\r\nusing System;\r\n\r\nnamespace OASAvalonia\r\n{\r\n    public class OAS_Panel : Panel, IStyleable\r\n    {\r\n        public OAS_Panel()\r\n        {\r\n            this.InitializeComponent();\r\n        }\r\n\r\n        private void InitializeComponent()\r\n        {\r\n            AvaloniaXamlLoader.Load(this);\r\n        }\r\n\r\n        Type IStyleable.StyleKey => typeof(Panel);\r\n    }\r\n}\r\n```\r\n\r\n**MainWindow.xaml**\r\n\r\n```\r\n<Window xmlns=\"https://github.com/avaloniaui\"\r\n        xmlns:b=\"clr-namespace:OASAvalonia;assembly=OASAvalonia\"\r\n        xmlns:x=\"http://schemas.microsoft.com/winfx/2006/xaml\"\r\n        xmlns:d=\"http://schemas.microsoft.com/expression/blend/2008\"\r\n        xmlns:mc=\"http://schemas.openxmlformats.org/markup-compatibility/2006\"\r\n        mc:Ignorable=\"d\" d:DesignWidth=\"1200\" d:DesignHeight=\"500\"\r\n        x:Class=\"AvaloniaApplication1.MainWindow\"\r\n        Title=\"OAS / Avalonia Application\" Width=\"1200\" Height=\"500\">\r\n      <b:OAS_Panel Background=\"AliceBlue\"/>\r\n</Window>\r\n```"},"comment":{"url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/comments/532910729","html_url":"https://github.com/AvaloniaUI/Avalonia/issues/3013#issuecomment-532910729","issue_url":"https://api.github.com/repos/AvaloniaUI/Avalonia/issues/3013","id":532910729,"node_id":"MDEyOklzc3VlQ29tbWVudDUzMjkxMDcyOQ==","user":{"login":"danwalmsley","id":4672627,"node_id":"MDQ6VXNlcjQ2NzI2Mjc=","avatar_url":"https://avatars3.githubusercontent.com/u/4672627?v=4","gravatar_id":"","url":"https://api.github.com/users/danwalmsley","html_url":"https://github.com/danwalmsley","followers_url":"https://api.github.com/users/danwalmsley/followers","following_url":"https://api.github.com/users/danwalmsley/following{/other_user}","gists_url":"https://api.github.com/users/danwalmsley/gists{/gist_id}","starred_url":"https://api.github.com/users/danwalmsley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danwalmsley/subscriptions","organizations_url":"https://api.github.com/users/danwalmsley/orgs","repos_url":"https://api.github.com/users/danwalmsley/repos","events_url":"https://api.github.com/users/danwalmsley/events{/privacy}","received_events_url":"https://api.github.com/users/danwalmsley/received_events","type":"User","site_admin":false},"created_at":"2019-09-18T23:58:30Z","updated_at":"2019-09-18T23:58:30Z","author_association":"MEMBER","body":"My suspicion is that its not happy with _ in class name, can you remove and see if the problem goes away?\r\n\r\nAlso are you using nightly builds? if not try https://github.com/AvaloniaUI/Avalonia/wiki/Using-nightly-build-feed\r\n\r\nand see if it fixes it, or you get a more useful error message."}}
{"actor":{"display_login":"danwalmsley"}}