Need to take the N-th element from a queue

hello everyone!
I have a problem, i don't know how to take ony one element from a queue...
Indeed, i need to take only the 3rd element of a queue but i don't know how to do that... so i though maybe i can change it as an array (with the vi "flush queue") and then take the 3rd element of this new array but same problem, i don't know how to manage that!
please help me, i have been trying to solve this problem all day long
thank you very much!
Yanis

I am not sure if there is a more elegant solution but what I have done in the past in similar situations was to get all elements of the queue with the queue status. Then I would flush the queue and pop any elements I wanted back on the queue while removing the items I needed/wanted. As I say, this is not the most elegant but it is a tried and true method. If your elements are fairly small and you don't have lots of elements on the queue the performance hit is not too terrible.
Mark Yedinak
"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot

Similar Messages

  • I have the djay app on my ipad and i want to record the set i'm playing on my iphone through garageband. i need to take the sound from the headphone jack of the ipad, as the 30pin connector will be used to connect to the DJLive accessory. Is this possibl?

    i have the djay app on my ipad and i want to record the set i'm playing on my iphone through garageband. i need to take the sound from the headphone jack of the ipad, as the 30pin connector will be used to connect to the DJLive accessory. Is this possibl?reco

    You may get a better response in this community:
    https://discussions.apple.com/community/app_store/garageband_for_ios

  • Get every 10 sec a int.value and need to take the sum of the last 18 values

    Hi,
    i get every 10 sec a int.value and need to take the sum of the last 18 values (3 minutes).
    the programm should work permanently.
    I tried with a 1d-array but didn´t get a result. Could anyone help me?
    Best regards
    kasche

    Use the example in the posted link, then add another shift register for your sum of all elements. Dont add all the elements every time, add them to a running total when they come in. You will need to evaluate how big this number is going to get, however, and decide if you should use an I64 for your running total of all elements. Even this will overflow eventually. 
    So your code would look like that posted by GerdW in the above link, then add a shift register with a starting value of 0. Then add your input value to the value comming from this shift register and send the output to the shift register's output terminal. This creates your running total of all values. The code by GerdW provides your "last 18 elements" total in a very efficient manner, just change the 15 to an 18.
    I have attached a sample bit of code to make it clear. I saved it in LV 8.0 so more people can open it.
    CyberTazer
    Software Systems Engineer
    Attachments:
    Running 18 total.vi ‏11 KB

  • I have three different e-mail addresses, and need to receive the incoming e-mails from the three sources.  How do I enable my iPhone to do it? Tks in advance.

    I have three different e-mail addresses, and need to receive the incoming e-mails from the three sources into my iPhone (it's presently receiving msgs from only one of them).  How do I enable my iPhone to do it? Tks in advance.

    Many thanks for your help!

  • Itunes is not recognizing my ipod.  there is no sync under file.  I need to download the music just purchased from itunes.

    itunes is not recognizing my ipod.  there is no sync under file.  I need to download the music just purchased from itunes.
    can anyone help?

    Do you see your iPod under Devices on the left side of the iTunes window in the source list when it's connect to your Mac?
    BTW...  you sync iTunes media from the tabs in the iTunes menu, not from the File menu unless you are transferring iTunes purchases from the iPod to your Mac.
    Might need to zoom to see this graphic. I have "Music" selected as an example.

  • Need to ommit the short form letter from the given string

    HI,
         I need to ommit the Short form letter from column data.
    EX :
    CREATE table #testdata
    (id int identity(1,1),cust_address varchar(max))
    insert into #testdata (cust_address)
    select 'first street 5N, North'
    union
    select 'second street W, west'
    union
    select 'roja street 5S, South'
    union
    select 'temple street E, East'
    union
    select 'first street, Northwest, NW'
    union
    select 'first street, Southwest, SW'
    select  * from #testdata
    actutal out put:
    id cust_address
    1 first street 5N, North
    2 first street, Northwest, NW
    3 first street, Southwest, SW
    4 roja street 5S, South
    5 second street W, west
    6 temple street E, East
    Need to ommit the Short form letter from this output,
    condition , 1) the short form letter should have space in front of the letter ex : first street (space)N, North
                   so the output should be "first street, North" like that for other words like "first street, Southwest, SW" should be "first street, Southwest"
                 2) the short form letter should not combine with any other letter ex :  first street 5N, North
                     here we dont need to do anything.
    Required Out put :
    id cust_address
    1 first street 5N, North
    2 first street, Northwest
    3 first street, Southwest
    4 roja street 5S, South
    5 second street, west
    6 temple street, East
    Nandha Kumar

     CREATE FUNCTION [dbo].[SplitString]
             @str VARCHAR(MAX)
        RETURNS @ret TABLE (token VARCHAR(MAX))
         AS
         BEGIN
        DECLARE @x XML 
        SET @x = '<t>' + REPLACE(@str, ',', '</t><t>') + '</t>'
        INSERT INTO @ret
            SELECT x.i.value('.', 'VARCHAR(MAX)') AS token
            FROM @x.nodes('//t') x(i)
        RETURN
      END
    with cte
    as
    select  *
    from #testdata
    CROSS APPLY (SELECT * FROM [dbo].[SplitString](cust_address)) AS der
    ) ,cte1
    as
    select *,
    case when UPPER(token)=token COLLATE Latin1_General_BIN
      then  '' else token end as d 
     from cte
     ) ,CTE2
     AS
     (SELECT *,case when RIGHT(UPPER(D),1)=RIGHT(D,1) COLLATE Latin1_General_BIN 
      then  replace(D,RIGHT(UPPER(D),1),'') else token end d1 FROM CTE1
     SELECT m1.id,
           ( SELECT m2.D1 + ','
               FROM cte2 m2
              WHERE m2.id = m1.id
              ORDER BY id
                FOR XML PATH('') ) AS token
      FROM cte2 m1
     GROUP BY m1.id 
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • Daughter's iPod touch went through the washer. Do i need to take the back off somehow before I try putting it in rice?

    Daughter's iPod touch went through the washer. Do i need to take the back off somehow before I try putting it in rice?

    No. Just put it in rice as is.
    You may have success in getting it to boot after using the rice technique, but it will sincerely doubtfully never fully function again.

  • I continue to recieve the error message "Could not create key: Verify that you have sufficient access to that key" when I am try to down Akamai NetSession Interface that's needed to download the adobe photoshop elements 13 software that I purchased.

    I continue to receive the error message "Could not create key: Verify that you have sufficient access to that key" when I am try to down Akamai NetSession Interface that's needed to download the adobe Photoshop elements 13 software that I purchased.

    cancel the akamai download and download files 1 of 2 and 2 of 2 directly.  put both in the same directory and double click the exe to start installation.
    Downloadable installation files available:
    Suites and Programs:  CC 2014 | CC | CS6 | CS5.5 | CS5 | CS4, CS4 Web Standard | CS3
    Acrobat:  XI, X | 9,8 | 9 standard
    Premiere Elements:  13 | 12 | 11, 10 | 9, 8, 7 win | 8 mac | 7 mac
    Photoshop Elements:  13 |12 | 11, 10 | 9,8,7 win | 8 mac | 7 mac
    Lightroom:  5.7.1| 5 | 4 | 3
    Captivate:  8 | 7 | 6 | 5.5, 5
    Contribute:  CS5 | CS4, CS3
    FrameMaker:  12, 11, 10, 9, 8, 7.2
    Download and installation help for Adobe links
    Download and installation help for Prodesigntools links are listed on most linked pages.  They are critical; especially steps 1, 2 and 3.  If you click a link that does not have those steps listed, open a second window using the Lightroom 3 link to see those 'Important Instructions'.

  • CWB-Need to change the eligible salary column from yearly to monthly

    Hi All,
    I need to change the eligible salary column from yearly to monthly at Employee Allocation from Compensation Workbench.
    Kindly help me guys
    Regards,
    Sajid

    You can change the activity reference period in the Plan Form - > Not In Program tab from annually to monthly. However, it will impact all the calcuations as it will use monthly values for everything. Please be careful of this. I would suggest testing this (along with posting back the increases to ensure they are annual amounts) before proceeding with this.

  • Cannot take the password protection off from a blog

    Hi Everyone
    I cannot take the password protection off from a blog. I uncheck the password checkbox (In the inspector) save the site and then publish.
    When I visit the site in 3 different browsers the security user name and password protection still remains.
    Any ideas ?
    Thanks

    Thanks for your reply
    I have tried that, empty the caches history etc
    No luck
    Cheers

  • How to exclude STOs from GATP, when we need to ship the "Customer return" products from branch to Central DC?

    How to exclude STOs from GATP, when we need to ship the "Customer return" products from branch to Central DC?
    We have to set up a scenario for sending "Customer returned" products from branches to Central DC through STO. But we do not want GATP check for these STOs, as they are Customer Returns, which need to analyze at CDC for further actions. We are using SCM 7.0 and ECC 6.0
    Thanks in advance,
    Ravi

    Hi,
    You can exclude the "customer returned" category from the scope of check from that particular Check control

  • Can I take the old hard drive from a Mac Pro G5 and put it into a Mac Pro Dual Xeon?

    Hello,
    I have an old Mac Pro G5 that still runs fine but the video card is bad so you can't see anything. Can I take the hard drive out of the G5 and put it into the Mac Pro Xeon without losing the data on it?
    Thanks!

    jenniferfromescanaba wrote:
    Even if I go from the hard drive on the G5 to the next generation up from the G5 and put in that hard drive into that next generation up from the G5? Isn't the mounting nearly the same?
    The storage bays are physically different from those in a G5. G5's had two bays in ther upper reat of the chassis, the Mac Pros have four slots running front-to-rear two thirds of the way up the chassis.
    But as The Hatter says, you can use the G5 drives but may need to "manage" the data transfers.

  • How can i sort out the N lowiest elements from an 1D array faster than using the build in sort function (1D-array) in Labview?

    I need an algorithm that is based on the same sorting-algorithm that Labview uses (or one that is just as fast) but it only needs to sort out the N lowiest elements (and the N-element output array don't need to be sorted).
    /Jonas

    I want all three zeros in the output. You can se the algorithm that I'm looking for as a soft version of Labviews own sort algorithm that only gives you the N (always less then the length of the array) lowiest values as output.If two elements contain the same small value both should be sorted out.
    /Jonas

  • Need to Remove the tabs group Title from browser window title

    When I use a saved tab group, which means I named that tab group in FF 5,''' the name of the tab group appears at the top of the browser along with the title of the web page I am viewing'''. Not good, I need to remove that tab group title from the browser window title, so I am only seeing the title of the webpage, and nothing from the tab group. How do I do that?
    thanks
    JSC

    You can add the site to the Pop-up Blocker Exceptions list in Options > Content > Block Pop-up Windows > Exceptions
    *See --> [https://support.mozilla.com/en-US/kb/Pop-up%20blocker#w_pop-up-blocker-settings Pop-up blocker-Pop-up blocker settings]
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''
    Not related to your question, but...
    You need to update some plug-ins:
    *Plug-in check: https://www-trunk.stage.mozilla.com/en-US/plugincheck/
    *Adobe PDF Plug-In For Firefox and Netscape: [https://support.mozilla.com/en-US/kb/Using%20the%20Adobe%20Reader%20plugin%20with%20Firefox#w_installing-and-updating-adobe-reader Installing/Updating Adobe Reader in Firefox]
    *Shockwave Flash (Adobe Flash or Flash): [https://support.mozilla.com/en-US/kb/Managing%20the%20Flash%20plugin#w_updating-flash Updating Flash in Firefox]
    *Next Generation Java Plug-in for Mozilla browsers: [https://support.mozilla.com/en-US/kb/Using%20the%20Java%20plugin%20with%20Firefox#w_installing-or-updating-java Installing or Updating Java in Firefox]

  • TS4148 I need to change the mobile data network from Vodafone to orange I need the passwords and address to do it my self

    I'm trying to find out the mobile data network info on my iPhone 3GS it's on Vodafone at the moment but I want to use my orange sim so I need to change the pan details help

    Assumption ...you are in UK
    If you purchased the iPhone from Vodafone it will be locked to them
    You will need to request they unlock the iPhone before you can use
    it on Orange no other way
    In UK  Apple are the ONLY source of unlocked new  iPhones

Maybe you are looking for