LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

event structure

There are many ways to Rome. Since I haven't got so much experience I would have used Sys Execute and run the shutdown commando there. A shutdown is a shutdown and wich way you do it doesn't really matter unless the rest of your code says so.

Regards,
Even
_________________________________
Certified LabVIEW Associate Developer

Automated Test Developer
Topro AS
Norway
0 Kudos
Message 11 of 23
(1,286 Views)
0 Kudos
Message 12 of 23
(1,282 Views)

Now we are off topic. If you are interested in helping me, please reread my post

 

I DID say that I have the shutdown procedure working....so thats not really where I'm seeking assistance.

 

My issue is using some type of time comparison in an event structure.

 

Thanks anyway

0 Kudos
Message 13 of 23
(1,273 Views)

As I said in my first answer, you need a case structure, not an event structure. What's up with your fixation on events?

 

If you want to use the event structure, you can do more than one thing in the timeout case, e.g. by placing a case structure that depends on state. Where exactly do you still have problems?

0 Kudos
Message 14 of 23
(1,264 Views)

Hi,

 

I have attached a VI that might help you.

 

Martin

0 Kudos
Message 15 of 23
(1,258 Views)

Hi Marty,

 

Seems a bit of an overkill creating a custom event to trigger from the timeout event that the custom event then handles when you could just simply put the code in the timeout case.

 

Rgs,

 

Lucither.

------------------------------------------------------------------------------------------------------
"Everything should be made as simple as possible but no simpler"
0 Kudos
Message 16 of 23
(1,233 Views)

Here is a VI that should accomplish what you want. It is very similar (almost identical) to the above posted VI.

0 Kudos
Message 17 of 23
(1,206 Views)

Good Morning All

 

Firstly thank you all for taking an interest in my post and for the help.

 

Martin.....thta is definitely a way of doing it that I was not aware of. I haven't had much experience with queueing events, so it tends to narrow my vision down to what I do understand.

 

Lucither......this is very much the way I was contemplating doing it....just couldn't get the germ of an idea onto my desktop....I'll try and incorporate that into my code.

 

Paul...thanks mate, but I couldn't open it. I'm using LV2009, so if you could convert it for me, I'd be interested in having a look at it.

 

Altenbach.......no...no fixation with events....as I suggested in my first post.....the snippet was a small part of a very much larger program, with the main suspect being an event structure doing the majority of the work. It seemed sensible to continue using the same coding philosophy, but then nobody ever accused me of being sensible.

 

Once again, thanks all. Your assistance is appreciated.

 

Regards

Ray

 

 

0 Kudos
Message 18 of 23
(1,187 Views)

Hello Lucither

 

I tried out your vi and of course it does work.......however, I am using the timeout event for another use.......with a timeout value of 5 minutes, I'm using the event to return to a default page of a tab control.

 

The timeout value of 5 minutes is way too long for using as a time shutdown (with your value of 100ms, its fine, but screws up my tabulation process).

 

Is there another way to incorporate the system time change code into the event structure using another event?

 

Thanks and best regards

Ray

0 Kudos
Message 19 of 23
(1,175 Views)

Hi Ray,

 

All you have to do is have a timer in the timeout section that handles the tab change. Im assuming that you want the timer to reset every time an event is triggered. If so the attached will point you in the right direction.

 

You may need to add some logic so the tab change to default only happens if the page is not on the default page, otherwise it will do this every 5 mins if no event is triggered,

 

Rgs,

 

Lucither

 

 

 

 

 

------------------------------------------------------------------------------------------------------
"Everything should be made as simple as possible but no simpler"
0 Kudos
Message 20 of 23
(1,171 Views)