Forcing function 'Wait on the case' to stop waiting

Hi all

is it possible to interrupt the function of 'wait on basis of events", so that he stops waiting?

Here's my situation:

In my VI, I use instances to get the windows API event messages. See here: http://www.ni.com/example/29394/en/ for a code example. A part is a DLL that takes the reference of the event and defines an event each time an event occurred (for example the mouse down, etc.). In this case, the VI is closed it is necessary to abandon immediately wait for them at the appearance, if not, the application become inactive until an event occurs.

I have not looked at the code over the years, so I don't really remember what it looks like, but what prevents you from splitting the occurrence of thread to the point where you know that VI stops and put in this case there? Obviously, this will cause your code to think that an event has occurred, then you need to add another mechanism to highlight that this is not the case, but it should be doable.

Another alternative is to use the time-out period. Of course, this will make question, with all the consequences of this, so it's up to you.

A third option is to add a layer between the presence and your actual code, which is essentially what Nathan suggested, but this suggestion is to do it on the side BT instead of in the DLL. This does not solve the problem you are having (you still need to write code to manipulate) and it makes the system more complicated, but it can make the API that your final code sees cleaner (for example using two events). According to what the code looks like, that might require some demons, etc., if you do not want this.

Tags: NI Software

Similar Questions

  • How to stop queuing in the structure of the case

    I'm trying to find the Summit and the Valley of the signal. I'm able to find it, but I don't want to make the zero with the pic. I just want to get the value of Ridge and Valley. Is it possible to stop queuing the values in the structure of the case? As I have a several signals which peak/Valley must be found that I can't use the library functions.

    Kanye wrote:

    I'm trying to find the Summit and the Valley of the signal. I'm able to find it, but I don't want to make the zero with the pic.

    First of all, and more which has been mentioned, there are serious shortcomings, making the Subvi is not very universal.

    • Your Subvi does NOT export the correct value of the Ridge (or Valley), but the value just after (which is more a peak or a Valley!)

    • Your Subvi is only the positive peaks and valleys negative. This seems very restrictive. In general, you could easily have a Valley even if all the data is positive. Right? (With the exception of the Valley of death for example, most of the valleys are above sea level, for example )

    • Your code is extremely complicated, with two sets of structures of the case, each stacked three deep, four change records and tons of comparisons. Here is a simpler version. (To imitate your outings, place a statement select after each comparison and output the value or zero depending on the result of the comparison).

  • my iphone 5 c screen stops working when I remove the case

    my iphone 5 c screen stops working when I remove the case

    Delete this case? Please explain what you ask a little more clear.

  • I closed and put my computer in its case after use. 3 hours later, when I went to use it again once I took the case and it was hot. It's on and he said "your computer was stopped because of a problem. Anyone had this happen?

    I shut down my computer and put it in its case after use. 3 hours later, when I went to use it again once I took the case and it was hot. It's on and he said "your computer was stopped because of a problem. Anyone had this happen?

    No. I have not experienced this before, after having turned off. It seems that your Mac was not completely extinguished before you he packed. Make sure that it is actually stopped before closing the lid.

  • Is it possible to an array of Boolean function number in a case without the table of Boolean structure?

    Hi guys! In my program, my "robot" (lego mindstorms EV3) has essentially read a code bar and do different things according to the codes bar, he reads and so I have an array of Boolean, and basically I need compare to the other Boolean tables. First of all, I used the "Boolean chart at number" function and then just put it in a structure of the case, but it turns out that the Boolean value to number function is not compatible with my Lego EV3 brick, so I have to find another way to do this. Any ideas?

    Help is appreciated! If you have any questions or if my question is confusing, just ask!

    Thank you.


  • 7 error "Paris 7.2.241.1enRegInstaller.exe of work and has been closed." A problem with the application to stop functioning properly. Windows will notify you if a solution is available.

    Original title - 7.2.241.1enRegInstaller.exe

    Hello.

    Today, JUST after I "Set Windows to update," twice, I got the disconcerting message:

    "Paris 7.2.241.1enRegInstaller.exe of working and was closed".

    A problem with the application to stop functioning properly.  Windows will notify you if a solution is available. »

    Any wisdom or experience with this?  I'm on a 64-bit HP Pavilion older (dv7-1245dx) with this OS JUST-update Windows (Vista Home Premium).

    Thank you.

    GIES W

    The solution has been found just uninstall bing bar, restart the computer, and if you want just bing toolbar to reinstall. This easy solution my system fixed.  Bing has again reminded all my points that I have amassed

  • Save as function opens a window full-screen stop see the doc, I'm trying to save

    When I use "save under" on a document it opens a window full screen (so I can choose where to save it) but it stops me see the document that I am recording so I memorize the title - this used to happen with Windows XP. Anyone got any ideas how I can get it to open a small window (mobile)? There is no option minimize!

    I assume you mean a Microsoft Word using Microsoft Word document.  If so, please repost your question in the Discussion of the Office group at: http://www.microsoft.com/office/community/en-us/default.mspx?dg=microsoft.public.word.docmanagement&lang=en&cr=US where issues of speech specialists will be more than happy to help you with your problem.  Don't forget to give them the version of Word that you use in your message.

    If this is not the case, what program are you talking about (name and version)?  This happens with other programs?  Have you tried to uninstall and reinstall the program to see if that solves the problem?

    Good luck!

    Lorien - MCSA/MCSE/network + / has + - if this post solves your problem, please click the 'Mark as answer' or 'Useful' button at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • Cancel my subscription on 1 August was told by André that he would "worsen the case" to the team and I would be notified within 2-3 business days... Still waiting.

    Cancel my subscription on 1 August was told by André that he would "worsen the case" to the team and I would be notified within 2-3 business days... Still waiting.

    Hi Garry,

    Your subscription has been cancelled. The number of cases of your refund is: 216253479.

    Sorry for your trouble and it took so long to get addressed.

    Guinot

  • When you try to install Adobe Standard XI, he says: "Setup has detected that you already have a more functional product installed. Steup will stop now. "I have a trial Pro installed but do not sow the feature so much so I bought the standard.

    When you try to install Adobe Standard XI, he says: "Setup has detected that you already have a more functional product installed. Steup will stop now. "I have a trial Pro installed but do not sow the feature so much so I bought the standard.

    Uninstall versions acrobat and reader, if you have a win os clean (Download Adobe Reader and Acrobat tool - Adobe Labs), and then install acrobat std.

  • EXTRACT function can be used directly in the CASE statement WHEN

    I wrote the following SELECT statement. The function 'calc_time_diff' is a stored function that subtracts two timestamps and returns the result to the total number of seconds. My DBA does not 'calc_time_diff' as a stored function, then, I replaced the third line (in bold) in the SELECT statement with this:

    COUNTY ( BOX WHEN (extract (DAY OF v_end_ts-v_st_ts) * 24 * 60 * 60) +)

    (extract (HOUR FROM v_end_ts-v_st_ts) * 60 * 60) +.

    (excerpt (v_end_ts-v_st_ts MINUTE) * 60) +.

    extract ((DEUXIÈME à PARTIR de v_end_ts-v_st_ts) < 3600 THEN 1 END) less_than_1_hrs_count

    But the CASE above does not work. It returns the same value as COUNT (*). If the total number of tickets is 32 output will be

    total_tickets less_than_1_hrs_count

    32                                 32

    If I call the "calc_time_diff" then I get the correct result. What I'm doing wrong here?

    **********************************************************************************************************************************************************************

    SELECT

    Count (*) total_tickets,

    COUNTY ( CASE WHEN END of calc_time_diff (t.created_date, h.closed_date) < 3600 THEN 1) less_than_1_hrs_count

    OF n01.cc_ticket_info t

    JOIN IN-HOUSE

    (SELECT ticket_id, MAX (created_date) closed_date

    OF n01.cc_ticket_status_history

    WHERE ticket_status = 'CLOSED' AND created_date > = 18 August 2013 ' AND created_date < (to_date('08/24/2013','MM/DD/YYYY') + interval '1' DAY)

    GROUP BY ticket_id

    ) h

    WE (t.ticket_id = h.ticket_id)

    INNER JOIN n01.cc_ticket_notes n

    WE (n.created_date = h.closed_date)

    WHERE (t. ticket_status = 'NOTIFICATION' t.ticket_status 'CLOSED' = GOLD) AND t.created_date > = 18 August 2013 ' AND t.last_changed < to_date('08/24/2013','MM/DD/YYYY') + interval '1' DAY);

    ***********************************************************************************************************************************************************

    create or replace

    FUNCTION calc_time_diff)

    p_st_ts N01.cc_ticket_info. Type of LAST_CHANGED %,

    p_end_ts N01.cc_ticket_info. Type of LAST_CHANGED %)

    RETURN NUMBER

    AS

    v_no_sec NUMBER;

    v_st_ts N01.cc_ticket_info. Type of LAST_CHANGED %;

    v_end_ts N01.cc_ticket_info. Type of LAST_CHANGED %;

    BEGIN

    v_st_ts: = p_st_ts;

    v_end_ts: = p_end_ts;

    SELECT (extract (DAY OF v_end_ts-v_st_ts) * 24 * 60 * 60) +.

    (extract (HOUR FROM v_end_ts-v_st_ts) * 60 * 60) +.

    (excerpt (v_end_ts-v_st_ts MINUTE) * 60) +.

    excerpt ((SECOND from v_end_ts-v_st_ts)

    IN v_no_sec

    DOUBLE;

    Return v_no_sec;

    END calc_time_diff;

    Hello

    You don't need a function defined by the user or the EXTRACT to find the difference between two timestamps.

    SELECT COUNT (*) AS total_tickets

    , COUNTY ( BOX WHEN h.closed_date < t.created_date="" +="" interval="" '1'=""> )

                         THEN 1

    END

    ) AS less_than_1_hrs_count

    ...

    I hope that answers your question.
    If not, post a small example of data (CREATE TABLE and only relevant columns, INSERT statements) for all of the tables involved and the results desired from these data.
    Point where the above query is to produce erroneous results, and explain, using specific examples, how you get the right results from data provided in these places.
    If you change the query at all, post your modified version.
    Always say what version of Oracle you are using (for example, 11.2.0.2.0).

    See the FAQ forum: https://forums.oracle.com/message/9362002

  • User defined function in the cases in article

    Hello

    I have a function that returns in priview:

    (1,2,3,4)
    

    Now I am using this function in SQL where clause

    Selection of the debug version where id in debug.debug_process)

    Executing select I am getting ORA-01722 invalid number, I understand the functions return not only numbers but character symbols too "(en).

    It is posible to use the function defined by the user that do not return a NUMBER CASE statement IN clause?  If this is not the case, what advice can I sugest for a list of values for use in the Clause IN?

    ID.

    Thank you!

    The SQL IN clause requires a set as the parameter type.

    This means that the function used must provide a suitable type.

    Examples:

    SQL> create or replace type TNumberSet as table of number;
      2  /
    
    Type created.
    
    SQL>
    SQL> create or replace function FunkyFoo return TNumberSet as
      2  begin
      3          return(
      4                  new TNumberSet(7369,7499,7902)
      5          );
      6  end;
      7  /
    
    Function created.
    
    SQL>
    SQL> select
      2          *
      3  from       emp
      4  where      empno in(select * from table(FunkyFoo));
    
         EMPNO ENAME      JOB              MGR HIREDATE                   SAL       COMM     DEPTNO
    ---------- ---------- --------- ---------- ------------------- ---------- ---------- ----------
          7369 SMITH      CLERK           7902 1980/12/17 00:00:00        800                    20
          7499 ALLEN      SALESMAN        7698 1981/02/20 00:00:00       1600        300         30
          7902 FORD       ANALYST         7566 1981/12/03 00:00:00       3000                    20
    
    SQL>
    SQL> select
      2          *
      3  from       emp
      4  where      TNumberSet(empno) submultiset of (FunkyFoo);
    
         EMPNO ENAME      JOB              MGR HIREDATE                   SAL       COMM     DEPTNO
    ---------- ---------- --------- ---------- ------------------- ---------- ---------- ----------
          7369 SMITH      CLERK           7902 1980/12/17 00:00:00        800                    20
          7499 ALLEN      SALESMAN        7698 1981/02/20 00:00:00       1600        300         30
          7902 FORD       ANALYST         7566 1981/12/03 00:00:00       3000                    20
    
    SQL>
    
  • How to stop the case change in SQL developer Editor

    Dear friends,


    When I begin editing in Developer SQL (version 1.6), case or formatting words is changed automatically.
    Y at - it no option to stop the change of the case.

    Thanking in advance
    Sanjeev

    Assuming you're the 2.1.X SQL Developer trying to disarm

    Tools-> preferences-> Code Editor-> completion Insight-> change as you type

  • How can I block a program that I have not loading when I start the computer. What is own mac. It comes to start scaning and ask to activate. Is this something authorized by apple. If this is not the case, how can I stop it from loading up.

    Recently whenever I start the computer a program named Mac cleaning charge, stat my scanning system and ask to activate. It looks like a third party program that I should pay. Is it an accredited program for mac. If this is not the case, how can block this load upward.

    Is it called Advanced Mac Cleaner?  If so go here. http://AMC.Kayako.com/Knowledgebase/article/view/4/0/how-to-uninstall-advanced-m ac-cleaner

    It is malware.

    Edit: See post of Linc Davis on this topic for more detailed information.

    Advanced Mac cleanser

  • The space bar has stopped working in text blocks. Iendupwithsentaceslikethis - I have reset the mac, but it is always the case please help!

    Iendupwithsentaceslikethis - I have reset the mac, but it is always the case please help!

    Latest version CC

    Richard

    Solved the problem - I just changed a Chinese document. I copied the milling guide in a new document.

  • using the function to decode or case in query

    Hi experts

    I use the Oracle 11 G server, I need to check the length of the value in the name column of the table employee and if length (name) > 39 then the value should be substr (name, 0, 39)
    else value should be the name.
    I tried code below
     
    select CASE when length(name) > 39,substr(name,0,39)
                else name
           END
      from employee 
    but it's not working... can I do this using decode too? which one would be better or this is not a good way?

    Thank you

    Hello

    siebelD wrote:
    Hi experts

    I use the Oracle 11 G server, I need to check the length of the value in the name column of the table employee and if length (name) > 39 then the value should be substr (name, 0, 39)
    else value should be the name.
    I tried code below

    
    select CASE when length(name) > 39,substr(name,0,39)
    else name
    END
    from employee 
    

    but it's not working...

    Review the syntax of the CASE expression in the Manual of the SQL language. An expression BOX always at least a THEN clause. Commas are not part of the syntax of the CASE expression.

    can I do this using decode too?

    Of course, everything you can do with CASE, you can also do it with DECODE.

    that it would be better

    This is one of the many situations where the CASE is much shorter, clearer and more effective than DECODE.

    or is not a good way?

    What is

    SELECT  SUBSTR (name, 1, 39)  AS employee_name
    FROM    employee;
    

    ?
    If the name is 39 characters (or less), then SUBSTR (name, 1, 39) will ship itself, unchanged.

    Published by: Frank Kulash on 3 March 2013 14:07

Maybe you are looking for