Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 08:52

    dependabot-preview[bot] on nuget

    (compare)

  • 08:52

    dependabot-preview[bot] on develop

    Bump ApprovalTests from 5.4.5 t… Merge pull request #1772 from C… (compare)

  • 08:52
    dependabot-preview[bot] closed #1772
  • 08:51
    dependabot-preview[bot] labeled #1772
  • 08:51
    dependabot-preview[bot] opened #1772
  • 08:51

    dependabot-preview[bot] on nuget

    Bump ApprovalTests from 5.4.5 t… (compare)

  • Feb 24 21:40

    delete-merged-branch[bot] on 20210224-213936

    (compare)

  • Feb 24 21:39

    GeertvanHorrik on develop

    GitHubSync update Merge pull request #1771 from C… (compare)

  • Feb 24 21:39
    GeertvanHorrik closed #1771
  • Feb 24 21:39
    GeertvanHorrik opened #1771
  • Feb 24 21:39

    GeertvanHorrik on 20210224-213936

    GitHubSync update (compare)

  • Feb 24 10:16

    delete-merged-branch[bot] on nuget

    (compare)

  • Feb 24 10:16

    GeertvanHorrik on develop

    Bump Moq from 4.16.0 to 4.16.1 … Merge pull request #1769 from C… (compare)

  • Feb 24 10:16
    GeertvanHorrik closed #1769
  • Feb 24 08:15
    dependabot-preview[bot] synchronize #1769
  • Feb 24 08:15

    dependabot-preview[bot] on nuget

    Bump Moq from 4.16.0 to 4.16.1 … (compare)

  • Feb 24 08:15
    dependabot-preview[bot] edited #1769
  • Feb 24 08:14
    dependabot-preview[bot] edited #1769
  • Feb 24 08:13

    dependabot-preview[bot] on nuget

    (compare)

  • Feb 24 08:13

    dependabot-preview[bot] on develop

    Bump Microsoft.NET.Test.Sdk fro… Merge pull request #1770 from C… (compare)

Geert van Horrik
@GeertvanHorrik
I would use a hierarchical model (thus not a view model per tree view item, but just 1 for the treeview). You could try to use x:Name and bind to TreeListView.DataContext (which is the VM) or using RelativeSource binding
culer
@culer
Thanks for the hint. I'm not sure if I completely understand what you're saying. Is your comment about binding to "TreeListView.DataContext" refering to EventToCommand Trigger or to the Property Setter I was describing? Could you maybe send a short code snippet of what exactly you mean?
Geert van Horrik
@GeertvanHorrik
No, I can't provide an example. I'm sorry, but I'm too busy to create free examples, done that too many times in the past. maybe ask the question on stack overflow?
culer
@culer
I'm not talking about an example, I just didn't understand what you meant by "try to use x:Name and bind to TreeListView.DataContext" and thought you could tell me in which context I need to read your answer to understand correctly. Can of course also try on StackOverflow - however most of the Catel questions that have real "solution" there where also answered by you ;)
tm1k
@tm1k
I just tried to implement a wizard according to the manual in https://opensource.wildgums.com/orc.wizard/ but there is a problem I can't resolve. I get the "System.MissingMethodException" which is missing "Void catel.Data.ModelBase.SetValue(Catel.Data.PropertyData, !!0, Boolean)". When I try to "LoadAssempliesOnStartup" within FodyWeavers, I get the error that it fails to execute weaver "LoadAssembliedOnStartup.Fody.dll"
Is there something I can do to solve this?
Geert van Horrik
@GeertvanHorrik
did you manually use a different (lower) version of Catel than orc.wizard uses?
note that it's best to let nuget fight out all dependencies, and we totally recommend you to use the latest alpha of Orc.Wizard since that will be released very soon
tm1k
@tm1k
Oh yes, this was the problem. I updated all packages according to the dependencies and it seems to work. The wizard window is damn small, in the output the error is that a ThemeManager is not initialized. I did not find any information about a theme manager, the only thing I found is the this.ApplyTheme() in Orc.Wizard.Example
Geert van Horrik
@GeertvanHorrik
You can call Orc.Thening.ThemeManager apply theme or something like that
And you can control the size of the wizard from within the wizard model
tm1k
@tm1k
Hm, the size is already set in the wizard model. Seems the theming error prevents it from be shown correctly?
tm1k
@tm1k
Somehow I can't either find a method for the initialization of ThemeManager nor anything in the Orc.Wizard.Example that I have not implemented. The error is still "Theming is not yet initialized, make sure to initialize a theme via ThemeManager first"
or use the AccentColor / BaseColorScheme methods and it should auto-apply it for you
tm1k
@tm1k
Boom! It works. Thanks a lot!
tm1k
@tm1k
Is it possible to access variable inside a wizard page that has been set by the user in a previous wizard page?
Geert van Horrik
@GeertvanHorrik
yes
a wizard page has a Wizard property, and that contains all the wizard pages available inside the wizard (including the state).
tm1k
@tm1k
I have a page selected with Linq from wizardPage.Wizard.Pages , but the ViewModel is null, so I cant access any variable. Am I missing something?
Geert van Horrik
@GeertvanHorrik
whenever a view model gets saved (SaveAsync), it's recommended to write data back to the Page model (view models are short-living objects).
In the example wizard, you can see how the summary page uses all other pages to determine the summary at the end
tm1k
@tm1k
I have not seen any constructor parameter injection within orc.wizard and my attempt of using typeFactory.CreateInstanceWithParameters is not working. Is this possible in general?
Geert van Horrik
@GeertvanHorrik
CerateInstanceWithPArametersAndAutoCompletion
tm1k
@tm1k
Also tried this, _typeFactory.CreateInstanceWithParametersAndAutoCompletion<Wizard.MyWizard>(Parameter); also gives me a System.NullReferenceException.
Geert van Horrik
@GeertvanHorrik
enable Catel logging, it will tell you why it fails
LogManager.AddDEbugListener(true) or something like that
tm1k
@tm1k
I have it activated, the return value of _typeFactory.CreateInstance... is null which I give the wizardService.ShowWizardAsync
Geert van Horrik
@GeertvanHorrik
yes, but the typefactory tells you why it cannot instantiate
tm1k
@tm1k
Got it! It was the order of the parameters in MyWizard
It is now MyWizard(Parameter, ITypeFactory typerFactory) : base(typeFactory) - what a bad mistake
Geert van Horrik
@GeertvanHorrik
mistakes happen, that's why we are glad we have logging :)
ssc19940105
@ssc19940105
var configurationService = new ConfigurationService();
Constructor without corresponding parameters
This is example in doc,but it is incorrect
Geert van Horrik
@GeertvanHorrik
Good catch! It probably requires dependencies now. A good usage now would be dependency injection (preferred0 or resolving it using ServiceLocator.Default.ResolveType<IConfigurationService>();
if you want, you can contribute to the docs with a fix :)
ssc19940105
@ssc19940105
configuration.SetValue(ConfigurationContainer.Local, "config", Config);

