These are chat archives for ButchersBoy/Dragablz

25th
Feb 2017
Alex Fanat
@TheFanatr
Feb 25 2017 06:30
Hello @ButchersBoy I am trying to get the new tab button to work in my app. I copied the exact BoundExampleNewItem file from the demo project, and have used it programmatically like so in my MainWindow XAML code: <dragablz:TabablzControl BorderThickness="0" Name="TabablzControl" ShowDefaultAddButton="True" NewItemFactory="{x:Static local:BoundExampleNewItem.Factory}">
local is the project namespace
and it says: The name "BoundExampleNewItem" does not exist in the namespace "clr-namespace:MaterialDesignUI".
I have tried to make it as a default property using the resource manager thing like it's done in the demo, but I get the same result.
The app just doesn't compile when I try to bind the newitemfactory
I have all the namespaces and everything set up, and everything else works perfectly.
Alex Fanat
@TheFanatr
Feb 25 2017 06:36
I've tried to make my own button appear in the TabablzControl, but as soon as someone clicks it, not only does the event handler not get called, but the button itself moves into the tab. Also, when I try to add a TabItem programmatically to the TabablzControl using items.add, it doesn't do anything.
Thanks in advance.
Alex Fanat
@TheFanatr
Feb 25 2017 07:00
Update: I got items.add to work but still can't get any event handlers to activate that are linked to items I've added.
James Willock
@ButchersBoy
Feb 25 2017 07:16
@TheFanatr you'll have to post a repo
Alex Fanat
@TheFanatr
Feb 25 2017 07:17
Ok I'll go do that
That is the stripped down version of the GUI I was working on, with all mentioned issues in it.
I tried to make it as simple as possible for the sake of anyone trying to help not having to comb through mountains of source.
Also, in case it matters, I'm using the latest .NET framework, WPF framework, and C#, on Visual Studio 2017 RC.
Though the Dragablz test solution works perfectly fine In the area that I was looking at
Alex Fanat
@TheFanatr
Feb 25 2017 19:49
@ButchersBoy So... did I do something wrong in the XAML
Alex Fanat
@TheFanatr
Feb 25 2017 23:00
Update: No matter what I try, I can't get the default add button to produce the expected behavior. I even went as far as copying a lot of the project files directly from the demo and adapting the namespace referencing the local project. Still, It couldn't find anything. I am really confused as to what is going on.
I thought maybe that it was missing some random configurations that I missed, but even the BoundExampleWindow from the demo was having the same errors.
Does anyone have working code that makes a new tab?
I think it may be that the versions of Dragablz included in the demo target older versions of everything I have installed, so it is screwing up when I give it newer ones, because otherwise I can't really explain what is going on, unless I missed something stupidly obvious and over-complicated everything.
Alex Fanat
@TheFanatr
Feb 25 2017 23:54
@ButchersBoy Is there any way to get a button into the TabablzControl, separate from the tabs, and make the click handler actually work. I'm trying to make my own add button and I came up with a solution but it's literally just a button in the top right corner of the program. I really want to have that new tab button from the demo, but again, everything I try to do gives me an error. I don't understand. Also, sorry if I am being annoying.