How to set curent tool options via batchPlay

I am trying to change the settings of the current tool.
There are no problems with getting the current settings and changing the object, but I can’t figure out how to write similar code for batchPlay

var d1 = new ActionDescriptor(),
    r = new ActionReference();
r.putClass(s2t(currentToolName);
d1.putReference(s2t("target"), r);
d1.putObject(s2t("to"), s2t("currentToolOptions"), currentToolSettingsObj);
executeAction(s2t("set"), d1, DialogModes.NO);

Forum search is most of the time very useful :wink:
This should help:

1 Like

thx, I tried to find similar messages by searching, but the keywords that I used did not allow me to find this topic.