It is currently April 27th, 2024, 1:52 am

[solved] Having Trouble With Variables Being Used To Write To Another Variable

Get help with creating, editing & fixing problems with skins
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

death.crafter wrote: December 18th, 2021, 5:07 am How does it do it's things again? Cause right clicks take me to the directory in file explorer. And left clicks follow path. :confused:
OK say you start from a new skin.
The idea - so far as it seems to be functioning:
1) right click the path at the top to set a path to the variable (has to refresh to work so back to This PC)
2) Right click a number at the top (has to refresh to work so back to This PC)
3) Left click a set number to go to the path folder.

That's how it works, since I couldn't get a more immediate setting happening e.g. with out the refreshes.

So I suppose if this is a good as it gets without something external, then the next step is to be able to set all the paths to This PC as a refresh. This is where the backslash issue comes in.

I haven't found a way yet - but tbh I'm fairly absorbed by my job given the lockdowns are back in the big cities in AUS this week.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

CodeCode wrote: December 18th, 2021, 8:47 am OK say you start from a new skin.
The idea - so far as it seems to be functioning:
1) right click the path at the top to set a path to the variable (has to refresh to work so back to This PC)
2) Right click a number at the top (has to refresh to work so back to This PC)
3) Left click a set number to go to the path folder.

That's how it works, since I couldn't get a more immediate setting happening e.g. with out the refreshes.

So I suppose if this is a good as it gets without something external, then the next step is to be able to set all the paths to This PC as a refresh. This is where the backslash issue comes in.

I haven't found a way yet - but tbh I'm fairly absorbed by my job given the lockdowns are back in the big cities in AUS this week.
I think I said thing wrong.
I meant that the working version is mostly going good.
And I am trying to get a [Reset] working not a 'refresh'.
The reset would be setting the variables to This PC so the default path after left clicking would be This PC.
Anyway... I will try some more but at last effort, this line somehow is getting a backslash added after the default variable value of 'THIS PC':
RightMouseUpAction=[!SetVariable FaveOne "THIS PC"][!WriteKeyValue Variables FaveOne "THIS PC" "#@#TitanVars.inc"]
I was hoping there would be a regexp setting or a substitute setting to remove the weird backslash from the returned variable in the skin.
That path is somehow looking like this THIS PC\ and so the path is somehow wrong and I think windows is adding a backslash that normally would not be there. Or if that is not so then the backslash still is messing up the path to the top level of showing all of the hard drives. Hmm... :confused:
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

CodeCode wrote: December 19th, 2021, 11:19 am I think I said thing wrong.
I meant that the working version is mostly going good.
And I am trying to get a [Reset] working not a 'refresh'.
The reset would be setting the variables to This PC so the default path after left clicking would be This PC.
Anyway... I will try some more but at last effort, this line somehow is getting a backslash added after the default variable value of 'THIS PC':
RightMouseUpAction=[!SetVariable FaveOne "THIS PC"][!WriteKeyValue Variables FaveOne "THIS PC" "#@#TitanVars.inc"]
I was hoping there would be a regexp setting or a substitute setting to remove the weird backslash from the returned variable in the skin.
That path is somehow looking like this THIS PC\ and so the path is somehow wrong and I think windows is adding a backslash that normally would not be there. Or if that is not so then the backslash still is messing up the path to the top level of showing all of the hard drives. Hmm... :confused:
ok, ok, ok, ok...

Never mind. Lol. I am messing up my posts more than I am messing up my code. :lol:

This is sounding more confusing than it really is.

I have something I can try that I think will work.

So, ya. Never mind my inane ramblings in my last two posts.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
death.crafter
Rainmeter Sage
Posts: 1399
Joined: April 24th, 2021, 8:13 pm

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by death.crafter »

CodeCode wrote: December 19th, 2021, 11:26 am ok, ok, ok, ok...

Never mind. Lol. I am messing up my posts more than I am messing up my code. :lol:

This is sounding more confusing than it really is.

I have something I can try that I think will work.

So, ya. Never mind my inane ramblings in my last two posts.
To be honest, I can't really see the objective here. You want to favourite THIS PC? But you could hard code that if you want
THIS PC
specifically. And THIS PC isn't a location, so I wonder what you want to achieve here.
from the Realm of Death
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

death.crafter wrote: December 19th, 2021, 1:22 pm To be honest, I can't really see the objective here. You want to favourite THIS PC? But you could hard code that if you want
THIS PC
specifically. And THIS PC isn't a location, so I wonder what you want to achieve here.
Ok. It is weird and confusing what I am doing. But really quite basic.

a) I wish to set some favorite paths.
b) So setting a variable is the way to go
c) Setting the variable and have it work requires a !Refresh so the button controlling the variable is actually going to that [new] path.
d) Right clicking the path at the top captures the intended path in the variable (then !Refreshes)
e) Right clicking the button of choice sets that button to the captured path in c)
f) Now a left click of that button will go to the favorite (even after a refresh since !WriteKeyValue is being used
g) I wanted a reset so all of the variables got to This PC
h) It wasn't working until now...

1) I needed to have a [reset] feature so saved paths were defaulting [now] to the This PC level
1a) Setting the variables to empty string "" OR to "This PC" some how was getting a backslash added and breaks to path ability of going to that top most level.

