Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Cowboy1

Pages: [1] 2 3 ... 5
1
Support Questions / Re: Start Form
« on: September 08, 2015, 07:57:16 PM »
Ok it is working thanks for everybody's help
I deleted all temp files
I deleted all obj and bin directories.
I rebuilt the project
I didn't use publish and was able to move the custom icon that I had linked in the project properties window to the desktop to run the project.


2
Support Questions / Re: Start Form
« on: September 07, 2015, 11:18:50 PM »
Godra,

I created the desktop icon in the properties section of the project and published the project. I used a beer glass image in ".ico" format. When I select the icon it opens the project, but for some reason the project is not communicating with the PLC. When I open VS and open the project and run it, everything works great.
Thanks

3
Support Questions / Re: Start Form
« on: September 07, 2015, 05:40:58 PM »
OK after rebooting computer everything is working but not connected to PLC when using the desktop icon. When I use VS to start project it is connected?

4
Support Questions / Re: Start Form
« on: September 07, 2015, 05:17:42 PM »
When I select start in Visual Studio it acts like it is trying to start and says something about loading symbols at the bottom of the screen and goes right back into the build screen.

5
Support Questions / Re: Start Form
« on: September 07, 2015, 05:00:33 PM »
I cleared all 6 and still can not run my project from Visual Studio or the desktop icon.

6
Support Questions / Re: Start Form
« on: September 07, 2015, 04:38:06 PM »
Ok and delete everything in those folders? I have a lot of files in each folder is that normal?

7
Support Questions / Re: Start Form
« on: September 07, 2015, 04:30:31 PM »
how do I locate them?

8
Support Questions / Re: Start Form
« on: September 07, 2015, 04:17:00 PM »
Well I have a icon on my desktop but can not open the application with the icon or from Visual studio. I don't know what I did wrong but it will not load now. I get a error stating Application can not be started contact application vendor.

9
Support Questions / Start Form
« on: September 07, 2015, 12:21:45 PM »
I know this is probably very basic but I have not been able to find anything in my searches. Is there a way to select which form opens when the project loads?
Another question.
Is there a way to create a project ICON on the desktop to select that would load my project?

I have basically finished my project just doing some clean-up, I'm sure as I get this thing running I will want more bells and whistles but I have a real good starting point.
Thanks for everybody's help.

10
Support Questions / Re: msgbox for button
« on: August 31, 2015, 11:59:44 AM »
I used this code that i found on this forum and I maybe missing something.
when i click a button to toggle a bit the message pops up with a yes or no question but the bit still toggles before I answer.


