Forum Home › Forums › Understanding the Software › Auto Logon
- This topic has 13 replies, 3 voices, and was last updated 2 years, 2 months ago by Rich Ex.
-
AuthorPosts
-
January 6, 2022 at 11:43 am #9850Rich ExParticipant
Hi Friends ,
Is it possible to set up a user accoubt that has no Logon password , I am trying to set up a screen that automatically loads in Webstation .
I have Raspberry Pi units spread around the factory that display a general information screen and its these I want to log on automatically .
Thanks
RichJanuary 7, 2022 at 6:16 am #9856manjey73ParticipantYes, it is possible
January 7, 2022 at 6:48 am #9857manjey73Participanthttps://yadi.sk/d/RZArYfy89mgjkw
Strange, this plugin is not in the repository. Here is the link to the plugin that the author gave.
Go to js and edit autologin.js my version is below with a delay of 20 seconds, which allows you to have time to change the user if necessary.
$(document).ready(function () {
$(“#txtUsername”).val(“operator”);
$(“#txtPassword”).val(“1234S”);
sleep(20000).then(() => { document.getElementById(“btnLogin”).click(); })
});function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
}January 7, 2022 at 11:17 am #9859MikhailModeratorHi,
In Rapid SCADA 6 an auto login feature will be available out of the box.January 8, 2022 at 6:29 am #9864Rich ExParticipantHi Mikhail & Manjey
Thank you for you help
Rich
January 11, 2022 at 11:14 am #9887Rich ExParticipantJanuary 17, 2022 at 1:58 pm #9924January 17, 2022 at 2:06 pm #9925Rich ExParticipantHi Manjey
Tried the auto log on plugin , its not working .
Double checked al the files are in the correct place but no problem found with that .
When I log on its just as the old way with no automation , I checked my browser (Chrome) and that is set to allow js .
I tried changing the log on details in the $(“#txtUsername”).val(“Admin”); but this di not make any difference to the Webstation logon screen .Any ideas what could be happening .
Thanks
RichJanuary 18, 2022 at 7:00 am #9928manjey73ParticipantThe script is located in the file /scada/ScadaWeb/js/autologin.js where you specify your user and his password. It may be necessary to reboot the web to update the scripts in the browser, for example by Ctrl+F5
January 18, 2022 at 9:02 am #9929Rich ExParticipantHi , please to report its all working great now .
The issue was that for some reasons some errors got into Manjeys code . When I cut and pasted it Visual studio showed the ” ” ” ” characters gave errors , it reports = The character U+201c ““” is not a basic ASCII character = ,maybe we are using different keyboards not sure , anyway it works great now .
//Working auto login with 20 sec delay …..
$(document).ready(function () {
$(“#txtUsername”).val(“guest”);
$(“#txtPassword”).val(“12345”);
sleep(20000).then(() => { document.getElementById(‘btnLogin’).click(); })
});function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
}Thanks for the help again
RichJanuary 18, 2022 at 9:21 am #9930manjey73ParticipantExactly, this forum is slightly spoiling some characters when inserting.
January 18, 2022 at 1:09 pm #9933MikhailModeratorWhen inserting code, try <pre>your code </pre> tags:
your code
January 18, 2022 at 1:25 pm #9936manjey73Participant$(document).ready(function () { $("#txtUsername").val("operator"); $("#txtPassword").val("1234S"); sleep(20000).then(() => { document.getElementById("btnLogin").click(); }) }); function sleep(ms) { return new Promise(resolve => setTimeout(resolve, ms)); }
Strange, I have double quotes and it works. Maybe the quotation marks code is from the Russian language, but it seems they should be the same.
If you look in HEX format, the quote code is 0x22 everywhere
- This reply was modified 2 years, 2 months ago by manjey73.
January 19, 2022 at 11:46 am #9946Rich ExParticipantHi , ok thanks to you both .
Was just and observation and not in any way a criticism of the help which worked great .Thanks again.
Rich -
AuthorPosts
- You must be logged in to reply to this topic.