How do I programmatically determine the cursor legend refnum?

I am determining the controls and such of a front panel programmatically as I have a need to be able to modify panels quickly without the manual editing necessary. I need to know how to determine the refnum of a cursor legend for a waveform or XY graph in a programmatic fashion rather than by creating a reference node.

That is a good question. The cursor legend reference is not returned if you get a list of all the object references. The graph is, so you can get its reference and get the cursor legend reference from it. You probably only need to look at the ones with a visible property set to true.
Bob Young - Test Engineer - Lapsed Certified LabVIEW Developer
DISTek Integration, Inc. - NI Alliance Member
mailto:[email protected]

Similar Messages

  • How do I programmatically change the plot legend names on my xy graph?

    I have a need to change the names/labels on my XY Graph's Legend at run time.  This is because plot 0 is not always the same set of data.  I have searched high and low for a couple days now to no avail.  The closest thing I've seen is overlaying a string over the plot legend, but I would prefer to do change the property of this box.  Any help would be appreciated.

    Hello Ben,
    with waveforms this also works for me fine. So where is the pitfall? (if always all works fine, one don't really gets experience)
    greets, Dave
    P.S. @ J.B. I used the Code Capture Tool from the Starware Thread, this made me so fast. If I could do, I would give it five stars each time I use it.
    Btw. would it be possible to programmatically give ratings with LV? Here it should be used. Thanks again to tst & the others
    Message Edited by daveTW on 06-14-2007 09:13 AM
    Greets, Dave
    Attachments:
    Example_FP.png ‏5 KB

  • How can I programmatically determine the capabilities of a card under NI-DAQmx (e.g. max sample rate, number of AI/AO/CTR channels, etc.

    Is there a DAQ_Get_Device_Info() equivalent for NIDAQmx? I need to iterate thru all the devices on my system, and build up a list of device capabilities. The system may include M-series and E-series cards.

    Attached is a program I've used in the past to determine number of AI channels. It could be easily modified to check for AO or digital or counter. Also, there is a ton of properties that you have access to (i.e. max sample rate, max/min voltage inputs, etc.) that are accessed as properties of the type of channel, or timing properties, as opposed to properties of the board. Check out the DAQmx C Reference Help (Usually at Start>>All Programs>>National Instruments>>NI-DAQ). Expand the NI-DAQmx C Properties, and look at the List of Channel Properties, and Timing Properties, etc.
    -Alan A.
    Attachments:
    Device_Info.vi ‏25 KB

  • How do I programmatically reference the current page in 902?

    Hello,
    How do I programmatically reference the current page in 902?
    The Portal Smart Text option for Current Page is not flexible enough, and I wish to create my own custom greeting using PL/SQL.
    Cheers,
    John

    hi,
    If you are developing a PLSQL Portlet, then you do have a way for getting the page URL.
    The page URL can be obtained from the record, portlet_runtime_record. There is a filed page_urlavailable with portlet_runtime_record.
    The portlet_runtime_record is passed as a argument to the show_portlet procedure.
    --Sriram                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How can I make that the cursor of a table ...

    Hello,
    how can I make that the cursor of a table (on the frontpanel) go to the starting position? I have placed a table that give back the number of the row if I doubleclick a row on the frontpanel, but when I restart the vi the cursor of the table is on this position. If I have many informations in the table and after restarting there are just one or two, I can`t see this information without scrolling to the top of the table. I want that the cursor (that I see) is at the first row. How can I make it?
    thankyou
    Schwede

    Hello,
    Sorry, I forgot to attach it in the previous post.
    Regards,
    Paulo
    Attachments:
    EditPos.vi ‏16 KB

  • Position Cursor on GRAPH either by dragging it OR entering the dsired position in the Cursor legend

    I've written a VI that allows the user to import a dataset, view it on a graph, and then use cursors to "filter" the range of data that I'm interested in, by sending the cursor.index values from the first graph to an array subset function which feeds a second graph.  The problem is that I'd like to provide the user the ability to position the cursors on the first graph both visually - by dragging - (for "course" control) AND by entering the desired values directly into the cursor legend (for fine control).  The problem is that I cannot find a way to do this, since I have to have the Lock Ring set to “Lock to Plot” in order to capture the index information. According to the documentation, the only way to be able to position the cursors via the Cursor legend is to set the Lock Ring to “Free”, which means the index values are rendered useless, since the cursor is no longer locked to the plot.  If I leave the Lock Ring in "Lock to Plot", and enter a value in the cursor legend, it does move the cursor, but not to where it should.  If I enter a value an x value of 9.0 for cursor 1, the cursor goes to 10.2638.  The next time I enter 9.0, it goes to 9.82794.  I don't understand what the issue is.  Is there a way around this?
    Attachments:
    ppv data filter 3.vi ‏366 KB

    Yes Rudi:  What I want is for the operator to place the cursors by dragging them (just eye-balling it).  The, if they see that the Y cursor (horizontal) is at 10.234, and they want to make it 10, they could simply enter that value in the cursor legend, and the cursor would be placed exactly at 10.  The only way to do this seems to be to select the “Free” option for the cursor.  However, in order to use the first graph to set the boundaries of the second graph, I have to use the Cursor Index from the first as an input to the Array Subset that feeds the second graph.  In order to use the Cursor Index, the first graph has to have its cursor Lock Rings set to “Lock to Plot”.  Am I making this any more understandable, or just rambling?

  • How do we programmatically "enable" the Page to have

    Some body known how do we programmatically "enable" the Page to have
    Item level security. - analogous to checking the box in the Page edit mode for "Enable item level security"
    J.

    Try this. It might work for you.
    declare
         l_page portal.wwsbr_api.page_record;
    begin
         select * into l_page
         from portal.wwv_user_owned_corners
         where siteid = <page group id>
         and id =<page id>;
         -- 0 is disabled . 1 is enabled.
         l_page.haveitemsecurity := 1;
         portal.wwsbr_api.modify_folder(
                   p_page => l_page
         wwpro_api_invalidation.execute_cache_invalidation;
         commit;
    end;
    regards
    Suresh.

  • How can a servlet determine the exact requesting URL

    This seems like a simple question, but I cannot find a solution. I am wondering how a servlet can determine the exact requesting URL that invoked the servlet. Specifically, I am having trouble making my servlet determine if the port number was specified or not. I am using session tracking, and my web server (by default) produces two separate sessions when hitting https://myserver.com/myservlet and https://myserver.com:443/myservlet.
    I have tried to use the HttpUtils.getRequestURL(), but this function seems to assume that if you used https over port 443, that you DID NOT specify 443 in the URL.
    SV

    If your servlet container implements servlet 2.2 or better, try the request.getRequestURL() method. It should return everything that was originally entered for the request address at the client except the query string (use request.getQueryString() to get that).
    I am not sure how it handles the port number for specifically entered vs not specifically entered.

  • How to determine the cursor record count before the "open cursor"?

    Is it possible to determine the record count of an explicit cursor without running a count()? Say, my cursor definition is something like this,
    CURSOR cur_vehicle
    IS
    SELECT os.order_id, os.order_item, vs.part_id
    vs.part_num,
    vs.iso_num,
    vs.model_yr
    vs.dealer_cde,
    vs.cust_cde,
    px.plant_cd
    FROM parts_source vs,
    orders_source os,
    plant_tbl_crossref px
    wHERE os.order_id = vs.order_id
    AND vs.part_id = os.part_id
    AND vs.plant_cde = px.plant_cde
    ORDER BY os.order_id;
    I want to log the count of records returned by the above cursor prior to the first fetch, without running a count(1) for the query in cursor select.
    I know adding " Count(1) over(order by null) " in the cursor SELECT will bring it. But that does not help me log the record count to some log file or table before opening the cursor for processing.
    To conclude, my objective is to update the record count of cursor in some table before processing

    sarvan wrote:
    Is it possible to determine the record count of an explicit cursor without running a count()?
    ..snipped..No. The only way to do it correctly is inside that select.
    Each select is a consistent read. Which means that if this is done as 2 select statements, the 1st select can see a different version of the data than the 2nd select statement. does. So if you want a count and that to be consistent and on the same version of the data than the select, it has to be done as part of the select.
    Also consider what a cursor is. It is not a result set of sorts that is created in memory upfront - with a convenient interface that tells you the size/number of rows of that result set.
    A cursor is basically a program that reads database data as input and produce output. A fetch from a cursor is an instruction for this program to execute and output data.
    There's no data set that is created by the cursor from which the count can be determined. The cursor program does have state variables - like +%RowCount+ that specifies how many rows the cursor has thus far output. And you need to run that cursor to the end (no more output) in order to determine the total number of rows output by the cursor.

  • How to programmatically move the cursor to the "To" field of a new AppointmentItem?

    I need to move the cursor to the "To" field of all new AppointmentItems which are created through my Outlook Addin. How I can achieve this?
    Thanks in advance.
    Thanks Prasad

    Hello Prasad,
    The Outlook object model doesn't provide anything for that. You need to use Windows API functions or use
    Accessibility API to set the cursor programmatically.

  • How do i programmatically get the current version of a file?

    I asked this same question in the SP2013 forum and I haven't been able to determine the solution. So I posting this here, to maybe get more eyes on this issue. 
    ...I am basically trying to programmatically get the current version of a document in a library, then determine if its a major or minor version, in code. I have tried doing this, to get the current version but I keep getting an empty string returned.
    var versions = item.File.Versions;
    string currentVersion = string.Empty;
    foreach (SPListItemVersion version in item.Versions)
    DateTime lastMod = version.Created;
    foreach (SPFileVersion fileVersion in versions)
    if (fileVersion.IsCurrentVersion == true)
    currentVersion = fileVersion.ToString();
    Does anyone know what am doing wrong, and how to get this resolved? I really appreciate the help. Thanks

    Why not just get the SPListItem and look at it's Version property? That'll be the latest version.
    No need to go into the Versions collection etc. When you get a list item you get the current version as standard.
    w: http://www.the-north.com/sharepoint | t: @JMcAllisterCH | YouTube: http://www.youtube.com/user/JamieMcAllisterMVP

  • Update plot name in the cursor legend

    Hi,
    I have a XY graph with its cursor legend set as visible.  The plot name changes based on the string that I sent to its property node, but I don't know how to update its cursor plot name?  Cursor is snapped to the plot, but the cursor plot name did not update.  Could anyone please help me?
    Thank you
    Solved!
    Go to Solution.
    Attachments:
    cursor.PNG ‏31 KB

    Here's a hint:  I found that if I toggle the Cursor.Cursor Mode from 0 to 1, then the cursor name changes. 
    "There is a God shaped vacuum in the heart of every man which cannot be filled by any created thing, but only by God, the Creator, made known through Jesus." - Blaise Pascal

  • How to remove entries from the plot legend?

    Hello,
    I have got a waveform graph to display measurement data. Sometimes there will be 40 plots shown. The plot legend also expands to 40 and I limit the number of elements shown in the Plot legend and I have activated the vertical scroll bar. Of course 40 plots are too many to work with. So the user has the ability to select plots to be shown. Now I want to decrease the number of elements in the plot legend as well. But if there were once 40 elements the plot legend remains in this size and the vertical scroll bar indicates that there are more elements than shown even if there are only e. g. two plots in the graph.
    I don't want to increase and decrease the number of plots shown in the plot legend programmatically each time the user changes the number of plots shown. Secondly the plot legend shall have a maximum number of 20 elements (otherwise it would exceed my front panel). So I don't want to programmatically check whether to show the vertical scroll bar or not.
    The legend should look like a partially filled array with grayed out elements. 
    How do I do this? 
    Is there a simple way to clear the plot legend and remove all entries?
    Regards, Jörn

    Hi Suse,
    your example does not exactly solve my problem. I wanted the plot legend always to show 10 legend entries.
    But it helped me to find the solution: set LegNumRows to 10 and set LegPlotMin to the number of plots in the Graph (see attached example).
    One thing is still missing: setting the plot number currently at the top of the legend. If you run the attached example with 30 plots shown, scroll the legend down and run the VI once again with 3 plots shown then you will see no plots in the legend despite the fact that all could be shown. You need to move the scroll bar first to see the 3 elements.
    Best regards, Jörn
    Attachments:
    Graph_Plotanzeige.vi ‏12 KB

  • Event for a change in the cursor legend

    Hi!
    I need to recognize a change of the cursor properties by the user through the XY-Graph Cursor Legend! (i.e. changing cursor color)
    There seems to be no event for that in my event structure (although there is a event for changing the plot properties through the plot legend).
    I'm using LV2009SP1.
    Greets CtheR

    I need the recognize any change of the cursor props made by the user. Like that:
    Watching the cursor-Property for a change would be no help because there are automatic changes that I do not want to catch.
    Something similar to the plot attribute change event in an event structure would be most helpful:
    Greets CtheR

  • How can IC WebClient determine the host name for free seating?

    Hi,
    I want to determine the host name at CRM application server by ICI interface for free seating scenario.
    There is a TCODE CRMM_IC_GFS to set 'Host Name Identification Applet'.  But when I check on it, all buttions in IC Webclient disappeared. I followed the note 812399 to change Java security configuration, but the synptom still exist. Do anybody now how to? Thanks!
    BR,
    Hao

    To run a public VPN server, you need to do the following:
    1. Give the gateway either a static external address or a dynamic DNS name. The latter must be a DNS record on a public DNS registrar, not on the server itself. Also in the latter case, you must run a background process to keep the DNS record up to date when your IP address changes.
    2. Give the VPN server a static address on the local network.
    3. Forward external UDP ports 500, 1701, and 4500 (for L2TP) and TCP port 1723 (for PPTP) to the corresponding ports on the VPN server.
    4. Configure any firewall in use to pass this traffic.

Maybe you are looking for

  • Auto SO from PO- ALE IDoc

    Hi Friends, Someone provide me basic process flow and steps to automate creation of Sales Order in another Company Code when a Purchase Order is created in a separate Ccd with the help of IDocs. Eg: (PO saved in CCd-1100 triggering a SO in CCd-2200)

  • Can I put my iphone sim card into my ipad mini?

    Can I put my iphone sim card into my ipad mini?

  • Help me... my macbook was frozen

    I was using iMovie and it got frozen. I tried to quit the program but I couldn´t so I have to turn it off the old-fashion way with power button. It was this error: Interval Since Last Panic Report: 545773 sec Panics Since Last Report: 1 Anonymous UUI

  • Restricting a choice complex type

    Hello Everyone, We have this XSD that allows users to register other users on our system with XML requests. These users are known as viewers and they may register a preferred payment type for them. <xsd:element name="viewerInfo">           <xsd:compl

  • Generated analysis authorization cannot be changed

    Hello all, did someone manage to edit/delete generated (from DSO) analysis authorizations? When I want to correct a typo in one of the generated analysis authorizations it is not possible although the system is telling that it should be possible to d