If MsgBox("Are you sure?", Microsoft.VisualBasic.MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
            EthernetIPforPLCSLCMicroCom1.Write("B3/100", "1")
        End If

Darrell

Darrell,

I think this may work:

 If   
    MsgBox("Are you sure?", Microsoft.VisualBasic.MsgBoxStyle.YesNo)
EndIf

      If
        MsgBoxResult.Yes Then
            EthernetIPforPLCSLCMicroCom1.Write("B3/100", "1")
     End If

11
Support Questions / Re: Help with boil additions
« on: August 28, 2015, 08:53:29 PM »
Archie,

The pause forms from polling was a huge help.
On my 6 main screens
Batch Set-Up = 35 data points polling < 1sec
Fill and Heat = 46 data points polling < 1 sec
Mash = 85 data points polling 1 - 2 seconds -messagebox sound delayed
Sparge = 57 data points polling < 1 sec
Boil = 68 data points polling 1 - 2 seconds - message box sounds delayed.
Chill = 35 data points polling < 1 sec

Total running prior to pausing hidden forms was 326 guess that might slow updates.

Thanks for your help,

David

12
Support Questions / Re: Help with boil additions
« on: August 28, 2015, 05:40:01 PM »
Thanks Godra and Archie for the code provided. I know they both work but I had polling problems, so I have removed the code for batch additions believing it was causing long poll times since I noticed it after trying the code. After removing it and writing it into the PLC program, I still have long polling times @ >6 seconds. The PLC is very responsive just not the display. Is there any way you know that I can find my problem I have 8 forms in this project? If I should create another post for polling problem just let me know and I will start a new thread.

Thanks,

David

13
Support Questions / Re: Help with boil additions
« on: August 27, 2015, 07:24:38 PM »
Archie,


I think this code will work but for some reason my poll rate is around 7 seconds? Do you think this code would slow it down that much? I have had great speed up until now.

Code: [Select]
Private Sub Label5_TextChanged(sender As Object, e As EventArgs) Handles Label5.TextChanged

        If Not String.IsNullOrEmpty(Label51.Text) AndAlso String.Compare(Label51.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label12.Text & " " & Label41.Text & " " & Label61.Text, "1st. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label50.Text) AndAlso String.Compare(Label50.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label13.Text & " " & Label40.Text & " " & Label60.Text, "2nd. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label49.Text) AndAlso String.Compare(Label49.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label14.Text & " " & Label39.Text & " " & Label59.Text, "3rd. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label48.Text) AndAlso String.Compare(Label48.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label15.Text & " " & Label38.Text & " " & Label58.Text, "4th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label47.Text) AndAlso String.Compare(Label47.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label16.Text & " " & Label37.Text & " " & Label57.Text, "5th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label46.Text) AndAlso String.Compare(Label46.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label17.Text & " " & Label36.Text & " " & Label56.Text, "6th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label45.Text) AndAlso String.Compare(Label45.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label18.Text & " " & Label35.Text & " " & Label55.Text, "7th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label44.Text) AndAlso String.Compare(Label44.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label19.Text & " " & Label34.Text & " " & Label54.Text, "8th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label43.Text) AndAlso String.Compare(Label43.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label24.Text & " " & Label33.Text & " " & Label53.Text, "9th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
        ElseIf Not String.IsNullOrEmpty(Label42.Text) AndAlso String.Compare(Label42.Text, Label5.Text, True) = 0 Then
            System.Windows.Forms.MessageBox.Show("Perform " & Label20.Text & " " & Label29.Text & " " & Label52.Text, "10th. Boil Addition", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)

        End If

    End Sub

14
Support Questions / Re: Help with boil additions
« on: August 26, 2015, 11:00:57 PM »
Archie,

What you have there looks right.

Couple of things that might need consideration:
1. I can have multiple additions that would be made at any time including 00:00:00.
2. I could have up to 10 additions in a batch.

Label 5 is updated by a datasubscriber:

Code: [Select]
Private Sub DataSubscriber1_DataChanged(sender As Object, e As Drivers.Common.PlcComEventArgs)
        Dim ts As TimeSpan = TimeSpan.FromSeconds(e.Values(0))
        Dim mydate As DateTime = New DateTime(ts.Ticks)
        Label5.Text = mydate.ToString(("HH:mm:ss"))

    End Sub

Driver Poll rate=500
Datasubscriber1 Poll rate=0


Thanks,

David


15
Support Questions / Re: Form stops running
« on: August 26, 2015, 10:52:20 PM »
Archie,


Thanks for your help with this it works perfectly a lot smoother than the timer I stepped up the poll rate just to see response until I get actually running in the next couple of weeks. I posted the complete code for anybody that might use it for reference in the future.

Code: [Select]
Private lastValue As Single
    Private currentValue As Single
    Private vesselFillRate As Single
    Private Sub DataSubscriber3_DataReturned(sender As Object, e As Drivers.Common.PlcComEventArgs) Handles DataSubscriber3.DataReturned
        Me.currentValue = e.values(0)
        vesselFillRate = (Me.currentValue - Me.lastValue) * 6
        Me.BasicLabel4.Value = vesselFillRate 'This you could change to CInt(vesselFillRate) to get round value
        Me.lastValue = Me.currentValue
    End Sub

End Class

Pages: [1] 2 3 ... 5