Custom Page

Tagged: 

Viewing 15 posts - 1 through 15 (of 24 total)
  • Author
    Posts
  • #8371
    Matt3
    Participant

    Hi

    I’m looking to add channel values to a custom web page.
    I’ve used the files in this link as my starting example…
    https://github.com/RapidScada/scada-community/tree/master/Plugins/CustomPageExample

    How do you suggest reading multiple current values, say from channels 101, 102 and 105 of the hello World example?

    Thanks
    Matt

    #8376
    Mikhail
    Moderator

    Hi,

    Use getCurCnlDataExt function. If you run file search of “getCurCnlDataExt” on *.js files, you will find examples in the Table and Scheme plugins.

    #10368
    csshenrapid
    Participant

    Hi,
    Why can’t the page load all the time?About CustomPageExample.

    #10371
    Mikhail
    Moderator

    Hi,
    Could you explain your question?

    #10678
    ramiouba
    Participant

    Hi,

    I have RapidScada v5.8.4 installed and everything is working fine on my windows PC, I deployed the custom pages example exactly as mentioned in the following link https://github.com/RapidScada/scada-community/tree/master/Plugins/CustomPageExample

    But when I uploaded the “HelloWorld” project and re-logged into the SCADA and select the desired page nothing appeared, and the animated loading progress sign still rotating without any changes. I thing something is missing in the configuration, or the location of custom pages folder is not correct.

    Could you please help me to fix this issue?

    Thanks,
    Rami

    • This reply was modified 1 year, 10 months ago by ramiouba.
    #10685
    Mikhail
    Moderator

    Hi Rami,

    In browser press F12, select the Console tab and check the web page errors.
    Screenshots of configuration and error would help.

    • This reply was modified 1 year, 10 months ago by Mikhail.
    #10700
    ramiouba
    Participant

    Hi Mikhail,

    I checked the errors in browser’s console then I found the error that causes this issue.

    It was because I’ve defined a full path of the “myPage.html” file starting with “C:\SCADA\bla\bla\bla\myPage.html” in the interface database of the Scada Administrator, the browser console return an error that “the server can’t access local resources” where the file is located.

    I’ve changed the path to the one that mentioned in the example of “Custom Pages”, I paste it as it is “../../custom/MyPage.html” then it worked correctly.

    Thanks for your help Mikhail.

    Rami

    #10710
    Mikhail
    Moderator

    Hi,
    Good 🙂

    #12206
    Matt3
    Participant

    Hi Mikhail

    I’m starting to use v6 for live projects.
    I need to add a custom page showing 5 tag values. I modified the code in v5 to read channel data.
    Can you please provide script showing the best way to continuously read the values form from 5 channels and to show the value on the page.

    Thank you
    Matt

    #12225
    Mikhail
    Moderator

    Hi,

    Custom web page example for v6 has not been developed. You should use main-api.js to get data from a web page.

    #12495
    Matt3
    Participant

    Hi Mikhail

    We are using version 5.8.4 with 24 custom pages, in a production environment.
    We tried to port some of our pages to version 6.1.1 but failed, so we tried a very basic html page but failed there too. I can see the menu item “TEST” in the left hand menu but when I hover the mouse pointer over it, it changes to a “no entry” icon (red circle) so we cannot click the link.
    We are using the Hello World sample project and adding the custom page to item 3 in the list. I’ve been in to the browser view source option. I’ve added the source code below…

    1 – In version 6, if I have a file named Test.html, where should I save it (where is the custom folder located)?

    2 – and what path structure should I use when I enter the path, via ScadaAdmin, in the “view” section.

    Thanks
    Matt

    <div class='node-parts'><div class='indent'></div><div class='expander left empty'></div><div class='icon'></div><div class='text'>Simulator</div></div>
    
    <div class='node-parts'><div class='indent'></div><div class='expander left empty'></div><div class='icon'></div><div class='text'>TEST</div></div>
    
    • This reply was modified 1 year, 2 months ago by Mikhail.
    #12501
    Mikhail
    Moderator

    Hi Matt,
    1. SCADA\ScadaWeb\wwwroot\custom would be good.

    2. In the Views table set
    Path = (any)
    View Type = Web page view
    Arguments = ../custom/mypage.html (may be it’s not correct, but we need to start from somewhere)
    Title = (any)

    #12507
    Matt3
    Participant

    Hi Mikhail

    Thank you for your feedback.
    By moving the custom folder under wwwroot, I can show htm pages.

    Path
    ../../custom/Page1.htm

    Arguments
    ../../custom/Page1.htm

    View Type
    WebPageView

    Title
    \Page1

    However, when I copy default.aspx page, it is not shown? Are aspx pages not supported?

    Kind regards
    Matt

    #12510
    Mikhail
    Moderator

    Hi,

    *.aspx is an old ASP.NET extension. Webstation 6 uses Razor Pages for development.

    #12515
    Matt3
    Participant

    Hi Mikhail

    Aha!!!
    It makes sense now. I’ve started learning razor pages.
    Is it possible to have a few example pages showing how to add a custom page (an example sowing how to get 5 or more channel values would be perfect).

    Thanks
    Matt

Viewing 15 posts - 1 through 15 (of 24 total)
  • You must be logged in to reply to this topic.