Automated loading and executing array of presets sequentially

Hi,
I have built a system that allows a user to set certain parameters and send those parameters to another program using an event case.  In order to have my controls update in real time I had to use nested while loops.  The inner loop contains the controls which is halted by the event trigger that is housed in the larger while loop along with the inner while loop.  I have recently built functionality to be able to save and load preset files in order to make it easier to set these controls.  My end goal is to allow the user to load in multiple preset files sequentially and have those values pass through to the other program where the hardware I am using can utilize it.
The problem I am having is in figuring out how to automate this loading and execution of presets.  I can automate the loading of presets outside of the main VI, but due to the while loops I am confused on how to have only one preset be executed at a time.  Essentially, the pattern I am looking to create is to have a preset automatically load and then pass those control values on to the rest of the program.  Then the system will wait for a signal that the hardware has done its job and will then proceed to load and pass the next set of preset control values.
I have attached a VI that shows how the main controller operates.  I would attach the whole thing, but it would contain too many files as there are multiple subVIs being called.  Any help in figuring this out would be greatly appreciated.  Thanks!
Attachments:
Main VI Architecture Outline.vi ‏6 KB

You could consider using the Queued Message Handler.  It's a state machine that uses an event structure as one way to influence the next state in a state machine.  I'm not sure if there is an example of it in LV 2010 though.
I would split up the functions into different states.  One state can load your presets, another can read the data from the controls themselves.  A third state would send the data and would be called by either of the other two states.  You would have a button for calling the preset state and another to read the controls.  A final state would cause a graceful exit.  Refer to the template to see how that gets set up.
I was considering just using a basic event structure inside a while loop followed by your code to send the data to the external program, but upon exiting you would have to send one final set of config data to the external program, which is probably NOT what you want to do.
I guess you could use a simple state machine with an idle state that polls the buttons, but I don't like button polling.
Bill
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.

