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 - rmac

Pages: [1] 2
1
Open Discussion / Re: Emailer problems
« on: January 18, 2018, 05:00:13 PM »
I've been using gmail smtp with port 587 for about a year with no issues.

2
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 09:50:54 PM »
Archie,
I added a few lines to the basicdatalogger and it does work now with the True/False values from N7:0/x in the Collection List.
See below.
THANK YOU VERY MUCH FOR YOUR PATIENCE!!!

For Each item In PLCAddressValueItems
                    If item.ScaleFactor = 1 Then
                        If item.LastValue = "True" Or item.LastValue = "False" Then
                            StringToWrite &= "," & item.LastValue
                        Else
                            StringToWrite &= "," & CDbl(item.LastValue).ToString("0.0")
                        End If

                    Else
                            Try
                            StringToWrite &= "," & (item.LastValue * item.ScaleFactor)
                        Catch ex As Exception
                            StringToWrite &= "," & "INVALID-Check scale factor-" & item.LastValue
                        End Try
                    End If
Next

3
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 08:46:25 PM »
In the datalogger I replaced this line :

StringToWrite &= "," & CDbl(item.LastValue).ToString("0.0")

with the original one:

StringToWrite &= "," & item.LastValue

And everything works OK.
Something needs to be added to the first line to avoid the True/False values from being treated as numbers, if I want to keep my numeric values with just one decimal point.


4
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 08:36:42 PM »
It looks the problem lies in the list of Items in the Collection.
I have a couple of bits N7:0/6 and N7:0/7 in the list and it seems they are not accepted.
When I add one of those to the working Collection list, it does not get recorded any more. No matter in what position they are in the list.
As soon as I remove them the basicdatalogger works as  a charm.
If that is the case, how can I include the status of those bit in the list?

5
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 08:04:52 PM »
So I had the lines shifted.
I placed the breakpoint now at lines 234 and 242 and ran the program.
It didn't stop at any breakpoint.

6
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 08:02:21 PM »
I remembered that I replaced this:
StringToWrite &= "," & item.LastValue
by this:
StringToWrite &= "," & CDbl(item.LastValue).ToString("0.0")

That's what you suggested to get the result with one decimal point.

7
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 07:48:43 PM »
It does stop at breakpoint.
I tried with no PLC connected. Cannot have it online now.
The weird thing is that it does work fine for the first basicdatalogger instance.
Is there any limit on the number of tags in the Collection list?

8
Support Questions / Re: Basicdatalogger2 not recording in real time
« on: March 29, 2017, 06:24:48 PM »
Same ComComponent.
PauseLogging is set to False. Using TimeInterval

9
Support Questions / Basicdatalogger2 not recording in real time
« on: March 29, 2017, 05:19:56 PM »
Hello,
I have two basicdatalogger2 running. One of them reads 3 tags from the PLC, the second one reads 27 tags.
When AHMI is running without PLC connection both files are updated with zero values, of course, but OK.
When the PLC is connected, the first datalogger2, the one that only reads 3 tags, works fine.
The second one doesn't record anything. The values are shown on the screen, but they are not recorded by the basicdatalogger.
Any thoughts??
Thank you.


10
Support Questions / Re: Catching the exception
« on: March 23, 2017, 07:05:58 PM »
I put a group of "write to PLC" commands inside the Try and it did work.
I realized that a reaction to the first one is enough.
Got my response to the exception "under control" now.

Thanks again Archie.
Much appreciation.

11
Support Questions / Re: Catching the exception
« on: March 23, 2017, 06:53:04 PM »
Should I use Try for every read/write, or I can group several read/write operations inside one Try?

12
Support Questions / Re: Catching the exception
« on: March 23, 2017, 06:50:41 PM »
You are right. As usual.
I'm trying to write/send some values to the PLC from the code.
Will try your suggestion asap.
THANK YOU.

13
Support Questions / Catching the exception
« on: March 23, 2017, 06:24:21 PM »
Is there a way to catch this exception inside the application?
It's clear I'm getting the error because there is no connection with the PLC, but I would like to be able to catch/report that, instead of getting this pop up message from .Net Framework.
If I hit Continue the program resumes operation, without showing any readings from the PLC of course.
Any help will be appreciated.

14
Support Questions / Re: Numeric format in the basicdatalogger2
« on: March 20, 2017, 10:52:40 AM »
It does work!
Thank you again for your prompt reply.

15
Support Questions / Re: Numeric format in the basicdatalogger2
« on: March 20, 2017, 10:43:22 AM »
Thank you for your reply Archie.
I'm using two instances of Basicdatalogger2 to write/update two separate log files.
Will try your suggestion as soon as I can.

Pages: [1] 2