Author Topic: Issues with Windows 10 Ent and AdvancedHMI programs  (Read 1626 times)

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Issues with Windows 10 Ent and AdvancedHMI programs
« on: May 23, 2019, 09:46:52 AM »
We are in the process of upgrading from windows 7 to windows 10 Ent and I'm having trouble getting the AdvancedHMI programs to run on these new windows 10 machines. I have the source files saved on our file server so all we have to do is give users a shortcut to the .exe file and it worked on windows 7.

On windows 10 this doesn't work anymore and the only way I've found to get it to work is to copy the entire debug folder to the windows 10 machine which is a problem because if i need to update the project ill need to go around to every ones PC and copy the new debug folder to their PC's.

Is there anyway around copying the entire debug folder over to the users PC to get it to work with windows 10?

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #1 on: May 23, 2019, 10:03:23 AM »
I have never ran something from a network drive, but it sounds to me like a change in permissions. Do the files have execute permission? Did you try to Run As Administrator?

What happens when you try to run it? Do you get any errors?

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #2 on: May 23, 2019, 10:14:07 AM »
I opened the security up to everyone with full control on our file server so i don't think its permissions. I also tried to run as administrator and it does nothing. When i click the shortcut nothing happens at all on screen, the only way i know its erroring is if i look at the event logs and it has a couple of errors each time i try to open it. I also changed the .net framework settings in the project a couple of times to see if maybe that would help but i didn't notice any change. I attached the errors below.

First Error:
Faulting application name: AdvancedHMI.exe, version: 3.9.9.24, time stamp: 0x5ce69e0d
Faulting module name: KERNELBASE.dll, version: 10.0.17134.1, time stamp: 0x149ab0fd
Exception code: 0xe0434352
Fault offset: 0x0010d722
Faulting process id: 0x22a4
Faulting application start time: 0x01d51170f02b4a27
Faulting application path: \\gad-fs\Depts\Line Overview\Date Calculator\AdvancedHMI\bin\Debug\AdvancedHMI.exe
Faulting module path: C:\WINDOWS\System32\KERNELBASE.dll
Report Id: ed39db77-f311-4a52-ae64-16b8e80c4d21
Faulting package full name:
Faulting package-relative application ID:

Second Error:
Application: AdvancedHMI.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Net.Sockets.SocketException
   at System.Net.Sockets.Socket..ctor(System.Net.Sockets.AddressFamily, System.Net.Sockets.SocketType, System.Net.Sockets.ProtocolType)
   at System.Net.Sockets.TcpListener..ctor(System.Net.IPAddress, Int32)
   at System.Runtime.Remoting.Channels.Tcp.TcpServerChannel.SetupChannel()
   at System.Runtime.Remoting.Channels.Tcp.TcpServerChannel..ctor(System.Collections.IDictionary, System.Runtime.Remoting.Channels.IServerChannelSinkProvider, System.Runtime.Remoting.Channels.IAuthorizeRemotingConnection)
   at System.Runtime.Remoting.Channels.Tcp.TcpServerChannel..ctor(System.Collections.IDictionary, System.Runtime.Remoting.Channels.IServerChannelSinkProvider)
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.RegisterChannel(ChannelType, Boolean)
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(System.String[])
   at MfgControl.AdvancedHMI.My.MyApplication.Main(System.String[])

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #3 on: May 23, 2019, 10:29:50 AM »
Are you using a mapped drive or the full path name?

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #4 on: May 23, 2019, 10:34:01 AM »
The full path name.

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #5 on: May 23, 2019, 10:34:52 AM »
The error refers to System.Net.Sockets.TcpListener . Does your application have any code other than the drivers? All of the drivers are clients, therefore should not use a Listener.

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #6 on: May 23, 2019, 10:39:36 AM »
The only thing in AdvancedHMI that uses the TCPListener is the SimpleWebServer. Do you have one of those in your application?

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #7 on: May 23, 2019, 10:42:06 AM »
I dont think so, but im not entirely sure what that is.

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #8 on: May 23, 2019, 10:45:39 AM »
Do a search on the Entire Application for "TCPServer"

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #9 on: May 23, 2019, 10:46:08 AM »
Here's the code behind the screen and a screenshot of it. This one is a pretty simple application to convert dates for QA.

Code:
Public Class DateCalc

    'On screen startup set the initial value of the dropdown box.
    Private Sub DateCalc_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        ShelfLife.SelectedIndex = 1 'Select the first value in dropdown box on screen startup.
    End Sub


    Private Sub BtnShelfLife_Click(sender As Object, e As EventArgs) Handles BtnShelfLife.Click
        Dim ProductDate As Date = ProdDate.Value
        Dim ShfLife As Int16 = ShelfLife.Text

        'Format Production date as Julian date.
        Julian.Text = ProdDate.Value.DayOfYear

        'UseBy Date = ProductDate + ShfLife, Converted to MMM DD YYYY format.
        UseByDate.Text = String.Format("{0:MMM dd yyyy}", ProductDate.AddDays(ShfLife).Date)



    End Sub

End Class

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #10 on: May 23, 2019, 10:48:32 AM »
This doesn't look like an AdvancedHMI application. Is that the only form in the application? If so, I would create a blank VB WinForms application and import that form into it.

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #11 on: May 23, 2019, 10:53:53 AM »
I built it in AdvancedHMIv35 but ill try what your talking about. I'm not a Vb programmer so bear with me. I attached another screenshot showing the header and version. There are two other forms one is MainForm and the other is Page2.

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5270
    • View Profile
    • AdvancedHMI
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #12 on: May 23, 2019, 10:58:58 AM »
Since you are not using any of the AdvancedHMI drivers or controls it is better not to base the application on AdvancedHMI.

- File->New->Project
- Select Windows Forms App for Visual Basic
- Give it a name and click Next
- Once the applications is created, in Solution Explorer right click the project and select Add->Existing Item
- Browse to and select the DateCalc.vb file in the other project
- You should now be able to run your application

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #13 on: May 23, 2019, 11:05:32 AM »
I also have another program that pulls data from SQL and AB PLC's that isn't working as well. The date calclator program is small and easy to dig into that's why i was using it as a guinea pig. I'll try what you're explaining though and see if it fixes the problem.

jsu0234m

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: Issues with Windows 10 Ent and AdvancedHMI programs
« Reply #14 on: May 23, 2019, 11:15:56 AM »
Since you are not using any of the AdvancedHMI drivers or controls it is better not to base the application on AdvancedHMI.

- File->New->Project
- Select Windows Forms App for Visual Basic
- Give it a name and click Next
- Once the applications is created, in Solution Explorer right click the project and select Add->Existing Item
- Browse to and select the DateCalc.vb file in the other project
- You should now be able to run your application

It has to be a windows 10 and shared files issue. I did what you said and and saved it to our file server and i was able to open it from my windows 7 machine and it worked right but once i tried to open it from the windows 10 machine it gave me a network error.