Similar Messages

  • SQL loader and executing the package

    Hi all,
    I am trying to load the data from flatfile and execute a package from .cmd / .bat file.
    here is the script zip_load.cmd
    sqlldr CONTROL=zip.ctl LOG=zip.log DISCARD=Zip.dsc BAD=Zip.bad userid=scott/tiger@mydb
    sqlplus scott/tiger@mydb
    --sqlplusw scott/tiger@mydb
    EXEC pkg_zip_log.prc_zip_log ('zip_load', NULL, 'address', 'begin', 'begin prc_zip');
    commit;
    EXEC pkg_zip_load.prc_zip_maint;
    pkg_zip_log.prc_zip_log ('zip_load', NULL, 'address', 'end', 'begin prc_zip');
    commit;
    exit;
    The above script stopping after loading the data and logging to database from sqlplus.
    sqlldr CONTROL=zip.ctl LOG=zip.log DISCARD=Zip.dsc BAD=Zip.bad userid=scott/tiger@mydb
    sqlplus scott/tiger@mydb
    It's executing the above 2 statments and stopping at
    SQL prompt SQL>
    Could you guys let me know the fix for executing the all statments in one step.
    Thanks in adv.
    bye

    It happens because SQL+ doesn't know anything about the rows after the connect string. It's just waiting for your input. Here is an example how to make it work.
    I've created test package:
    create or replace package body test
    as
    procedure p1
    as
    begin
    dbms_output.put_line('Hello!');
    end;
    end;
    Then on my Unix machine I created a file test.sh:
    sqlplus scott/tiger@prod << EOF
    set serveroutput on
    exec test.p1
    quit
    EOF
    When I run it from command line:
    Connected to:
    Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
    With the Oracle Data Mining option
    JServer Release 9.2.0.1.0 - Production
    SQL> SQL> Hello!
    SQL> Disconnected from Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
    With the Oracle Data Mining option
    JServer Release 9.2.0.1.0 - Production
    Voila!

  • How to set the bind variable on page load and execute query ?

    Hi All,
    I am using Jdeveloper 11.1.1.5
    I have a table called "Employee"
    Columns :- id , name , location
    Data :- 1, ,james , chicago
    2 ,Raj ,capetown
    Now i have another webservice(created as a webservice dataControl) which sends me the "id" on each time my page loads.Now the id which has been returned by webservice should be incorporated in my VO Query as in where clause to fetch the data for the respective "id" in that "Employee" table and should be rendered on form.
    Eg :- Id "2" has been sent by the webservice then the record should be fetched from database should be "2","raj","capetown".
    I know that there would be necessity of bind variable , but how do i set the bind variable on page load ?
    How can i use the bind variable appropriately ??
    Please suggest !!!!
    Thanks.

    Hi,
    Check
    http://www.orastudy.com/oradoc/selfstu/fusion/web.1111/b31974/web_services.htm#CJADCDBG
    http://thepeninsulasedge.com/frank_nimphius/2011/02/18/adf-code-corner-sample-73-released-hands-on-creating-a-search-form-using-a-pojo-ws-and-the-web-service-data-control/
    -Suresh

  • Why won't the voluntary upgrades load and execute?

    About once a week I get a Firefox-generated message asking me to upgrade or accept an update. Then the status bar displays on the screen saying that it's being loaded. That will go on for hours, with no progress.
    Should I download a fresh copy of Firefox 4, and will I get instructions?

    Cor-el wrote: "Remove all rules for Firefox and the plugin-container from the permissions list in the firewall"
    Okay.... I'll bite... What is a "plugin-container" and where are the "rules" to be found? I know this is hard to believe, but not everyone came out of the womb clutching a mouse and a keyboard!

  • AS3 array used to load and play random swfs?

    Hi, I'm trying to use an array adapted from AS2 script to load random swfs called "koan_1.swf" or "koan_2.swf" etc into a "koan_loader_mc" on the stage.  Each "koan_#.swf" has code in its last frame to both advance the "shuffle" array in the action script in the first frame of the stage and to load the next koan swf.  The code below -- almost -- works, but....?
    Frame on main stage:
    // creates function called at the end of koan_#.swfs
    function shuffle(a:Array) {
    for (var ivar = a.length-1; ivar>=0; ivar--) {
    var p = Math.floor(Math.random())(ivar+1);
    var t = a[ivar];
    a[ivar] = a[p];
    a[p] = t;
    // loads koans into koan_loader_mc
    var index:uint = 0;
    var koan_loader:Loader = new Loader();
    var koan:Array =["swfs/koans/koan_1.swf","swfs/koans/koan_2.swf", "swfs/koans/koan_3.swf", "swfs/koans/koan_4.swf", "swfs/koans/koan_5.swf", "swfs/koans/koan_6.swf", "swfs/koans/koan_7.swf", "swfs/koans/koan_8.swf", "swfs/koans/koan_9.swf", "swfs/koans/koan_10.swf", "swfs/koans/koan_11.swf", "swfs/koans/koan_12.swf"];
    koan.shuffle();
    koan_loader.load(new URLRequest(koan[index]));
    MovieClip(this).koan_loader_mc.addChild(koan_loader);
    MovieClip(this).stop();
    Code is on the last frame of the loaded koan swfs:
    MovieClip(stage).index++
    if(MovieClip(stage).index>MovieClip(stage).koan.length-1){
    MovieClip(stage).index=0;
    MovieClip(stage).koan.shuffle();
    MovieClip(stage).koan_loader.load(new URLRequest(koan[MovieClip(stage).index]));
    MovieClip(stage).koan_loader_mc.addChild(koan_loader);
    Thanks for -- any -- guidance and suggestions...at my wit's end...

    Thank you for taking the time to help, but......unfortunately it still isn't working.  When the "koan.shuffle():" segment of code on the first frame of the stage timeline, below, is commented out, everything else in the movie (except randomizing of swfs) works fine.
    This code loads swfs (but they are not randomized/shuffled):
    // loads koans into koan_loader_mc
    var index:uint = 0;
    var koan_loader:Loader = new Loader();
    var koan:Array =["swfs/koans/koan_1.swf","swfs/koans/koan_2.swf", "swfs/koans/koan_3.swf", "swfs/koans/koan_4.swf", "swfs/koans/koan_5.swf", "swfs/koans/koan_6.swf", "swfs/koans/koan_7.swf", "swfs/koans/koan_8.swf", "swfs/koans/koan_9.swf", "swfs/koans/koan_10.swf", "swfs/koans/koan_11.swf", "swfs/koans/koan_12.swf"];
    //koan.shuffle(); 
    koan_loader.load(new URLRequest(koan[index]));
    MovieClip(this).koan_loader_mc.addChild(koan_loader);
    Thanks again for your help....

  • Outlook lost connection when load balanced CAS array name was moved to different AD site and data centre

    At the weekend our F5 load balanced CAS array name was moved to our 3rd datacentre and all users lost access to Outlook.  The databases were running on DAG2 listed below at the time.
    We have 3 DAG servers configured as the following:
    DAG SERVER ONE (DAG1) | Datacentre 1 | Primary AD Site | Multi role server MBX, CAS, HT
    DAG SERVER TWO (DAG2)  | Datacentre 2 | Primary AD Site | Multi role server MBX, CAS, HT
    DAG SERVER THREE (DAG3) | Datacentre 3 | Secondary AD Site | Multi role server MBX, CAS, HT
    We primarlily run from DAG1 or DAG2 - DAG3 is for real DR and loss of Datacentre 1 and 2.  The CAS array "Outlook" is configured for the primary AD site load balanced across DAG1 and DAG2.
    We use an F5 load balancer that balances the connections across DAG1 and DAG2, if both fail then DAG3 is used automatically.   We have tested and it works fine simulating loosing DAG1 and DAG2 and bringing up as a 1 node cluster on DAG3 with a
    FSW and the load balancer pointing at DAG3 for Outlook connections.
    For some reason this stopped Outlook users connecting - can anyone advise me why as I have been asked to test this again and I was expecting it to work?

    Hi,
    As far as I know, For Exchange 2010 before SP2 RU3,the Outlook clients with an existing Outlook profile would continue to use the old RPC endpoint rather than the new RPC endpoint (even though Autodiscover detected the change). Thus, except with Andy's suggestion,
    I recommend you can also repair or recreate the Outlook profile to have a test.
    For more information, you can refer to the following article:
    http://blogs.technet.com/b/aljackie/archive/2013/11/14/outlook-rpc-end-point-and-pf-the-microsoft-exchange-administrator-has-made-a-change-that-requires-you-quit-and-restart-outlook.aspx
    Thanks,
    Angela Shi
    TechNet Community Support

  • My PC is  a Windows xp professional.It don't install and execute  the  download of iTunes 10,it send a message  that the program is in a file  without support  to the down load

    My PC is  a Windows xp professional.It don't install and execute  the  download of iTunes 10,it send a message  that the program is in a file  without support  to the down load

    I'd like to have a closer look at that error message please.
    Generate the error message again. While the error message box is open, hold down the Alt key and hit the PrtSc key. Paste the screenshot into an image file (using a program like Paint), and save the file.
    Start a reply here and click the wee camera icon at the top of the reply window. Click "Choose file", browse to the image file, select the file and click "Open". Now click "Insert file" to insert the screenshot into the reply.

  • Launch PDF from HTML and execute search

    Is it possible using JavaScript in an HTML doc to launch a PDF and execute a search.query with a passed-in search parameter? TIA

    Hello, George, thanks for following up.  I went into Advanced->Document Processing->Document JavaScripts and put the code at the top of the file outside of the dummy function declaration I had to insert to activate the edit button.  It looks like this:
    // Split the file path into an array
    var aPath = this.path.split("/");
    // Remove the last element, which is the file name
    aPath.pop();
    // Join the path elements back together and add the index file
    var cIdxPath = aPath.join("/") + "/Support Documents/SupDocs.pdx";
    search.query ("Enhanced Tactical Automated Security System (eTASS)", "Index", cIdxPath);
    function Search()
    It runs fine when I launch the PDF directly into the reader by double-clicking in file explorer in the folder above "Support Documents".  When I load the PDF from an HTML file in the same folder, however, the script does not run.  I set the reader preferences to force loading in the reader even when launched from a browser, and the script still will not execute.  I tried adding a button to the PDF and attaching the search script to it.  Again, it runs when launching directly but not from the HTML document.  Otherwise, the PDF is empty, and I'm using a relative URL and JS to load it from the HTML doc, such as:
    document.location = "mySearch.PDF"
    or
    window.open("mySearch.PDF", "searchwin");
    Neither one works.  This product has to run from a CD-ROM, so I haven't bothered to test it via http service.  Any suggestions?  Thanks again!
    Jon Camp
    Senior Computer Scientist
    Applied Research Associates, Inc.
    North Florida Division
    Training Solutions Group
    430 W 5th Street Suite 700
    Panama City, FL  32401
    comm: 850-914-3188 x203
    fax: 850-914-3189
    email: [email protected]

  • Actionscript to load captions from array to dynamic text when thumb is clicked

    i have this code below that i made using a tutorial....it loads vars from txt file splits it then puts it into an array....once in an array it the brings the pics in from the array to create thumbnails and a larger image. my problem is i have captions to go with it and when i try to load the captions nothing happens or can be seen to be happening.
    i dont know where i am going wrong as i have no output or compiled errors
    var locVar = new Array();
    locVar = imgLoc.split(",");
    trace ( locVar );
    var tmbVar = new Array();
    tmbVar = tmbLoc.split(",");
    trace ( tmbVar );
    var capVar = new Array();
    capVar = imgCap.split(",");
    trace ( capVar );
    var NPICS:Number = locVar.length;     // number of pictures to load
    var PICX:Number = 32.8;               // x loc of big picture
    var PICY:Number = 24.9;               // y loc
    var THUMBHOLDERX:Number = 50;        // x location of thumbnail holder movieclip
    var THUMBHOLDERY:Number = 457;      // y location
    var THUMBW:Number = 100;             // width of each thumbnail
    var THUMBH:Number = 75;             // height
    var MARGIN:Number = 10;             // margin between thumbnails
    var TOTALBYTES:Number = 212000;     // approx sum of bytes in all jpgs (x 2)
    var MAXPIXELS:Number = 12;          // max number of pixels to move slider per frame
    // mask definition; mask is assumed to cover some part of the thumbnail slider (here the numbers
    // were chosen so that there are margins between the mask and the right and left edges of the movie
    // (which is 420 x 290), and enough space above and below the thumbs to show them when they 'grow'
    // on mouseover
    var MASKX:Number = 0;                    // start x location of mask
    var MASKW:Number = 600;                    // mask width
    var MASKY:Number = 447.9;                    // start y location of mask
    var MASKH:Number = 92;                    // mask height
    var totalloaded:Number = 0;         // running tally of bytes loaded from all pics
    // index into pictures array, used for loading
    var ipic:Number;
    // set up loader, an instance of MovieClipLoader
    var loader:MovieClipLoader = new MovieClipLoader();
    // use the main timeline to listen to and respond to loader's broadcast events
    loader.addListener(this);
    // function to move thumbnail slider ("this" = thumbs_mc)
    function sliderControl() {
       var w:Number = this._width/2;
       var hw:Number = mask_mc._width/2;
       var npixels:Number;
       // only do when mouse over slider mask
       if (_ymouse > mask_mc._y && _ymouse < mask_mc._y + mask_mc._height) {
          // mouse over left half of slider:
          if (_xmouse > mask_mc._x && _xmouse < mask_mc._x + hw) {
             npixels = (hw - _xmouse) / hw * MAXPIXELS;
             this._x += npixels;
             if (this._x >= 0) this._x = this._x - w;
          // mouse over right half of slider:
          } else if (_xmouse > mask_mc._x + hw && _xmouse < mask_mc._x + mask_mc._width) {
             npixels = (_xmouse - hw) / hw * MAXPIXELS;
             this._x -= npixels;
             if (this._x <= -w) this._x = this._x + w;
    // thumbnail click (onrelease) handler
    function openPic() {
       pic_mc.loadMovie(locVar[this.i]);
    function brightON(){
         this._alpha = 300;
    function brightOFF(){
         this._alpha = 30;
    function captionTXT(){
         _root.cap_txt = capVar;
    // assign event handlers (called when all jpgs are loaded)
    function setupHandlers() {
       pct_txt.removeTextField();          // don't need loading indicator any more
       thumbs_mc.onEnterFrame = sliderControl;
       for (var i:Number = 0; i < NPICS*2; i++) {
          thumbs_mc["mc"+i].onRollOver = brightON;
          thumbs_mc["mc"+i].onRollOut = brightOFF;
          thumbs_mc["mc"+i].onMouseDown = captionTXT;
          thumbs_mc["mc"+i].onRelease = openPic;
    // listener function for broadcast 'done' message (for each pic)
    // onLoadInit gets executed when the movieclip has been loaded into _mc AND
    //   its width and height data are available.
    //   (_mc = the movieclip being loaded into)
    // this routine sets the size and position of each thumbnail clip as its jpg
    //   is loaded and starts the next one loading.  When all have been loaded,
    //   a random picture is loaded into pic_mc and setupHandlers is called to
    //   assign handlers to each thumbnail movieclip
    function onLoadInit(_mc:MovieClip) {
       // this gets done when the jpg is completely loaded:
       _mc._width = THUMBW;
       _mc._height = THUMBH;
       _mc._alpha = 30;          // for image clarity
       // give the movieclip a property to remind it who it is
       // (used by openPic to know which big picture to open)
       _mc.i = (ipic >= NPICS ? ipic-NPICS : ipic);
       // add picture size to totalloaded variable
       totalloaded += loader.getProgress(_mc).bytesTotal;
       // now load the next one (if there are more) or set up handlers if done
       ipic++;
       if (ipic == NPICS * 2) {
          // start with a random photo displayed when all thumbs loaded
          pic_mc.loadMovie(locVar[Math.floor(Math.random()*NPICS)]);
          setupHandlers();
       } else if (ipic >= NPICS) {
          // load jpg into duplicate thumbnail (will already be cached)
          loader.loadClip(tmbVar[ipic-NPICS],  thumbs_mc["mc"+ipic]);
       } else {
          // load jpg into thumbnail
          loader.loadClip(tmbVar[ipic],  thumbs_mc["mc"+ipic]);
    // listener function to handle broadcast progress messages
    // make pct_txt show cumulative loading progress
    function onLoadProgress(_mc:MovieClip, loaded:Number) {
       var loadedsofar:Number = totalloaded + loaded;    
       pct_txt.text = Math.floor(loadedsofar / TOTALBYTES * 100) + "%";
    function init() {
       // create holder for pictures
       createEmptyMovieClip("pic_mc", 1);
       pic_mc._x = PICX;
       pic_mc._y = PICY;
       // create (and draw) holder for thumbnails
       createEmptyMovieClip("thumbs_mc", 2);
       thumbs_mc.beginFill(0, 100);     // black
       thumbs_mc.moveTo(0, 0);
          thumbs_mc.lineTo(2 * (MARGIN + THUMBW) * NPICS, 0);
       thumbs_mc.lineTo(2 * (MARGIN + THUMBW) * NPICS, THUMBH);
       thumbs_mc.lineTo(0, THUMBH);
       thumbs_mc.endFill();
       // drawing the thumb holder at 0, 0 and then moving it makes its reg point = upper left
       thumbs_mc._x = THUMBHOLDERX;
       thumbs_mc._y = THUMBHOLDERY;
       // create, draw and enable mask over thumbs (could use different variables to define mask
       // if desired)
       createEmptyMovieClip("mask_mc", 3);
       mask_mc.beginFill(0x0000cc, 100);
       mask_mc.moveTo(0, 0);
       mask_mc.lineTo(MASKW, 0);
       mask_mc.lineTo(MASKW, MASKH);
       mask_mc.lineTo(0, MASKH);
       mask_mc.endFill();
       mask_mc._x = MASKX;
       mask_mc._y = MASKY;
       thumbs_mc.setMask(mask_mc);
       // create loading textfield indicator
       createTextField("pct_txt", 4, 200, 100, 40, 100);
       var tf:TextFormat = new TextFormat();
       tf.align = "center";
       tf.size = 12;
       tf.font = "Verdana";
       tf.color = 0xFFFF00;
       pct_txt.setNewTextFormat(tf);
       // create loading textfield indicator
       createTextField("cap_txt", 0, 400, 200, 40, 100);
       var cf:TextFormat = new TextFormat();
       cf.align = "center";
       cf.size = 12;
       cf.font = "Verdana";
       cf.color = 0xFFFF00;
       cap_txt.setNewTextFormat(cf);
       // make empty movieclips in thumbs_mc for each pic to go into
       // make double the number so the slider can move continuously and show content
       for (var i:Number = 0; i < NPICS * 2; i++) {
          var mc:MovieClip = thumbs_mc.createEmptyMovieClip("mc"+i, i+1);
          mc._x = i*(MARGIN + THUMBW);
          mc._y = 0;
       // set the pointer to the first jpg in the array picnames
       ipic = 0;
       // start loading jpgs (ipic is initialized to 0)
       loader.loadClip(locVar[ipic], thumbs_mc["mc"+ipic]);
    init();
    stop();

    ok here is my code so far.....i've set a movieclip where i want the captions and set the dyn text box above the clip....i've given the movieclip a background n faded so images can still be seen behind.
    im just having a problem with the loop.....each one i tried resulted in the caption staying the same no matter what thumbnail is clicked.
    are there any suggestions as to how this can be done......(please bare in mind im a newbie to actionscript)
    var locVar = new Array();
    locVar = imgLoc.split(",");
    var tmbVar = new Array();
    tmbVar = tmbLoc.split(",");
    var capVar = new Array();
    capVar = imgCap.split(",");
    var NPICS:Number = locVar.length;     // number of pictures to load
    var PICX:Number = 32.8;               // x loc of big picture
    var PICY:Number = 24.9;               // y loc
    var THUMBHOLDERX:Number = 50;        // x location of thumbnail holder movieclip
    var THUMBHOLDERY:Number = 457;      // y location
    var THUMBW:Number = 100;             // width of each thumbnail
    var THUMBH:Number = 75;             // height
    var MARGIN:Number = 10;             // margin between thumbnails
    var TOTALBYTES:Number = 212000;     // approx sum of bytes in all jpgs (x 2)
    var MAXPIXELS:Number = 12;                    // max number of pixels to move slider per frame
    var CAPSW:Number = 525;                    
    var CAPSH:Number = 28;     
    var CAPSX:Number = 38;            //caption text x position
    var CAPSY:Number = 391;            //caption text y position
    // mask definition; mask is assumed to cover some part of the thumbnail slider (here the numbers
    // were chosen so that there are margins between the mask and the right and left edges of the movie
    // (which is 420 x 290), and enough space above and below the thumbs to show them when they 'grow'
    // on mouseover
    var MASKX:Number = 0;                    // start x location of mask
    var MASKW:Number = 600;                    // mask width
    var MASKY:Number = 447.9;                    // start y location of mask
    var MASKH:Number = 92;                    // mask height
    var totalloaded:Number = 0;         // running tally of bytes loaded from all pics
    // index into pictures array, used for loading
    var ipic:Number;
    // set up loader, an instance of MovieClipLoader
    var loader:MovieClipLoader = new MovieClipLoader();
    // use the main timeline to listen to and respond to loader's broadcast events
    loader.addListener(this);
    // function to move thumbnail slider ("this" = thumbs_mc)
    function sliderControl() {
       var w:Number = this._width/2;
       var hw:Number = mask_mc._width/2;
       var npixels:Number;
       // only do when mouse over slider mask
       if (_ymouse > mask_mc._y && _ymouse < mask_mc._y + mask_mc._height) {
          // mouse over left half of slider:
          if (_xmouse > mask_mc._x && _xmouse < mask_mc._x + hw) {
             npixels = (hw - _xmouse) / hw * MAXPIXELS;
             this._x += npixels;
             if (this._x >= 0) this._x = this._x - w;
          // mouse over right half of slider:
          } else if (_xmouse > mask_mc._x + hw && _xmouse < mask_mc._x + mask_mc._width) {
             npixels = (_xmouse - hw) / hw * MAXPIXELS;
             this._x -= npixels;
             if (this._x <= -w) this._x = this._x + w;
    // thumbnail click (onrelease) handler
    function openPic() {
            pic_mc.loadMovie(locVar[this.i]);
    function brightON(){
         this._alpha = 300;
    function brightOFF(){
         this._alpha = 30;
    function captionTXT(){
         cap_txt.text = capVar[this.i];
    // assign event handlers (called when all jpgs are loaded)
    function setupHandlers() {
       pct_txt.removeTextField();          // don't need loading indicator any more
       thumbs_mc.onEnterFrame = sliderControl;
       for (var i:Number = 0; i < NPICS*2; i++) {
          thumbs_mc["mc"+i].onRollOver = brightON;
          thumbs_mc["mc"+i].onRollOut = brightOFF;
          thumbs_mc["mc"+i].onMouseDown = captionTXT;
          thumbs_mc["mc"+i].onRelease = openPic;
    // listener function for broadcast 'done' message (for each pic)
    // onLoadInit gets executed when the movieclip has been loaded into _mc AND
    //   its width and height data are available.
    //   (_mc = the movieclip being loaded into)
    // this routine sets the size and position of each thumbnail clip as its jpg
    //   is loaded and starts the next one loading.  When all have been loaded,
    //   a random picture is loaded into pic_mc and setupHandlers is called to
    //   assign handlers to each thumbnail movieclip
    function onLoadInit(_mc:MovieClip) {
       // this gets done when the jpg is completely loaded:
       _mc._width = THUMBW;
       _mc._height = THUMBH;
       _mc._alpha = 30;          // for image clarity
       // give the movieclip a property to remind it who it is
       // (used by openPic to know which big picture to open)
       _mc.i = (ipic >= NPICS ? ipic-NPICS : ipic);
       // add picture size to totalloaded variable
       totalloaded += loader.getProgress(_mc).bytesTotal;
       // now load the next one (if there are more) or set up handlers if done
       ipic++;
       if (ipic == NPICS * 2) {
          // start with a random photo displayed when all thumbs loaded
           var calc:Number = Math.floor(Math.random()*NPICS);
          pic_mc.loadMovie(locVar[0]);
           cap_txt.text = capVar[0];
          setupHandlers();
       } else if (ipic >= NPICS) {
          // load jpg into duplicate thumbnail (will already be cached)
          loader.loadClip(tmbVar[ipic-NPICS],  thumbs_mc["mc"+ipic]);
       } else {
          // load jpg into thumbnail
          loader.loadClip(tmbVar[ipic],  thumbs_mc["mc"+ipic]);
    // listener function to handle broadcast progress messages
    // make pct_txt show cumulative loading progress
    function onLoadProgress(_mc:MovieClip, loaded:Number) {
       var loadedsofar:Number = totalloaded + loaded;     
       pct_txt.text = Math.floor(loadedsofar / TOTALBYTES * 100) + "%";
    function init() {
       // create holder for pictures
       createEmptyMovieClip("pic_mc", 1);
       pic_mc._x = PICX;
       pic_mc._y = PICY;
       // create (and draw) holder for thumbnails
       createEmptyMovieClip("thumbs_mc", 2);
       thumbs_mc.beginFill(0, 100);     // black
       thumbs_mc.moveTo(0, 0);
       thumbs_mc.lineTo(2 * (MARGIN + THUMBW) * NPICS, 0);
       thumbs_mc.lineTo(2 * (MARGIN + THUMBW) * NPICS, THUMBH);
       thumbs_mc.lineTo(0, THUMBH);
       thumbs_mc.endFill();
       // drawing the thumb holder at 0, 0 and then moving it makes its reg point = upper left
       thumbs_mc._x = THUMBHOLDERX;
       thumbs_mc._y = THUMBHOLDERY;
       // create, draw and enable mask over thumbs (could use different variables to define mask
       // if desired)
       createEmptyMovieClip("mask_mc", 3);
       mask_mc.beginFill(0x0000cc, 100);
       mask_mc.moveTo(0, 0);
       mask_mc.lineTo(MASKW, 0);
       mask_mc.lineTo(MASKW, MASKH);
       mask_mc.lineTo(0, MASKH);
       mask_mc.endFill();
       mask_mc._x = MASKX;
       mask_mc._y = MASKY;
       thumbs_mc.setMask(mask_mc);
       // create loading textfield indicator
       createTextField("pct_txt", 4, 200, 100, 40, 100);
       var tf:TextFormat = new TextFormat();
       tf.align = "center";
       tf.size = 12;
       tf.font = "Verdana";
       tf.color = 0xFFFF00;
       pct_txt.setNewTextFormat(tf);
       createEmptyMovieClip("caps_mc", 5);
       caps_mc.beginFill(0x000000, 50);
       caps_mc.moveTo(0, 0);
       caps_mc.lineTo(CAPSW, 0);
       caps_mc.lineTo(CAPSW, CAPSH);
       caps_mc.lineTo(0, CAPSH);
       caps_mc.endFill();
       caps_mc._x = CAPSX;
       caps_mc._y = CAPSY;
       // create loading textfield indicator
       createTextField("cap_txt", 6, 38, 380, 525, 25);
       var cf:TextFormat = new TextFormat();
       cf.align = "center";
       cf.size = 16;
       cf.font = "Arial Black";
       cf.color = 0xFFFFFF;
       cap_txt.setNewTextFormat(cf);
       cap_txt._x = CAPSX;
       cap_txt._y = CAPSY;
       // make empty movieclips in thumbs_mc for each pic to go into
       // make double the number so the slider can move continuously and show content
       for (var i:Number = 0; i < NPICS * 2; i++) {
          var mc:MovieClip = thumbs_mc.createEmptyMovieClip("mc"+i, i+1);
          mc._x = i*(MARGIN + THUMBW);
          mc._y = 0;
       // set the pointer to the first jpg in the array locVar
       ipic = 0;
       // start loading jpgs (ipic is initialized to 0)
       loader.loadClip(locVar[ipic], thumbs_mc["mc"+ipic]);
       cap_txt.text = capVar[2];
    init();
    stop();

  • Logic crash when loading 3rd party space designer preset

    Hi,
    I am having problems loading 3rd party space designer presets in a specific project. When I load the presets in a new song there is no problem. I would like to use the presets in this specific project, so maybe somebody knows a solution.
    I already tried system maintenance like
    - running the regular cron scripts
    - repairing permissions
    - removing the logic preferences file
    My setup:
    - dual 2Ghz PPC G5
    - 4 GB DDR SDRAM
    - OSX 10.4.11
    - Logic Pro 8.0.2 (1502.22)
    And the crash report until the crash:
    OS Version: 10.4.11 (Build 8S165)
    Report Version: 4
    Command: Logic Pro
    Path: /Applications/Logic Pro.app/Contents/MacOS/Logic Pro
    Parent: WindowServer [78]
    Version: 8.0.2 (1502.22)
    Build Version: 9
    Project Name: Logic
    Source Version: 15022200
    PID: 374
    Thread: 0
    Exception: EXCBADACCESS (0x0001)
    Codes: KERNPROTECTIONFAILURE (0x0002) at 0x00000014
    Thread 0 Crashed:
    0 com.apple.AppKit 0x926bd0c8 -[NSMatrix mouseDown:] + 304
    1 com.apple.AppKit 0x9256b4e0 -[NSWindow sendEvent:] + 4616
    2 com.apple.prokit 0x96b52914 -[NSProWindow sendEvent:] + 272
    3 com.apple.logic.pro 0x005ff78c 0x1000 + 6285196
    4 com.apple.AppKit 0x92514524 -[NSApplication sendEvent:] + 4172
    5 com.apple.logic.pro 0x00521c74 0x1000 + 5377140
    6 com.apple.logic.pro 0x0051bf54 0x1000 + 5353300
    7 com.apple.logic.pro 0x00521c4c 0x1000 + 5377100
    8 com.apple.AppKit 0x9250b960 -[NSApplication run] + 508
    9 com.apple.prokit 0x96b2e714 NSProApplicationMain + 296
    10 com.apple.logic.pro 0x00003f1c 0x1000 + 12060
    11 com.apple.logic.pro 0x00003c20 0x1000 + 11296
    Any ideas?
    Thanks,
    Wouter.

    A quick update: logic crashes in more cases now. Last time I was working on volume automation in the arrange window.

  • Is there such thing as a "compile and execute statement" in Java?

    I wanted to know if there's any way to compile and execute a program "within" another program.

    Yes, but the classes to do so aren't officially supported by Sun as far as I know.
    And you must be able to assume a thing or two about the stuff you compile, such as existing constructors or factory methods etc, otherwise it gets hairy.
    Here's some example code (haven't tried it, so excuse any spelling errors etc) to compile the source code in a file called MyClass.java:
    ByteArrayOutputStream baos = new ByteArrayOutputStream();
    new sun.tools.javac.Main(baos,null).compile("MyClass.java");
    String theMsg = baos.toString();
    if (theMsg.length() > 0)
        // NiftyErrorHandlingHere
    }After that, you can load it with a simple ClassLoader.loadClass() call and create instances of it.
    It must be compiled with the tools.jar file in the classpath, to find the sun.tools.javac.Main class.
    However, for any such dynamically compiled class to be of any use to you, you must be able to assume something about it, such as implementing interfaces or whatever, otherwise it's a kind of pointless exercise.
    HTH,
    F

  • How to load and save custom workspaces in PE7

    I've written a little utility which allows PE7 users to load and save custom workspaces. It's attached to post #1 of this thread.
    System requirements
    The utility has been tested with Windows XP Pro SP3 only. It might or might not run under Vista. It will only work with PE7 installations where the executable files are in the default places.
    Installation
    When you have downloaded the utility (it's only 199KB) you can run it from any convenient place in your system - it doesn't need to be installed as such.
    Usage
    It's pretty self-explanatory in use but here's the manual!
    Run the downloaded utility "PE7WS.exe".
    A file selection dialog appears. Choose the workspace layout file you wish to use. "LastUsed.layout" is the last used workspace (that's all you will be offered the first time you run the program). If you press Cancel at this point, the program will exit and nothing will happen.
    Once you have selected the workspace, click "Open" and Premiere Elements 7 will run, using the workspace layout you chose.
    After you exit from Premiere Elements 7, a workspace layout file save dialog will appear. If you made changes to the workspace during your Premiere Elements 7 session, you can now give the revised workspace a name and save it.
    Do not save the workspace in a different directory from that which the dialog offers!
    If you have changed an existing custom workspace, and you want to update the version previously stored, just select the name and over-write the saved workspace layout with the new one.
    If you don't want to save the workspace at all, just click "Cancel" - next time you run Premiere Elements, you can choose the "LastUsed.layout" workspace to use that last used unsaved workspace in any event.
    If you use the PE7WS utility to run Premiere Elements 7, and then you use the menu option "Window > Restore Workspace", then exit, you can either cancel the workspace saving stage, (which will mean that "LastUsed.layout" will contain that default workspace), or you could give that default workspace a name like "PE7 Default" so you can start a future Premiere Elements 7 session with the default workspace, even though you last used a custom workspace.
    If you run Premiere Elements 7 in the usual way without using PE7WS.exe, the workspace that appears will be the last used one.
    The usual disclaimer...
    The utility should be entirely safe in use, but I can't accept responsibility for any loss or damage it might cause. However, the only file manipulation is does is to workspace files in the directory that Premiere Elements 7 uses purely for the purpose - the utility doesn't go anywhere near your precious project files.

    I'm finding it very handy on my particular twin 22" monitor setup to sometimes use a one-screen layout and sometimes a two screen layout. I 'discovered' that having the timeline on the second monitor enables me to tweak edits there while having the playback full size after pressing the "full screen" button on the first monitor. Where the timeline would normally be I have the history, mixer, and other windows always open. As the second monitor is also used by another PC (the one I have the net and email etc on) using "Maxivista" monitor sharing software, I revert to single screen layout when doing stuff like exporting to DVD so I can see what is going on with the render while typing stuff like this.
    Selectable workspaces are dead handy!

  • Automated execution and mailing of BeX reports

    Hi,
    I have a requirement which goes like this:
    There is a report which gives a P&L statement for a cost center. Say I have one parent Cost Center Group and there are 100 Cost Centers within that group. The report allows the user to select variants based on the cost center. So they have to execute this report every month for 100 different cost centers in order to generate a P&L for each cost center.
    Now the users want some sort of automated way to execute the reports every month for each cost center within a cost center group and then the results (XL based) delivered to them through email. The mail should contain workbooks or BeX reports.
    Is it possible to implement this? If yes then how can this be achieved?
    We are running BW 3.5.
    Thanks in advance,
    Regards,
    Nikhil

    Hi Arun,
    Do you have some document on how to use the RSCRM_BAPI transaction?
    everytime I try to run an extract it generates an error "No authorization to create extract /BIC/0CYYNIKTEST of type Table"
    and when I try to execute the query - it generates an OLAP error in a key figure.
    The query is quite complexin the sense that it uses structures in both the rows & columns sections and also uses all possible types of variables and also hs built in variants already.
    I would be grateful if you can send across some document on the transaction. I would have posted docs & screenshots of the query, but there is no way in SDn to do that.
    Thanks & regards,
    Nikhil

  • How to load a second array?

    I have this code loading a set of thumbnails. Right now the
    first set of thumbs loads fine but how to load my second array in a
    new row?

    Well my first idea would be that somewhere you are out of
    scope and therefore you are getting an undefined somewhere in your
    code.
    So it might be trying to pass "undefined" as your url.
    I would start with the debugger and step through the code to
    make sure that it is able to get all the values it needs at every
    step.
    A good understanding of the debugger tool will save you tons
    of time.
    My next idea would be to split the code up using the command
    pattern.
    Also, since you only have two arrays, you could put an if
    statement before incrementing the arr variable.
    example:
    if (arr < 2){
    arr++;
    }

  • SQL *Loader and External Table

    Hi,
    Can anyone tell me the difference between SQL* Loader and External table?
    What are the conditions under we can use SQL * Loader and External Table.
    Thanx

    External tables are accessible from SQL, which generally simplifies life if the data files are physically located on the database server since you don't have to coordinate a call to an external SQL*Loader script with other PL/SQL processing. Under the covers, external tables are normally just invoking SQL*Loader.
    SQL*Loader is more appropriate if the data files are on a different server or if it is easier to call an executable rather than calling PL/SQL (i.e. if you have a batch file that runs on a server other than the database server that wants to FTP a data file from a FTP server and then load the data into Oracle).
    Justin

Maybe you are looking for

  • Folders on NAS read-only. Can't change

    I have a buffalo linkstation pro duo NAS. It is formatted in XFS. It seems that randomly some folders have been changed to read-only, when they were previously read-write. I have one folder that is stuck in a read-only state. The folder contains some

  • I have reset an Ipod 4g, and everytime I try to install ios 6.0, half way through is says failed.  Can anyone help me please?  I have tried 5 times... :(

    I recently purchased an Ipod 4G from a family friend.  When I set up my account, I originally was going to keep some of the items on it but found they were not appropriate for my 10 yr old.  So I reset the IPOD erasing everything and started new.  Af

  • I think there is a bug in belle

    i recently connect my nokia 500 to a wifi connection all things are going good then i try to connect it by 3g nothing happens in the browser then i reinstall firmware than it say connection fails and then after few more trials nothing happens in the

  • Can I submit form using app.launchURL

    I want to submit a pdf form without replacing my page. I need it open in new tab. The script below is work, but it replaces my old page this.submitForm({ cURL: "http://localhost:8080/project/TestServlet", cSubmitAs: "PDF", cCharset: "utf-8" This scri

  • MX2004 Dreamweaver won't run in 10.5.8, any solutions?

    I have been running Dreamweaver MX2004 on my (various Mac) computers for years now without a hitch.  Now I have just updated my OS to 10.5.8 and Dreamweaver will not load. Does anyone out there have a solution to this other than buying a whole new ve