LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

SMTP email sending and executable

Hi all !
I have some problems related to my executable I talked about in another message. I decided to create another thread to that question. Hope I'm doing it right !
 
As I told you my code is working perfectly. But I got some problems when I created an executable. You guys helped me solve them but now I got another problem:
I'm using SMTP to send a message notification after a certain condition is met (please see the attached VI).   The "normal " code is working well but the executable, not!
When I run the executable it's continually sending emails. It should normally send just one time! Can somebody tell me  what's going wrong with my executable?

Best regards
Kabanga
0 Kudos
Message 1 of 23
(3,271 Views)

Hi Kabanga,

i see no problem with it, but why don´t you use a "wait until next ms multiple"? What do you want to do? You could also use an event structure to count your clicks.

Mike

0 Kudos
Message 2 of 23
(3,268 Views)

I don't know why it work in edit mode, but not in exe.

If you place your bottom Switch-Case into the upper (in case TRUE), than it should send only once. I think.

0 Kudos
Message 3 of 23
(3,267 Views)

Hi Kabanga,

here is an example with the event structure, so you don´t need the "wait until next ms multiple".

Mike

0 Kudos
Message 4 of 23
(3,257 Views)

Hi Mike,

thanks for your help.
I just put the "OK" button for explanation purpuse. In fact the "ok" is done programatically each time I receive a defined byte from the serial port (please see the attached VI).
You helped me solve the problem related to byte reception and case-structure "driving"  last week. I'm very sorry not having mentioned it to you know.
Is it possible in that case to use the event-structure?

Best regards
Kabanga

 

 

0 Kudos
Message 5 of 23
(3,244 Views)

Hi Kabanga,

yes it is possible in this way. Is your serial receive function inside the while loop? When do you want to send the email? Why don´t you connect the reset for the counter?

Mike

0 Kudos
Message 6 of 23
(3,237 Views)

Hi Kabanga,

now i see the problem. If the number is 12 it change first after you receive your signal again, so the mail will sent until the next event occurs. So one solution could be to reset your counter after sending the mail, or to increase it.

Mike

0 Kudos
Message 7 of 23
(3,234 Views)

Thanks Mike, I'll use the solution you gave me and will late you know the outcome.

Best regards
Kabanga

 

0 Kudos
Message 8 of 23
(3,215 Views)

Hi Mike,

after modifications my executable is still sending many emails as soon as it begins to run!
The edit mode is working very well. I cannot figure out what is going wrong.

Best regards
Kabanga


 

0 Kudos
Message 9 of 23
(3,195 Views)

Hi Kabanga,

did you add the "wait until next ms multiple" or some other things to slow down you loop?

Mike

0 Kudos
Message 10 of 23
(3,193 Views)