Answered
File.openDialog(); What is the result? What if I only have the path?
Whether it's an object or a path is indistinguishable.
I don't want the dialog to open, I want it to open the file pointed to by the path by default, what should I write?
var file = File.openDialog();
alert("file:" + file);
Below is the result after I choose to select "my.json":

If I don't want to do it manually, it it directly opens this path “pathToMyJSONFile” (pathToMyJSONFile = File($.fileName).parent.parent + ‘/PubLib/my.json’;)
How do I change it?
var file = File.open(pathToMyJSONFile);
This seems wrong.
alert(pathToMyJSONFile); results in this:


