Reference to C# objects in TestStand - how to save and retreive them

I am new to LabView and TestStand.
I want to use 2 .NET objects in those applications
In Labiew, I successfully created the objects, manipulate the functions through VIs and closed the references.
While I could use the VIs for TestStand, I would rather use the DLL directly.
I am able to create both objects in a sequence, but I have problems with the following:
  - I don't know how to save the reference to the object after the constructor is run.
    - is the object stored in Globlal variables? I tried 'RunState.Engine' but it does not work
  - I don't know how to get the reference back in the other steps where I want to reuse the object to invoke a method on.
  - Once I can do the above, I need to get it to work in the 'batch' or 'parallel' modes.
     I am using successfully the 'RunState.TestSockets.MyIndex' to select my testing resources,
     but I am still confuse as where the array of objects would be.
     Note that I already set the number of DUT <> 1 and I can create successfully my 2 objects in X instances.
Thanks,
Daniel Coupal

dcoupal,
Getting the reference to the object involves specifying that as a return value in one of your parameters when you specify the module for that action. Inside of the parameters table you can also save that return value as a local object reference and then use it later on in the sequence.
Regarding your second question, I'm not sure what the array of objects is that you're referring to but this KB might be of some assistance.
Message Edited by Jon M on 11-01-2006 12:44 PM
Test Engineer - CTA

Similar Messages

  • How to save and  move an application

    Hi,
    I have made an application on Oracle Express. How to save and move that to another machine ?
    Many thanks.

    I'm in the process of porting my XE app to a 10.1 instance.
    I created an app export and export file of the schema. Then I installed a client on the same machine so I could connect and I get errors detailed in the end of this thread when attempting to import. Most of the tables are successful however, none of the procedural code goes in. The app export imported fine.
    Now, I can manually copy the objects that remain but only if I can connect to XE and this ability seems to have been lost with the install of the 10.1 client.
    Does anyone know how I can connect to XE using PLSQL Developer or is it indeed possible to connect to XE on a machine that is configured to also connect to a 10.1 remote server? I have installed the 10.1 client into a new Oracle home.
    . importing CODESPEED's objects into PRIMPATH
    IMP-00008: unrecognized statement in the export file:
    IMP-00017: following statement failed with ORACLE error 1950:
    "CREATE TABLE "FOLDER" ("FOLDER_ID" NUMBER NOT NULL ENABLE, "STAFF_ID_CREATE"
    "" NUMBER NOT NULL ENABLE, "STAFF_ID_MODIFY" NUMBER, "FOLDER_NAME" VARCHAR2("
    "100) NOT NULL ENABLE, "FOLDER_CREATED" DATE NOT NULL ENABLE, "FOLDER_MODIFI"
    "ED" DATE NOT NULL ENABLE, "FOLDER_NOTES" CLOB, "FOLDER_OWNER" NUMBER NOT NU"
    "LL ENABLE, "DRA_VERSION_ID" NUMBER, "ASSIGNED" NUMBER NOT NULL ENABLE, ""
    "UNASSIGNED" NUMBER NOT NULL ENABLE, "APPROVED" NUMBER NOT NULL ENABLE, "FOL"
    "DER_STATUS" VARCHAR2(1) NOT NULL ENABLE, "CODING_RULE_SET" NUMBER) PCTFREE"
    " 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 STORAGE(INITIAL 65536 FREELISTS 1 FR"
    "EELIST GROUPS 1 BUFFER_POOL DEFAULT) TABLESPACE "USERS" LOGGING NOCOMPRESS "
    "LOB ("FOLDER_NOTES") STORE AS (TABLESPACE "USERS" ENABLE STORAGE IN ROW CH"
    "UNK 8192 PCTVERSION 10 NOCACHE LOGGING STORAGE(INITIAL 65536 FREELISTS 1 F"
    "REELIST GROUPS 1 BUFFER_POOL DEFAULT))"
    IMP-00003: ORACLE error 1950 encountered
    ORA-01950: no privileges on tablespace 'USERS'
    IMP-00017: following statement failed with ORACLE error 2248:
    "ALTER SESSION SET PLSQL_OPTIMIZE_LEVEL = 2 NLS_LENGTH_SEMANTICS = 'BYTE' PL"
    "SQL_CODE_TYPE = 'INTERPRETED' PLSQL_DEBUG = TRUE PLSQL_WARNINGS = 'DISABLE:"
    "ALL'PLSQL_CCFLAGS = ''"
    IMP-00003: ORACLE error 2248 encountered
    ORA-02248: invalid option for ALTER SESSION
    IMP-00000: Import terminated unsuccessfully
    C:\Documents and Settings\PWin>

  • What are message tables and their role?How to create and access them ?

    hi,
    Can any body clarify me about What are messaging tables and their role(use) in DataBase?How to create and access them ?
    Thanks in advance
    Gopi

    If you have doubt that's you have an idea. So, explain your idea please, because I don't see what are "messaging tables".
    Did you say about Oracle database ? Apps ?...
    Nicolas.

  • Working with Chinese characters: How to paste and modify them as sentences; not as individual images?

    Working with Chinese characters: How to paste and modify them as sentences; not as individual images?
    From 2004, this is so far the most detailed answer I could find: http://en.allexperts.com/q/Adobe-Illustrator-1027/FONTS-display-problem-Adobe.htm, but is this really still the most up-to date solution?
    Is it possible at all to work with Chinese characters, if I don't have the Chinese version of Illustrator? (http://www.proz.com/forum/dtp_desktop_publishing/221125-chinese_in_indesign.html)

    Thanks for your reply.
    I'm using Version 17.1.0 (64-bit) - basically CS6.
    Operating system is Windows 8.1. Installed is the simplied Chinese language package.
    I have received the text in a Word document. It contains mixed characters, something like this:
    教授资料
    学术背景:
      博士;曾于波恩大学(Rheinische Friedrich-Wilhelms-Universität Bonn)、台湾师范大学、
    I have tried to paste it in the two following ways:
    1) to create a text box and paste the text. The result is that some of the characters are not showed correctly.
    2) Paste it directly without any preparation. This result into a single "image" or group of images. I can cancel modify each character one at a time, or I can dissolve the group, but the result is the same.

  • How to save and edit a Word template and excel??

    How to save and edit a Word template and excel (extension. doc and. xls) in an XE database, which can be opened to allow the document and record all changes made by the user of the palicacion.
      or where it a clear tutorial on this topic.?
    I appreciate your attention and collaboration.
    good day ...

    You should not expect to do this in Oracle. But by .net, it can be fine
    http://www.codeproject.com/Articles/36432/Edit-Microsoft-Word-Document-From-Your-Application

  • Built-in SSH Terminal question on how to save and exit

    Howdy, Heres my question and problem.
    I haven't been able to figure out how to save and exit the editor for the SSH terminal that the mac has. I've read that to save you press control -O hit return and to exit hit control -X but that doesn't seem to be working.
    I'm trying to install imagemagick onto my web server and I get stuck at that point of saving and then exiting.
    can anyone tell me how to save and exit the editor?
    I hold down control press -O i let go of the buttons then i press control -X and it stays at the same editor like nothing happened. I try quitting the terminal and reloading it all but that just causes me to restart and nothing saved. and I actually hit the "-" key should i do that or no?
    heres the instructions I'm following for the imagemagick install.
    (For this next part, if you don't have "pico", you can use "vi" instead)
    $ cd libtiff-lzw-compression-kit
    $ pico Makefile
    change
    TIFFSRCDIR = /tmp/libtiff
    to
    TIFFSRCDIR = ../tiff-v3.5.5
    Then save and exit the Editor $ make install
    $ cd ..
    $ cd tiff-v3.5.5
    $ ./configure
    thanks for any help
    -Ahufs

    ctrl+x (thats both keys at the same time) will invoke the exit of the program. at wich point if youve made changes to the file it will ask you if you want to save the data or not. If yes you need to type yes or y and hit enter... if no then no or n. Then it will ask you what you want the file name to be with the default being whatever the file was that you opend to buffer to work on so in most cases you hit enter again.
    hitting ctrl+o (thats both at the same time again) should write the file out and close the application without prompting i think (i dunno for sure... i always use ctrl+x myself).
    At least thats on the OS X version of pico... your server is probably linux so it may differ although i wouldnt expect it to. my pico bindings have always been the same from Debian to CentOS to Darwin.
    Also i msut ask... why cant you pass the TIFFSRCDIR as an option to ./configure like normal instead of manually editing the make file?

  • How to save and retrieve an excel file as an object into lob column?

    Hi ,
    I need to save and retrieve the whole excel file with 3 or more sheets as an object into the lob column of table.
    For example:
    t_docments
    (doc_id number,
    excel_data clob
    All excel files need to be saved to excel_data column.
    What should I do?
    Thanks

    Did you check the asktom thread posted by Jens?
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P1
    1_QUESTION_ID:232814159006
    There's example of varies file types.Yes, I did try some examples.
    Those work for .doc/.pdf/.jpg files, BUT NOT for excel file.
    The following error happened when retrieving excel file(retrieving .doc/.pdf are OK)
    ORA-29285: file write error
    ORA-06512: at "SYS.UTL_FILE", line 18
    ORA-06512: at "SYS.UTL_FILE", line 375
    ORA-06512: at "SYS.UTL_FILE", line 990

  • WPF- How to save and retrieve details from database

    I want to develop an desktop app to save and retrieve details from database, but am having a little hitch
    am getting errors in my code, kindly advice below are the required code
    xaml
    <Grid>
            <TextBox HorizontalAlignment="Left" Height="23" Margin="144,28,0,0" TextWrapping="Wrap" x:Name="TbxId" VerticalAlignment="Top" Width="193"/>
            <TextBox HorizontalAlignment="Left" Height="23" Margin="144,134,0,0" TextWrapping="Wrap" x:Name="TbxFn" VerticalAlignment="Top" Width="193"/>
            <TextBox HorizontalAlignment="Left" Height="23" Margin="144,77,0,0" TextWrapping="Wrap" x:Name="TbxLn" VerticalAlignment="Top" Width="193"/>
            <Label Content="Student ID" HorizontalAlignment="Left" Margin="10,28,0,0" VerticalAlignment="Top" Width="101"/>
            <Label Content="Last Name" HorizontalAlignment="Left" Margin="10,134,0,0" VerticalAlignment="Top" Width="101"/>
            <Label Content="First Name" HorizontalAlignment="Left" Margin="10,77,0,0" VerticalAlignment="Top" Width="101"/>
            <Button x:Name="BtnSave" Content="Save" HorizontalAlignment="Left" Margin="23,206,0,0" VerticalAlignment="Top" Width="75" />
            <Button x:Name="BtnBrowse" Content="Browse" HorizontalAlignment="Left" Margin="149,206,0,0" VerticalAlignment="Top" Width="75" Click="Save"/>
            <Button x:Name="BtnShow" Content="Show" HorizontalAlignment="Left" Margin="294,206,0,0" VerticalAlignment="Top" Width="75"/>
            <WindowsFormsHost Grid.Column="0" Margin="448,28,75,243">
                <wf:PictureBox x:Name="pictureBox1" Height="150" Width="150" SizeMode="StretchImage"/>
            </WindowsFormsHost>
        </Grid>
    cs
    private void Browse(object sender, RoutedEventArgs e)
                SqlConnection cn = SqlConnection(global::DatabaseApp.Properties.Settings.Default.Database1ConnectionString);
                try
                    OpenFileDialog dlg = new OpenFileDialog();
                    dlg.Filter = "JPG Files (*.jpg)|*.jpg|GIF Files (*.gif)|*.gif|All Files(*.*)|*.*";
                    dlg.Title = "Select Student Picture";
                    if (dlg.ShowDialog() == DialogResult.OK)
                        imgLoc = dlg.FileName.ToString();
                        picStu.ImageLocation = imgLoc;
                catch(Exception ex)
                    System.Windows.MessageBox.Show(ex.Message);
    Thank you
    Jayjay john

    Hi Joakins,
    I think Lloyd has a point here in that all I see there which is really database related is a connection string.
    Maybe your question is more general though and you're just asking how to work with a database as a general principle.
    Personally, I like entity framework and would recommend that.
    You can read a shed load of stuff about it.
    https://msdn.microsoft.com/en-gb/data/ef.aspx?f=255&MSPPError=-2147217396
    With WPF almost every dev uses MVVM and I'm no exception.
    You may find this interesting:
    http://social.technet.microsoft.com/wiki/contents/articles/28209.wpf-entity-framework-mvvm-walk-through-1.aspx
    The article for the second in the series is only partly written, but the sample is complete:
    https://gallery.technet.microsoft.com/WPF-Entity-Framework-MVVM-78cdc204
    Hope that helps.
    Recent Technet articles: Property List Editing;
    Dynamic XAML

  • How to save and then close document Using Acrobat 9 (URGENT)

    I have been looking for a soultion for long time now but
    couldn't find any.
    I'm using a dynamic PDF form desgined using LC Desginer and created a button that should save the current opened form in the same location (no need to define the location because what I want to use is the command File -> Save) and then close the application (I'm using Acrobat 9 Pro Extended).
    I tried many scripts and gone throw JavaScript™ for Acrobat® API Reference but no luck.
    Once I click on the button I get the following error: NotAllowedError: Security settings prevent access to this property or method.
    Will you please help in this issue as it took long time and my project manager is pushing to get resolved ASAP.
    Guys, I'm new to this kind of tecnology so please be patient with me.
    Thanks in advance for your valuable help.
    The code I used in click event of the button is as follow:
    try{
         var myDoc = app.newDoc();
         myDoc.saveAs();
         myDoc.closeDoc(true);
    catch (e)
         xfa.host.messageBox(""+e);
    I used this earlier and got the same error:
    try{
          var myDoc = event.target;
         myDoc.saveAs();
    catch (e)
         xfa.host.messageBox(""+e);

    Hi Niall,
    function(){return A.apply(null,[this].concat($A(arguments)))}
    function(){return A.apply(null,[this].concat($A(arguments)))} 
    The app.execMenuItem works here. Is your form designed to be opened in Acrobat/Reader or are you opening the form in html?
    The form will be opened by Acrobat/Reader. The statement worked but what I need is to save the PDF in the current location without popping up the Save As dialog box. In other words I would like to perform Ctrl+Saction and then exit the application not only close the form because the Content Management Solution we are using will require the application to be closed so it can CheckIn the document.
    I tried to use app.execMenuItem("Save");  but it seems it is not working because once I try to close the application or the form using app.execMenuItem("Close"); the do you want to save changes to "FORM" before closing? dialog box pops-up.
    For closing the application I tried app.execMenuItem("Exit"); and I got this error: InvalidArgsError: Invalid arguments.
    function(){return A.apply(null,[this].concat($A(arguments)))}
    function(){return A.apply(null,[this].concat($A(arguments)))}Also you may want to consider how you are reader enabling the form. If you are using Acrobat to extend the form, then certain features like database connections will not work.
    The customer has Adobe LC Reader Extension so I will use it to extend the PDF but right now I do use Acrobat so I don't need to extend the PDF everytime I need to test it.
    Can I get all the arguments that execMenuItem uses?
    I really appreciate your help Niall.
    PS: I couldn't reply earlier yesterday because my work is on the server and I was at home (my time is +3 GMT it was night when I got your reply)
    Regards
    Mazen

  • How to save and then close a PDF Using Acrobat 9 (URGENT)

    I have been looking for a soultion for long time now but
    couldn't find any.
    I'm using a dynamic PDF form desgined using LC Desginer and created a button that should save the current opened form in the same location (no need to define the location because what I want to use is the command File -> Save) and then close the application (I'm using Acrobat 9 Pro Extended).
    I tried many scripts and gone throw JavaScript™ for Acrobat® API Reference but no luck.
    Once I click on the button I get the following error: NotAllowedError: Security settings prevent access to this property or method.
    Will you please help in this issue as it took long time and my project manager is pushing to get resolved ASAP.
    Guys, I'm new to this kind of tecnology so please be patient with me.
    Thanks in advance for your valuable help.
    The code I used in click event of the button is as follow:
         var myDoc = app.newDoc();
         myDoc.saveAs();
         myDoc.closeDoc(true);
    catch (e)
         xfa.host.messageBox(""+e);
    I used this earlier and got the same error:
    try{
          var myDoc = event.target;
         myDoc.saveAs();
    catch (e)
         xfa.host.messageBox(""+e);
    try{

    Hi Niall,
    function(){return A.apply(null,[this].concat($A(arguments)))}
    function(){return A.apply(null,[this].concat($A(arguments)))} 
    The app.execMenuItem works here. Is your form designed to be opened in Acrobat/Reader or are you opening the form in html?
    The form will be opened by Acrobat/Reader. The statement worked but what I need is to save the PDF in the current location without popping up the Save As dialog box. In other words I would like to perform Ctrl+Saction and then exit the application not only close the form because the Content Management Solution we are using will require the application to be closed so it can CheckIn the document.
    I tried to use app.execMenuItem("Save");  but it seems it is not working because once I try to close the application or the form using app.execMenuItem("Close"); the do you want to save changes to "FORM" before closing? dialog box pops-up.
    For closing the application I tried app.execMenuItem("Exit"); and I got this error: InvalidArgsError: Invalid arguments.
    function(){return A.apply(null,[this].concat($A(arguments)))}
    function(){return A.apply(null,[this].concat($A(arguments)))}Also you may want to consider how you are reader enabling the form. If you are using Acrobat to extend the form, then certain features like database connections will not work.
    The customer has Adobe LC Reader Extension so I will use it to extend the PDF but right now I do use Acrobat so I don't need to extend the PDF everytime I need to test it.
    Can I get all the arguments that execMenuItem uses?
    I really appreciate your help Niall.
    PS: I couldn't reply earlier yesterday because my work is on the server and I was at home (my time is +3 GMT it was night when I got your reply)
    Regards
    Mazen

  • How to SaveAS and SaveAs on different volume in TextEdit?

    i am having a bit of a battle with the new features for saving in Lion and while i /sort/ of get it i am not doing very well in TextEdit. wondering if someone wouldn't mind helping me out.
    i have created a new document and upon running the first Save (i think) i was giving an opportunity to put this document somewhere and to NAME it.
    NOW i would like to run a SaveAs so i can KEEP THE ORIGINAL but also edit a new version. I would also like to SAVE A BACKUP on my LAPTOP.
    in the past to do this i have run a SaveAs, edited and this new document (it was renamed in the SaveAs) and then i have re-opened the older document in order to continue editing it. alternatively, i have sometime COPIED and PASTED the contents of the existing doc into a NEW document and then Saved and named this document.
    1. How do i do this in TextEdit now? I see a Save Version (not applicable) and a Duplicate (doesn't /seem/ to do what i need since it automatically names this document with the same name and an appended "copy").
    2. I want to SAVE A COPY of my document on an external volume (my laptop). i see a "Export PDF" and again i see the Duplicate option but for some reason i don't see my laptop as a DESTINATION for either of these even though it appears to be mounted (little cutout people icon on the desktop).
    what am i missing here?

    thanks charlie.
    sort of a new world over here. newish mac user to boot. sort of interesting to go back and forth between my "old way" with photoshop products and then dive into a mac lion product and do this.
    in any event - i am /not/ seeing my /external/ volume when i try to save a duplicate or export a pdf.
    any idea (short of a bug) on why i am not seeing the Laptop as a shared location since it is mounted? this means i have to save to the macpro and then manually move it to the MBP.
    also, i guess export to PDF is the only option since if i am saving a txt i would use Duplicate...?

  • Save and Protect your iPad Device: How to Save and Prolong the battery life of your new ipad

    Please, as you read add more answers to this on how to prolong and save your ipad battery life. Thank you
    Saving the battery life of your iPad
    1.Keep Your iDevice Out of the Sun
    Whatever you do, don’t leave your iPhone or iPod sitting in a hot car—heat kills batteries faster than any other factor, and your device that used to keep a charge for hours will eventually barely hold a charge, and you’ll have to pay Apple to get it replaced. The same thing holds true for any really hot environment: try and store your device in a cool place.
    Reduce the Screen Brightness
    If you keep the screen at maximum brightness all the time, you’re wasting a lot of battery life—and the screens these days are so bright anyway that you don’t really need to, especially at night. Head into Settings -> Brightness & Wallpaper to adjust the default level of brightness, which you can probably keep as low as 30% most of the time.
    2. Make Sure the Screen Locks Quickly
    Even if you’ve adjusted the screen brightness, there’s still no substitute for having it turn off quickly when you’re not using it. Head into General -> Auto-Lock to set the screen lock to happen as quickly as your device will let you. This makes a big difference if you are always picking up your phone and putting it back into your pocket without turning the display off.
    3. Use Airplane Mode When You Don’t Need Internet (iPad/iPhone)
    If you’re busy spending the next 8 hours playing Angry Birds, there might not be a good reason to have internet access, so you can consider using Airplane Mode, which turns off both Wi-Fi and the regular wireless radio. Of course, this will prevent phone calls if you’re on an iPhone—but if you’re busy with Angry Birds you probably don’t want the interruption anyway.
    4. The more important reason to use Airplane Mode is when you’re mobile in an area with a really spotty connection—because the iPhone or iPad will try to stay connected at all times, it’s going to be constantly searching for a connection, which can drain your battery. Head into Settings and flip the Airplane Mode switch right up at the top of the screen.
    Use Wi-Fi Instead of 3G if Possible
    According to Apple, the iPad will get 10 hours of battery life under regular use with Wi-Fi enabled, but will only get 9 hours using 3G—the iPhone gets 6 for 3G and 10 for Wi-Fi. Of course, if you’re heavily using the Wi-Fi, you’ll still be draining the battery—the point is under similar workloads, Wi-Fi is better than 3G for battery life.
    You can enable Wi-Fi under Settings -> Wi-Fi, and then pick the network you’d like to connect to.
    5. Reduce or Eliminate Mail & Calendar Checking
    If you’ve got a bunch of email, calendar, or contact accounts configured, and they are all being checked and downloading email on a regular basis, you’ll be draining the battery an awful lot faster than you need to.
    Head into Settings -> Mail, Contacts, Calendars -> Fetch New Data and change the setting to the least frequent check possible. If you don’t use it often, you can just turn Push off entirely and then manually check when you need to.
    6. Reduce or Eliminate Push Notifications
    Do you really need notifications from Twitter or whatever other apps you’re running? You can turn these off one-by-one, or turn off Push entirely by heading into Settings -> Notifications, and save a bit of extra battery life since your device won’t be pulling in data for those applications anymore.
    7. Reduce or Eliminate System Sounds
    This one is probably a little silly, but if you really don’t care for the system sounds you can save a small amount of battery life by removing the sounds. A very, very small amount, most likely. Head into Settings -> General -> Sounds to change them.
    8. Disable Location Services
    If you don’t really need the location services, you can disable them to save some battery life. Head into Settings -> General and flip the Location Services setting to off.
    9. Disable Bluetooth If You Don’t Need It
    If you don’t use a Bluetooth headset or keyboard, you should keep the Bluetooth radio disabled to save some extra battery life. Head into Settings -> General -> Bluetooth to flip it on or off.
    10. Disable Vibrate Feature in Games
    If you’ve got a game that uses the vibrate feature, you can turn that off to save some battery life. This mostly matters if the game heavily uses it, and you’ll need to change the setting for the game. As a side note, and it should go without saying, if you’re running really intensive video games, they will kill your battery very quickly.
    11. Charge and Discharge Your Battery Regularly
    Your iDevice needs to be fully discharged and recharged at least once a month to operate at maximum efficiency and keep the battery from dying. You’ll also want to make sure that you don’t store the device with a dead battery, as that can also cause the battery to lose charge capability—when your battery dies, make sure to recharge it quickly.
    <Edited by Host>
    Irem Bright writes and would love your own addition if you got other helpful tips.
    Thank you all.

    11. Charge and Discharge Your Battery Regularly
    Your iDevice needs to be fully discharged and recharged at least once a month to operate at maximum efficiency and keep the battery from dying. You’ll also want to make sure that you don’t store the device with a dead battery, as that can also cause the battery to lose charge capability—when your battery dies, make sure to recharge itquickly
    The reason that Apple suggests you drain and recharge your battery once a month is not because it affects the life ofthe battery. What it actually does is calibrate the battery sensor, giving you a more accurate reading. 
    Other than that, you done an admirable job of summarizing the Knowledge Base article:
    http://www.apple.com/batteries/ipad.html
    Best of luck.

  • How to save and download json to make use of a app in offline mode

    how to download and save a json file from url to make use of a app in offline mode and if internet is available it should take data from url only and display it in tableview..but  for the second time it should make use of the saved json data to display the table view data in app.

    Hi,
    Using F calls a routine and not BAdI.
    If record will directly be created then there is no need to write Z program and calling it using F indicator. However, in case there is some logic which can not be written directly in the Dynamic Action then you need to write that logic in a routine and call it using F indicator.
    VK

  • How to save and open Text/csv file over APS

    Hi,
    I want to save(and open later) data from database block in text/csv file format over Application server, I did a lot of search here on Forms but didn't found a reasonable solution, Some one plz help me.
    Thanks and Regards, Khawar.

    As long as you are using the Report Generation Toolkit, there is no need to use ActiveX for the purpose of saving the Excel file -- Save Report will do that for you.  You can then export (as text) all of the Excel data and use the Write Spreadsheet File to make the .CSV file.  Here is how I would rewrite the final bits of your code --
    I cleaned up the wires around Excel Easy Table a bit.  You'll see I made a VI Icon for Replace Filename, which does (I think) a nicer job of self-documenting than showing its Label.  To make the filename, add the correct extension (.xlsx for Excel, .csv for CSV), use Build Path to combine Folder and Filename, and wire to Save Report.
    The next two functions add the Extract Everything and Write to Spreadsheet, using a Comma as a separator, which makes a CSV copy for you.
    Bob Schor

  • How to save and restore a Key?

    Hi,
    I Am working through some example code based on the Sun documentation here:
    http://java.sun.com/j2se/1.4/docs/guide/security/jce/JCERefGuide.html
    Here is part of the program:
            KeyGenerator keygen = KeyGenerator.getInstance("DES");
            SecretKey desKey = keygen.generateKey();
                Cipher desCipher;
            // Create the cipher
            desCipher = Cipher.getInstance("DES/ECB/PKCS5Padding");
            // Initialize the cipher for encryption
            desCipher.init(Cipher.ENCRYPT_MODE, desKey);
            // Our cleartext
            byte[] clearBytes =  "Joe".getBytes("UTF8");
            // Encrypt the cleartext
            byte[] cipherBytes = desCipher.doFinal(clearBytes);
            // Initialize the same cipher for decryption
            desCipher.init(Cipher.DECRYPT_MODE, desKey);
            // Decrypt the ciphertext
            byte[]  decryptedBytes = desCipher.doFinal(cipherBytes);This all works fine. Now, suppose I want to save desKey for future use. (Maybe I want to save my encrypted bytes to a file and decrypt them in the future. Maybe I want to give someone else the key for decrypting cipherBytes. )
    In the Key interface there is a method getEncoded() => byte[] which appears to be a way to save the key as a byte array for future use. However, I don't see how to restore the key from the byte array. That is, I expected a Key interface constructor something like: Key(bytes[], encodedKey). What am I misunderstanding?
    Regards,
    Joe

    >
    This works fine: SecretKey myKey = new SecretKeySpec(rawKey, "DES");
    And indeed it does. Thanks, mut - I learned something new today. (Of course, I feel stupid for not having ever noticed that SKSpec isA SecretKey - but that happens to me allll the time...)
    I couldn't get Grant's code to compile. Seems like
    the SecretKeyFactory class doesn't have a
    method named generateKey (in my 1.4 SDK).
    I replaced generateKey with
    generateSecret which compiled without error,Yup, sorry, I hadn't run the code thru a compiler or I'd've caught that.
    but then when I ran the code the third line threw an
    exception:
    java.security.spec.InvalidKeySpecException:
    Inappropriate key specification
    Any idea what's going on?Interesting. I don't offhand see any way for one to work and the other to fail with the same raw data. Then again, having been wrong twice in one post, I'm feeling abruptly unqualified to comment! ;)
    Will experiment some, and let you know what I find out.

Maybe you are looking for