I'm trying to use Application.GetApplicationPreferenceValue, but it's not working for me when the GroupName contains a space.
Sub test_get_app_preference_01() Debug.Print Application.GetApplicationPreferenceValue("Directories", "AutoBackup") End Sub Sub test_get_app_preference_02() Debug.Print Application.GetApplicationPreferenceValue("File Locations", "DefaultFillPath") End Sub Sub test_get_app_preference_03() Debug.Print Application.GetApplicationPreferenceValue("NodeEditTool", "TransientSkiaGpuAccelerated") End Sub Sub test_get_app_preference_04() Debug.Print Application.GetApplicationPreferenceValue("ShapingTool", "EffectRate") End Sub Sub test_get_app_preference_05() Debug.Print Application.GetApplicationPreferenceValue("FilletScallopChamfer", "FilletRadius") End Sub
So, in the above subs, the ones with GroupNames that do not contain spaces all work as expected.
The one with the GroupName "File Locations" gets me this:
Is there some syntax of which I'm unaware for handling the GroupNames that have one or more spaces in them?
I am afraid that GroupName or KeyName does not exist...
Where from did you take these groups and keys strings? At first glance i suppose that "DefaultFillPath" should be "DefaultFilePath"...
For instance, in my case (X8 installation) i do not receive the same error only for the next to procedures:
Sub test_get_app_preference_04() Debug.Print Application.GetApplicationPreferenceValue("ShapingTool", "EffectRate") End Sub Sub test_get_app_preference_05() Debug.Print Application.GetApplicationPreferenceValue("FilletScallopChamfer", "FilletRadius") End Sub'I also found a 'sister' API: SetApplicationPreferenceValue. I couldn't figure out how to use it in order to set something...
Thank you for looking, and for trying this!
I was using 2018. It makes sense to me that the _03 sub would not work in X8, as it refers to GPU acceleration.
I don't understand, though, why the _01 sub does not work with X8. If I look at the settings.ini file, that group and key are present.
Again, both _01 and _03 work in 2018.
Yes, what I really wanted to do was to use SetApplicationPreferenceValue.
I, too, cannot figure out how to use that!