<?xml version="1.0" encoding="utf-8"?>

<DynamicConfiguration xmlns:ctl="http://schemas.catelproject.com" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<config ctl:type="System.String">YtbDownloader.Models.Config (ID = 1)</config>
</DynamicConfiguration>

ConfigurationService GetValue custom type does not get the expected result
Geert van Horrik
@GeertvanHorrik
is the object serializable? I think it's trying to serialize the ToString method for some reason
ssc19940105
@ssc19940105
Yes
Geert van Horrik
@GeertvanHorrik
Here is the logic that determines whether it should be serialized as string
tm1k
@tm1k
Is it a bug in the NumericTextBox that the entered value must be larger than the MinValue instantly or am I using it wrong? When the MinValue is set to e.g. 12 I can't enter a number at all, except I position the cursor in front of the zero and type '2' to get 20.
Geert van Horrik
@GeertvanHorrik
Hmmm, good question, that appears to be a bug
Adam Araminowicz
@aaraminowicz_gitlab
Any ideas why after updating Catel to version 5.12.7 I get error: "Cannot add instance of type 'EventToCommand' to a collection of type 'TriggerActionCollection'. Only items of type 'T' are allowed.", while I try to use EventToCommand? Before update it worked flawlessly. It must be something with dependencies versions, but I have no clue what has changed.
Geert van Horrik
@GeertvanHorrik
Yes. Probably because you are using an old (outdated) version of Interactions. Please migrate xamlbehaviors instead
tm1k
@tm1k
Since I updated my package versions, I can't bind a collection to a ListBox anymore. I get the error that the "collection must be empty before using ItemsSource". This has never been a problem before. It seems that I can't CreateInstanceWithParametersAndAutoCompletion and pass one of the parameters to a binding Object anymore. When the _uiVisualizerService.ShowDialogAsync is called, the error is thrown when using a ListBox
tm1k
@tm1k
Using the same binding with the ItemsSource of a ComboBox works fine
Adam Araminowicz
@aaraminowicz_gitlab
@GeertvanHorrik Thanks, however I had newest version of Microsoft.Xaml.Behaviors.Wpf (1.1.19, as required by Catel.MVVM 5.12.7). I downgraded Behaviors lib to version 1.1.3, which downgraded Catel.MVVM to version 5.12.5, and now everything works.