Showing results 1 to 10 of 11

Thread: Close "Web-Client" window automatically

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    30.05.2007
    Location
    Salzburg
    Posts
    879

    Default Close "Web-Client" window automatically

    How can I close the "Web-Client" window automatically?
    This can be done with following VBA code:

    'API Function
    Public Declare Sub ExitProcess Lib "kernel32" (ByVal uExitCode As Long)
    
    Public Sub CloseWebClient()
        If thisProject.NetType = tpClient Then
            If MsgBox("Do you really want to close the Web-Client?", vbYesNo, "ExitProcess") = vbYes Then
                ExitProcess (0) 'close window
            End If
        End If
    End Sub

  2. #2
    Join Date
    20.08.2009
    Posts
    293

    Default Re: Close "Web-Client" window automatically

    This does not work anymore with IE8, for whatever reason.
    (IE hangs when executing the macro).

  3. #3
    Join Date
    20.08.2009
    Posts
    293

    Default Re: Close "Web-Client" window automatically

    With the attached zenon Project (650), IE Tabs/Windows from Version 6,7,8 can be closed (using VBA).
    Attached Files Attached Files
    Last edited by bernhardf : 4th August 2010 at 13:10

  4. #4
    Join Date
    02.06.2010
    Location
    Freiburg
    Posts
    175

    Default AW: Close "Web-Client" window automatically

    I'm sorry if this sounds stupid, but what do I have to do with the zip-file to get it working???
    zenOn Supervisor 7.60 + webserver pro

    Windows Server 2008 R2 / Windows 7 Enterprise

    ModbusTCP / LON / OPC / SQL / B&R

  5. #5
    Join Date
    20.08.2009
    Posts
    293

    Default AW: Close "Web-Client" window automatically

    Quote Originally Posted by michab View Post
    I'm sorry if this sounds stupid, but what do I have to do with the zip-file to get it working???
    It's a project backup (zenon version 6.50).

    Once you have opened it in the editor you have to change the server name (enter your runtime server name) in the network properties of the project.
    After that you have to adapt your webserver configuration file (global_vars.js), here the name of the project (TESTWEB) has to be entered.

    For further information regarding the configuration of the Webserver please see the documentation: Manual -> Web Server and Web Server Pro

    Regards,
    Bernhard

  6. #6
    Join Date
    02.06.2010
    Location
    Freiburg
    Posts
    175

    Default AW: Close "Web-Client" window automatically

    Sorry, ich muss das auf deutsch machen - hoffe, das ist okay so:
    "once you have opened it..." -> da würde ich gerne hin kommen! Ich krieg das Ding ja gar nicht geöffnet. Wenn ich mich nicht irre, muss ich einen bestehenden Arbeitsbereich geöffnet haben und dann unter Datei --> Projektsicherung rücklesen... den Pfad zur zip-Datei angeben und die Datei auswählen. Nur: wenn ich das mache, bleibt der "ok"-Button nicht anwählbar... Was ist zu tun?

    Grüße,
    Michael
    zenOn Supervisor 7.60 + webserver pro

    Windows Server 2008 R2 / Windows 7 Enterprise

    ModbusTCP / LON / OPC / SQL / B&R

Similar Threads

  1. Replies: 2
    Last Post: 9th June 2009, 12:53
  2. Replies: 0
    Last Post: 18th September 2007, 14:01
  3. automatically created limits
    By markclemens in forum zenon Supervisor
    Replies: 0
    Last Post: 20th August 2007, 10:21
  4. function "Export Data" on Windows CE
    By martinw in forum zenon Operator
    Replies: 0
    Last Post: 20th August 2007, 07:01
  5. On opening the archive MDI window an error appears!
    By wolfgangm in forum zenon Supervisor
    Replies: 0
    Last Post: 17th August 2007, 13:11

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •