How To Print Alarm Summary For Operator Using Workspace Only ?

We would like to print out alarm summary with credential of "Operator" user name.  

Yes, we have it in XML but how can we print out the document when operator has only access to workspace only.

Is it possible for us to display list of xml file for the alarm summary directory at the graphics workspace and printout from workspace?

If so kindly provide the scripting / graphics of this same.

I still observe a lot bug with alarm summary with version 11.3.1 :(

  • There are many very complicated scripting methods for doing what you require, but the simplest way which is recommended by the BOL article "Responding to Alarms" for handling these files is by installing Excel on the workstation, then simply accessing excel from the DeltaV Operate toolbar.  

    See  "Working with other Applications", "Launching Other Applications from DeltaV Operate" in Books On Line for the commands to launch excel.

    Once the file is open in excel, then you can print it.

    If installing excel on each node is not an option, you could launch internet explorer from the button and open the xml file with IE, but it probably won't be pretty. You can also pass IE the file name to open on load through the command argument.  To lock down IE, you can invoke kiosk mode, etc., to prevent wandering by the users.

    I don't know exactly what the XML looks like, but if you create an XSL template, you can render the XML in any format you like by using the DOM collection to transform it to html, then automatically open and print in a browser.  XSL is not easy (I've been working with it for years), but I suspect the XML schema for this particular set of data is not complicated.

    Lastly,  look at the ShellExecute subroutine in Operate.  Apprantly, you can use this command to tell a file to use its associated program to print it.  If the associated program for XML is IE or Excel on the workstation, then that might be a very simply way to get the printout without an intermediate step of having to open the application.

  • In reply to Youssef.El-Bahtimy:

    You can also transform the XML into an HTML table with a few lines of VBA:

    Set xmlDoc = New DOMDocument60

    Dim xmlDOMNodeList As IXMLDOMNodeList

    Dim xmlNode As IXMLDOMNode

    xmlDoc.async = False

    xmlDoc.validateOnParse = False ' No need to validate XML since we know it's origin

    xmlDoc.Load ("C:\Users\Frank\Documents\PRO_PLUS1_2012-10-20-211255.xml") ' Load XML file into xmlDoc variable

    Set xmlDOMNodeList = xmlDoc.SelectNodes("/ALARMSUMMARY/ALARM")

    Output_HTML = FreeFile() ' Get next free output file number

    Open "C:\Users\Frank\Documents\alarmlist.html" For Output As Output_HTML

    Print #Output_HTML, "<table border='1'><tr><th>Time_In</th><th>Description</th><th>Module Parameter</th>"

    Print #Output_HTML, "<th>Alarm</th><th>Message</th><th>Priority</th></tr>"

         For Each xmlNode In xmlDOMNodeList

                     On Error Resume Next

                     Print #Output_HTML, "<tr>" ' Initiate new table row

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Time_In").Text & "</td>"

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Description").Text & "</td>"

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Module_Parameter").Text & "</td>"

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Alarm").Text & "</td>"

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Message").Text & "</td>"

                     Print #Output_HTML, "<td>" & xmlNode.selectSingleNode("Priority").Text & "</td>"

                     Print #Output_HTML, "</tr>" ' End table row

                     On Error GoTo 0

         Next xmlNode

    Print #Output_HTML, "</table>"

    Close Output_HTML

    Start a DOS window (RUN CMD from Start), and run AlarmSummaryUtility.exe /? from C:\DeltaV\bin to see command line options.  Hence you can run frsruntask to execute this command with the /export switch; then run above VBA on the fixed/constant output filename, then open results in IE using frsruntask e.g. C:\Program Files (x86)\Internet Explorer\iexplore.exe -k C:\Users\Frank\Documents\alarmlist.html, right click and select Print to print table.  May want to include instructions to press ALT+F4 to close kiosk mode.  Path to IE will vary based on operating system.

    One technique I use, is to dump HTML files to an IIS server; then alarm/interlock summaries/batch charges, can be read from other computers in the plant.

  • In reply to Frank Seipel:

    One other comment on this thread, there is a free utility called PrintHTML available from http://www.printhtml.com/ This is a command line utility to print a web page, either from a file or external URL. it will print HTML from a file without loading IE, but using the IE engine to render what is printed.  You can even specify printer as a command line option, as well as headers, footers, margins, etc.  This may or may not be preferred over the kiosk method earlier proposed, depending on whether you want to view the list before printing.  Also if you choose to do this with Excel, you may not need to purchase Excel because the free Excel Viewer (read only) could be used. www.microsoft.com/.../details.aspx -- DeltaV could also open/print the file using Excel without making it visible for example:

    Dim exl As New Excel.Application

    Dim xls As Excel.Workbook

    exl.Visible = False

    Set xls = exl.Workbooks.Open("C:\Users\Frank\Documents\PRO_PLUS1_2012-10-20-211255.XML")

    xls.ActiveSheet.PrintOut

    xls.Close

    exl.Quit

    Set xls = Nothing

    Set exl = Nothing

    On another topic, what is typically used to send e-mails?  We use febootimail to send alerts based on a schedule (daily tank levels, certain alarms).  We have a schedule run on two workstations (second fires if first doesn't).  This seems to be quite reliable & we can configure which autodialer(s) are active and e-mail distribution lists from the faceplates.  I was wondering what others did for that application.  Now that I know a bit more about this it might have been better to just set this up in Excel on a dedicated computer using OPC.