Page 1 of 1

Button Variables not expanded

Posted: 2023-12-02, 09:42 UTC
by t_arn
I'm trying to send selected files to my pyTextDiff app.
I created a custom with following definition:
* Function: start program
* command: (the selected app)
* parameters: url:data:application/json,["%P%N","%T%M"]

But in my app, I get the string data:application/json,["%P%N","%T%M"] and the variables are not replaced by the paths / filenames

Re: Button Variables not expanded

Posted: 2023-12-03, 10:31 UTC
by ghisler(Author)
First, use "view with app" instead of "start program". Action.MAIN usually doesn't have parameters.
Second, you need to select a file in each panel by clicking on their icons to have them as parameters.
Third, this call
setData(Uri.parse(parameter))
with parameter containing data:application/json,["/path1/file1","/path2/file2"]
is this really what you want?

Re: Button Variables not expanded

Posted: 2023-12-03, 16:14 UTC
by t_arn
is this really what you want?
Yes, that was the idea.
But maybe you are right and I'm better off with adding a VIEW intent to my app.