I am trying to assign registry value to 1 or 0. Electron packager and electron behaves differently. I set the value of registry to 0 and 1 on click of anchor tags. I am able to achieve this before the application has packaged but after application has packaged, I get error:vbscript process reported unknown error code 1 and registry doesn't set to 1 or 0.
Please note: I am using regedit with regedit.putvalue here to update the values
This question below has info about what I tried. link to the question
What I tried
dropDownBtn=`
<button id="dropDown" class="dropdown" data-toggle="off">Set/Unset Registry</button>
<div id="dropDowncontent" class="content" data-state="closed">
<ul>
<p> <b>Set or Unset Registry</b></p>
<li><a href="#" onclick="setRegistryValue()">Set</a></li>
<li><a href="#" onclick="unsetRegistryValue()" >Unset</a></li>
</ul>
</div>
update on this question I use npm builder "electron-packager --out winx64 --no-prune --asar" with asar enabled this doesn't work.
The registry doesn't have access from asar package, I guess