Programmatically access list of Themes

0
0

Greetings sorry to trouble you.
There was some feature available in VWG that allowed access to a string array of themes.
Gizmox.WebGUI.Common.Configuration.Config.Themes

I know WiseJ references my single theme in the themes folder
and any mixins I additionally add in that theme folder.
But there does not seem to be any functionality available to access this list I see
available in the UI programmatically,  so I can present this list to the user.
— And of course change dynamically.

 

Thank you

  • You must to post comments
0
0

Thank you I appreciate this,    but my themes folder only has my custom theme in it and some odd mixin .

It does not represent the content of this list that I see in the designers of the controls as shown in the previous image attachment,

that I am attempting to access and provide to user for dynamic selection

 

  • Frank (ITG)
    As Julie pointed out, there is no build it function to achieve this. You would have to supply your own list of the themes you want to offer for selection. It’s just a list of strings with the Theme Names. Regards, Frank
  • Christian Programmer
    Thanks Frank is it just a standard default list then and other themes manually added to the themes folder would then be included in addition to these default IMUTABLE options? MyCustom-1 MyCustom-2 Blue-1 Blue-2 Blue-3 Bootstrap-4 BootstrapDark-4 Classic-2 Clear-1 Clear-1 Clear-1 Material-3 Graphite-3 Vista-2
  • Frank (ITG)
    Managing the content of the list is entirely up to you. You can add all available themes or just a subset to let the user select from. Regards, Frank
  • Christian Programmer
    Thanks was just checking to see of something was accessible to iterate over .. but manually listing the defaults since they always available is fine. I just add my single custom one to that list for dynamic changes & saves to user preferences. Thanks again
  • You must to post comments
0
0

There isn’t a built-in method for Wisej for getting the themes from the themes folder specifically.

However, you can just check the Themes folder and get a list of the files in it.
Just use DIrectory.GetFiles()
https://learn.microsoft.com/en-us/dotnet/api/system.io.directory.getfiles?view=net-8.0
https://stackoverflow.com/questions/12524398/directory-getfiles-how-to-get-only-filename-not-full-path

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.