How can I do the CNiReal64Vector as a global variable?

My problem is with the CNiReal64Vector. Ive tried to define this vector as a global variable in the header file:
public:
NI::CNiReal64Vector plotData(50);
but the debuger flushed error : Syntax error ´constant´.
Of course,  I used usually square brackets:
 public:
double plotData[50];
Is it possible define the array of CNiReal64Vector as a global variable?
Thank You.
Best Regards
Emta

In the header (.h) file, declare the variable like this:
extern NI::CNiReal64Vector plotData;
In a source (.cpp) file, define the variable like this:
NI::CNiReal64Vector plotData(50);
This will cause the compiler to generate a single instance of the plotData global variable and a call to the CNiReal64Vector constructor that takes an integer that specifies the initial size. I believe that this is what you are trying to do.

Similar Messages

  • How can I decouple the pagination for a global region?

    I was having a delightful time using a common region defined on a global page when I determined that pagination setting was begin carried from one page to the next.  Arghhhh!  So for example, if I have paged to the second set (page) of rows (11-20) on Page 1 and then I go to Page 2, the second set (page) of rows (11-20) is displayed there.   If I go to a page which only has a first set of rows (1-10), I get the pagination error "Invalid set of rows requested, the source data of the report has been modified. Reset Pagination".  And when I click to reset, it just repeats the error.  [I suppose it tries to display the second set or rows (11-20) again -- which doesn't exist.  What's that saying about insanity?]  
    How can I decouple the pagination for a global region? I want it to operarate just as it would if it were not sharing a common region.  So if I'm looking at rows (11-20) on page 1, I can go to any other page beginning with rows 1-10 there.  Then return to page 1 where I left off with rows 11-20 displayed.  One solution is NOT to paginate but that's not my preferred solution.
    Howard

    Howard(...inTraining) wrote:
    I was having a delightful time using a common region defined on a global page when I determined that pagination setting was begin carried from one page to the next.  Arghhhh!  So for example, if I have paged to the second set (page) of rows (11-20) on Page 1 and then I go to Page 2, the second set (page) of rows (11-20) is displayed there.   If I go to a page which only has a first set of rows (1-10), I get the pagination error "Invalid set of rows requested, the source data of the report has been modified. Reset Pagination".
    The fact that there are different numbers of rows returned on different pages implies that the reports have some local page dependencies, so why try to use a global component? What's the actual requirement? How many pages does the report have to appear on? (Please say it is a report and not a tabular form...)
    How can I decouple the pagination for a global region? I want it to operarate just as it would if it were not sharing a common region.
    The point is that a global region is just that: a single region that happens to be displayed on multiple pages. It does not create multiple instances of a region on different pages. (Specifically, a region has a single region ID, and this is used to reference it whether it appears on one page or all of them. The region ID is used by the report for the purposes of AJAX refresh, pagination etc.)
    A similar situation was discussed a long time ago. I'm rather surprised that Scott regarded it as a bug: the fact that it doesn't seem to have been "fixed" or have a bug number attached may indicate that the others on the APEX team disagreed with him? I haven't tried the workaround he suggested, however I don't think it's likely to be prove a useful line of attack for your issue, as (1) it resets pagination rather than preserving it; and (2) it doesn't appear to be compatible with the AJAX PPR pagination used in more recent versions of APEX.
    I can't see any straightforward "solution" (largely because I don't think there's really a problem: the exhibited behaviour is exactly how I expect/want global regions to behave). Pagination processing is undocumented. The current 4.2 apex.widget.report.paginate JS method is specifically annotated as "for internal use only". Search the forum for custom pagination techniques. Messy looking hacks for IRs have previously been suggested.
    So if I'm looking at rows (11-20) on page 1, I can go to any other page beginning with rows 1-10 there.  Then return to page 1 where I left off with rows 11-20 displayed.  One solution is NOT to paginate but that's not my preferred solution.
    Assuming that there aren't too many pages involved, the other obvious option is to create unique regions on the required pages. You can achieve some level of reusability by creating SQL Query (PL/SQL function body returning SQL query) reports based on an external function so that there's only a single SQL source to be maintained.
    Explain the requirement in more detail. Pagination is not the only option for reducing the quantity of displayed information. Often it's better to display some of all of the data, rather than all of some of it...

  • Can I Access the Value of a Global Variable in a Trigger

    I'm using a Global variable in a Package which i use in the BIU Trigger to populate a column. After assigning the value for that global variable, I run an INSERT in the same package. But I find only the default value of the Global variable populated in the column. Can I use a Global Variable in a Trigger? Is there any way to put in a common value across all the tables in an application for all DMLs of a particular session?

    Helios,
    I'm already having the same setup mentioned in the thread. And I'm doing exactly whats given there. But the issue seems to be something different. I'm assigning the value to the Global Variable in the Package through Apex. Here's the Package Code:
    CREATE OR REPLACE PACKAGE Schema1.SPMS_SECURITY_PKG
    AS
    X_app_user_id NUMBER DEFAULT -1;
    FUNCTION USER_ID RETURN NUMBER;
    END SPMS_SECURITY_PKG;
    CREATE OR REPLACE PACKAGE BODY Schema1.spms_security_pkg
    AS
    FUNCTION user_id
    RETURN NUMBER
    IS
    BEGIN
    -- RAISE_APPLICATION_ERROR(-20001,'USER ID'||'*'||X_app_user_id);
    RETURN NVL (x_app_user_id, -1);
    -- RETURN NVL (sys_context('USERENV', 'CURRENT_USER'), -1);
    EXCEPTION
    WHEN OTHERS
    THEN
    RETURN -1;
    END;
    And Here is the Trigger Code:
    CREATE OR REPLACE TRIGGER Schema1."USER_DETAILS_TRIGGER"
    BEFORE INSERT OR UPDATE
    ON PMS_SICAL.SPMS_USER_DETAILS REFERENCING NEW AS NEW OLD AS OLD
    FOR EACH ROW
    BEGIN
    IF INSERTING
    THEN
    :NEW.created_by := spms_security_pkg.user_id;
    :NEW.created_date := SYSDATE;
    :NEW.START_DATE := SYSDATE;
    ELSIF UPDATING
    THEN
    :NEW.updated_by := SPMS_SECURITY_PKG.X_app_user_id;--spms_security_pkg.user_id;
    :NEW.updated_date := SYSDATE;
    END IF;
    END;
    But I always get -1 in the both in the table after the DMLs.

  • How can I programmatically create and use a global variable?

    I have an app where the number of AI DAQmx tasks I create are specified in a config file.  I have a monitor task that periodically looks at the latest values from all DAQ tasks.  I've been doing this with a set of global variables because it was the simplest way to do it.  But to do this, I have to explicitly create a separate AI task that uses the hard-coded global variable name for the DAQmx samples.  I would prefer to only write one VI for the DAQ loop that writes to a global variable that I programmatically create based on the config file.  The only solution I can think of is to use a global variable "pool" that is sized bigger than I expect to need, and then have a big switch case to select which one I want based on the task index.  But this sounds pretty silly.

    I tend to agree with Ben. I don't buy the concept of taking the asy way out (globals) because it very rarely will things remain static. You almost always have to extend the features and functionality of an application and then you will run into issues with sloppy and lazy implementations. The solutions offered may require a little time to learn but once you do it doesn't really require any extra effort.
    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

  • How can I obtain a reference to a global variable?

    I wish to change the contents of the columns in a global multicolumn listbox. As far as I can see, the only way to access the columns in a multicolumn listbox is to create a reference to it and access the ItemNames property. But how can I create a reference to a to a global variable?

    You can open a reference to a global as if it is a normal VI and then get a reference to a control on that VI. I have included a little VI here with a test global variable to get the item names from an MCL in that global. I needed the MCL in the main program just to force the reference to a strict MCL reference. You could turn this into a sub VI that just returns the item names of a named MCL if that works better (then the MCL that's only used for reference would not be on your main front panel).
    This VI searches through all the names of the controls on the referenced VI until it finds the one that's asked for.
    Have fun with it.
    Rob
    Attachments:
    Get_Ref_to_MCL_in_Global.zip ‏158 KB

  • How can i implement the default value for this variable?

    In one of our Stored procs,we have a variable RECS_TO_DELETE, which determines the number of records to delete from various DELETEs that happen within this proc.
    The value for RECS_TO_DELETE variable should be obtained from a configuration table sys_config
    select
    rec_num into RECS_TO_DELETE
    from sys_config
    where
    sys_code=55;
    But if something goes wrong with sys_config table or the above SELECT INTO, our client wants to makes sure that RECS_TO_DELETE should have a default value of 1000.
    In the code, how will i implement having this default value of 1000 for RECS_TO_DELETE variable  in case the above SELECT INTO fails for some reason.

    Hi,
    You have to assign a value before the execution...
    DECLARE
        RECS_TO_DELETE NUMBER(9) := 1000;
    BEGIN
        SELECT rec_num
        INTO   RECS_TO_DELETE
        FROM   sys_config
        WHERE  sys_code = 55;
        DBMS_OUTPUT.put_line(RECS_TO_DELETE);
    EXCEPTION
        WHEN NO_DATA_FOUND THEN
           DBMS_OUTPUT.put_line(RECS_TO_DELETE);
    END;
    /Regards,

  • How can i transfer the system variable value through DTW in SBO

    Hi,
    I want to transfer the system variable("Excisable" in the Item master data in the SBO 'India' database) value through the template by the DTW.
    But i don't have any template consisting of this system variable.
    So please suggest me that how can i transfer the value of this system variable(Excisable) and by which template.Please tell me any constraint if it is on the value of this variable.
    I will be very thankful to you.
    Thanks & Regard,
    Sandeep
    Message was edited by:
            Marc Riar

    Sandeep,
    This question has come up several times on this Forum.
    Please read this read.
    Importing excisable item
    Suda

  • I am having macbook air recently my iphotos did not open and was showing report apple and reopen but i came to know that by pressing alt and iphotos i open an new photo library and stored the pics but now how can i get the pics which i had in the earlier

    i am having macbook air recently my iphotos did not open and was showing report apple and reopen but i came to know that by pressing alt and iphotos i open an new photo library and stored the pics but now how can i get the pics which i had in the earlier photo please help me to recover my photos

    Well I'll guess you're using iPhoto 11:
    Option 1
    Back Up and try rebuild the library: hold down the command and option (or alt) keys while launching iPhoto. Use the resulting dialogue to rebuild. Choose to Repair Database. If that doesn't help, then try again, this time using Rebuild Database.
    If that fails:
    Option 2
    Download iPhoto Library Manager and use its rebuild function. (In early versions of Library Manager it's the File -> Rebuild command. In later versions it's under the Library menu.)
    This will create an entirely new library. It will then copy (or try to) your photos and all the associated metadata and versions to this new Library, and arrange it as close as it can to what you had in the damaged Library. It does this based on information it finds in the iPhoto sharing mechanism - but that means that things not shared won't be there, so no slideshows, books or calendars, for instance - but it should get all your events, albums and keywords, faces and places back.
    Because this process creates an entirely new library and leaves your old one untouched, it is non-destructive, and if you're not happy with the results you can simply return to your old one.  
    Regards
    TD

  • How can i get the all values from the Property file to Hashtable?

    how can i get the all values from the Property file to Hashtable?
    ok,consider my property file name is pro.PROPERTIES
    and it contain
    8326=sun developer
    4306=sun java developer
    3943=java developer
    how can i get the all keys & values from the pro.PROPERTIES to hashtable
    plz help guys..............

    The Properties class is already a subclass of Hashtable. So if you have a Properties object, you already have a Hashtable. So all you need to do is the first part of that:Properties props = new Properties();
    InputStream is = new FileInputStream("tivoli.properties");
    props.load(is);

  • How can I change the display of Inbox in my iPad's mail app- so that it takes up the full screen?

    How can I change the display of Inbox in my iPad's mail app- so that it takes up the whole screen, as opposed to just about one third; the other two thirds display the full text of the selected email?

    You can't change the display in the Mail app, if you are holding the iPad in landscape orientation then the left-hand third will be for navigation, and the right-hand two-thirds will be an email. If you hold the iPad in portrait orientation then the navigation section becomes a drop-down section.

  • I have gmail and hotmail account on my macbook. In gmail I can visualize all the mailboxes but in hotmail i only can see the inbox ¿how can I visualize the rest of the mailboxes? thanks

    I have gmail and hotmail account on my macbook.
    In gmail I can visualize all the mailboxes but in hotmail i only can see the inbox ¿how can I visualize the rest of the mailboxes?
    I have the same problem with my ipad; the solution would be the same?
    thanks

    Hello Sophie59
    You should be able to see two different tabs when setting up the email if you go to Other > Add Mail Account. Once you enter in the email address and password, you should be at the next screen to provide more details about the email as far as incoming and outgoing servers and at the top there will be a blue section to add it in as a POP or IMAP email account. Check out the article below for further troubleshooting and emails setup options.
    iOS: Troubleshooting Mail
    http://support.apple.com/kb/ts3899
    iOS: Adding an email account
    http://support.apple.com/kb/ht4810
    Regards,
    -Norm G.

  • How can i display the result of java class in InputText ?

    Hi all,
    How can i get the result of java class to InputText Or OutputText ???
    also can every one in the forum give me road map for dealing with java in oracle adf because i'm beginner in oracle adf
    i saw some samples in oracle adf corner but it's difficult for me.

    User,
    Always mention your JDev version, technologies used and clear usecase description (read through this announcement : https://forums.oracle.com/forums/ann.jspa?annID=56)
    How can i get the result of java class to InputText Or OutputText ???Can you elaborate on your requirement? Do you mean the return value of a method in a class as output text? Or an attribute in your class (bean?) as text field?
    -Arun

  • I have three different ipods with music on them and have had to replace our computer as it was in a fire. How can we combine the ipods into one ipod.

    We had to replace our computer due to a fire and lost many of the fiels which were on them. Many were music files for the ipods, we have thre. Also, do not have ID's and passwords to the iTunes store.
    How can we combine the information so that they are all in each one or at least compbine everything into one ipod?

    Just so you know the method suggested by Nelsonleee will cost your $29.95 USD, Yamipod is free.

  • How can I stop the sharing on the iPhones that are in the same account because its sharing every thing even text messages

    How can I stop the sharing on the iPhones that are on my account because its sharing everything even text messages and its driving everybody crazy

    An icloud account is designed to be used by one user to keep his/her devices in sync. 
    If you have muitiple family members or friends using the same account as yours, then have them get their own Apple IDs and icloud accounts.
    If you mean you want to stop the sharing between all your devices, then on any one device, go to Settings>icloud and turn off the services you don't want that device to share/sync.  Or turn off icloud altogether if that's what you want.

  • How can I move the ODI Work Repository from one server to another server?

    How can I move the ODI Work Repository from one server to another server?

    Hi,
    If you would like to move your source models, target models and project contents from Work repository 1 to another work repository.
    I.e. Dev. server to Prod Server.
    1. Firstly, replicate the master repository connections i.e. with same naming conventions manually
    2. Go to Dev. Server work repository -> File Tab -> Click on Export work repository (save it in a folder)
    3. After exporting, you can view the xml files in the folders.
    4. Now, Open the Prod. server and make sure you already replicated mas. rep. details.
    5. Now, right click on model and import source model in synonym mode insert_update (select source model from the folder where your xml file located)
    6. Similarily, import again target then Project.
    Now, check. It should work.
    Thank you.

Maybe you are looking for