i) I did this to fix it:

Code: Select all

IfMatch2=THIS PC\\$
IfMatchAction2=[!SetOption mPath "Path" ""]
ii) So now I need to get all of the buttons working with the simplest click actions - that's another story - so this thread is solved. :thumbup:
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

death.crafter wrote: December 19th, 2021, 1:22 pm To be honest, I can't really see the objective here. You want to favourite THIS PC? But you could hard code that if you want
THIS PC
specifically. And THIS PC isn't a location, so I wonder what you want to achieve here.
I just realized, you were probably wondering why I am not utilizing the lua script file you made.
I didn't understand how to use it in my skin :confused:
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: [solved] Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

Ok. Necroposting again.

I 'think' I got things working to my intended goal.

It's less confusing with where left and right clicks are being expected, so that the favorites require less click actions over all.

Anyway...

Thanks for any and all help up to now. It is really, really, appreciated. :great:

I am going to wait a few days before posting this Titan Deluxe Version, since I might get another idea, having reached this point after getting this idea working - endorphins and all that.

Also = Merry Holidays!!
:17flag :17spot1 :17spot2
:party:
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
death.crafter
Rainmeter Sage
Posts: 1399
Joined: April 24th, 2021, 8:13 pm

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by death.crafter »

CodeCode wrote: December 19th, 2021, 11:09 pm I just realized, you were probably wondering why I am not utilizing the lua script file you made.
I didn't understand how to use it in my skin :confused:
Nah, I am wondering what you're trying to achieve. I mean what would you do with the favourites and stuff. The best guess would be show a favourites menu.

But the making favourite process is confusing. I mean you could have a favorite button next to each entry in the list.

And about the lua script, that was just an example. You can't usually integrate a script that's not made by you, unless it's a module or something. I just showed how to do it.
from the Realm of Death
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

death.crafter wrote: December 20th, 2021, 8:29 am Nah, I am wondering what you're trying to achieve. I mean what would you do with the favourites and stuff. The best guess would be show a favourites menu.
I didnt want
death.crafter wrote: December 20th, 2021, 8:29 am ... I mean you could have a favorite button next to each entry in the list.
I kind of went for what makes sense to me. So I made Favourite buttons that would allow the user the navigate to any folder, until a manual reset was triggered.
The next idea that I feel pretty good about, was to make the buttons appear as needed, and disappear once a reset was triggered.
death.crafter wrote: December 20th, 2021, 8:29 am And about the lua script, that was just an example. You can't usually integrate a script that's not made by you, unless it's a module or something. I just showed how to do it.
I forget you are a kindred mythological paradigm with me. I would do the same thing - get an approximate file of code that was just enough to spark thinking. But in my case before now was laziness for not trying to get through it for the sake of examples to use in my own way.

I also have five favourite options now. The variables cycle from button 1 through button 5, replacing previous path/s with the new FaveVar value.
1, 2, 3, 4, 5 repeating with mouse-click actions, endlessly, or until a manual reset is made.
It even has the feature to set any button to the path variable, and in kind until the reset button is pressed.

I m OCD-ing other minimal features; like, alt tint colors, streamlining the code to get the same job done, reducing the amount of mouse-clicks, etc.

I am also going to try and add a path-to-file option, and the path would finish when the file of choice was loaded or executed. the things that make up go 'hmm'.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
User avatar
CodeCode
Posts: 1366
Joined: September 7th, 2020, 2:24 pm
Location: QLD, Australia

Re: Having Trouble With Variables Being Used To Write To Another Variable

Post by CodeCode »

death.crafter wrote: December 20th, 2021, 8:29 am Nah, I am wondering what you're trying to achieve. I mean what would you do with the favourites and stuff. The best guess would be show a favourites menu.
I didnt want a context menu, as it would be clutter in this skin.
death.crafter wrote: December 20th, 2021, 8:29 am ... I mean you could have a favorite button next to each entry in the list.
I kind of went for what makes sense to me. So I made Favourite buttons that would allow the user the navigate to any folder, until a manual reset was triggered.
The next idea that I feel pretty good about, was to make the buttons appear as needed, and disappear when right-clicked, or once a reset was triggered.
death.crafter wrote: December 20th, 2021, 8:29 am And about the lua script, that was just an example. You can't usually integrate a script that's not made by you, unless it's a module or something. I just showed how to do it.
I forget you are a kindred mythological paradigm with me. I would do the same thing - get an approximate file of code that was just enough to spark thinking. But in my case before now was laziness for not trying to get through it for the sake of examples to use in my own way.

I also have five favourite options now. The variables cycle from button 1 through button 5, replacing previous path/s with the new FaveVar value.
1, 2, 3, 4, 5 repeating with mouse-click actions, endlessly, or until a manual reset is made.
It even has the feature to set any button to the path variable, and in kind until the reset button is pressed.

I m OCD-ing other minimal features; like, alt tint colors, streamlining the code to get the same job done, reducing the amount of mouse-clicks, etc.

I am also going to try and add a path-to-file option, and the path would finish when the file of choice was loaded or executed. the things that make up go 'hmm'.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.