A little background on using Crypt:SSLeay in the PERL script

I found this URL in my research today, thought it may help expand some understanding.
http://www-128.ibm.com/developerworks/linux/library/wa-perlsecure.html?ca=drs-
Chris

Hi,
Basically your function is zooming base to width (selected object or window) so instead of modifying I suggest to create a new a "base to scale" function.
To keep top window content shown after scaling one can use a trick and select temporalily created object in a center (remove it after), so:
function zoomToScale(myScale) {
  if (isNaN(myScale) || myScale > 4000 || myScale < 4) myScale = 100;
  var
  window = app.activeWindow,
  mDoc = app.activeDocument,
  mZeroPoint = mDoc.zeroPoint,
  mHorizViewPrefs = mDoc.viewPreferences.horizontalMeasurementUnits,
  mActiveSpread = window.activeSpread,
  mSpreadPages = mActiveSpread.pages.length,
  mWidth, theRec, mTopCenter;
  mDoc.zeroPoint = [0,0];
  mDoc.viewPreferences.horizontalMeasurementUnits = MeasurementUnits.points;
  mWidth = mDoc.documentPreferences.pageWidth;
  theRec = mActiveSpread.rectangles.add();
  mTopCenter = mWidth*mSpreadPages / 2;
  theRec.move(undefined,[mTopCenter,0]);
  window.zoom(ZoomOptions.fitSpread);
  window.zoomPercentage = myScale;
  app.selection = theRec;
  theRec.remove(); 
  mDoc.zeroPoint = mZeroPoint;
  mDoc.viewPreferences.horizontalMeasurementUnits = mHorizViewPrefs;
call it i.e. this way:
zoomToScale(170);
myScale is reset to 100 if it is out of range or is not a number
Jarek

Similar Messages

  • ISO 7 how do you close out open apps running in the background you use to double press the start button and then touch and hold an icon on the bottom

    How to close open apps from bottom of screen on ISO 7 when you double tap start button

    When you double click the home button.  You see the App Icon below and an open view of the app page above.  Swipe the open view page upwards and the app closes.

  • How to covert a ttibetan pdf file to a .docx file using adobe acrobat maintain the tibetan script

    Hi I'm working with a pdf file in traditional Tibetan script and I need to use this content in an editable .doc or .docx file. How do I convert this Tibetan script into a word doc? My adobe doesn't recognize Tibetan as a downloadable item. Please help. Thanks

    I've tried several settings when saving as a PDF, to try to produce a file with fonts that can be detected by Acrobat.  I tried the presets listed in guide: Photoshop Help | Saving PDF files
    But none have worked.
    I cannot use PNG because it is not one of the formats that Acrobat allows for a watermark.  And JPG doesn't work because I need transparency.

  • How to use DBMS_JOB to run the OWB scripts?

    Can anyone pls explain how I can use the DBMS_JOB to run the scripts which are generated by OWB.
    Suroop

    CREATE OR REPLACE PACKAGE "LOAD_DATAMART"
    AS
    TYPE t_global IS RECORD
    ( plsql_map VARCHAR2(50) := 'transactions_map_exp', -- Default mapping plsql program
    plsql_map_main VARCHAR2(50) := 'transactions_map_exp.main', -- Default mapping plsql main program
    servers NUMBER(2) := 19, -- Default concurrent loading servers
    max_reloads NUMBER(3) := 3 , -- Default maximum load retrys
    mail_sender VARCHAR2(99) := '"Certegy Data Warehouse"', -- Default Mail Sender
    mail_notice VARCHAR2(99) := '[email protected]', -- Default Recepient Notification
    mail_error VARCHAR2(99) := '[email protected]' -- Default Recepient for Errors.
    GLOBAL t_global ;
    PROCEDURE start_monitor_load(p_date IN DATE);
    PROCEDURE monitor_load( p_date IN DATE , p_dwh_load# IN NUMBER DEFAULT NULL, p_servers IN NUMBER DEFAULT GLOBAL.servers );
    PROCEDURE start_load(p_dwh_load# IN NUMBER, p_load_seq IN NUMBER, p_rbs IN VARCHAR2);
    PROCEDURE create_job_load(p_dwh_load# IN NUMBER, p_load_seq IN NUMBER, p_rbs VARCHAR2 DEFAULT 'batch01_rbs' );
    FUNCTION dependency_on(p_type IN VARCHAR2, p_date IN DATE) RETURN BOOLEAN;
    PROCEDURE send_mail (p_sender IN VARCHAR2, p_recipient IN VARCHAR2, p_subject IN VARCHAR2, p_message IN VARCHAR2);
    PROCEDURE start_load_guard;
    PROCEDURE load_guard(p_job IN INTEGER);
    END load_datamart;
    CREATE OR REPLACE PACKAGE BODY "LOAD_DATAMART"
    AS
    PROCEDURE start_monitor_load(p_date IN DATE) IS
    v_plsql VARCHAR2(32000);
    BEGIN
    v_plsql := 'load_datamart.monitor_load(to_date('''||TO_CHAR(p_date,'DD-MON-YYYY HH24:MI:SS')||''',''DD-MON-YYYY HH24:MI:SS''));';
    EXECUTE IMMEDIATE 'declare v_job integer; begin dbms_job.submit(v_job,:v_plsql); end;'
    USING v_plsql;
    END start_monitor_load;
    PROCEDURE monitor_load( p_date IN DATE, p_dwh_load# IN NUMBER DEFAULT NULL , p_servers IN NUMBER DEFAULT GLOBAL.servers ) IS
    TYPE t_server IS TABLE OF NUMBER INDEX BY BINARY_INTEGER;
    v_server t_server;
    v_dwh_load# NUMBER;
    v_reload_limit NUMBER := 0;
    v_plsql_error VARCHAR2(32000);
    pending_jobs BOOLEAN;
    p_batch VARCHAR2(20) := 'batch01_rbs';
    FUNCTION job_server_running(p_dwh_load_seq NUMBER) RETURN BOOLEAN IS
    CURSOR c1 IS SELECT * FROM DWH_LOAD_DETAIL
    WHERE dwh_load# = v_dwh_load#
    AND load_seq = p_dwh_load_seq;
    r1 c1%ROWTYPE;
    PROCEDURE try_resubmit_job(p_dwh_load_seq OUT NUMBER) IS
    v_load_seq NUMBER;
    BEGIN
    SELECT COUNT(*) INTO v_load_seq
    FROM DWH_LOAD_DETAIL
    WHERE dwh_load# = v_dwh_Load#;
    IF v_load_seq < v_reload_limit THEN
    INSERT INTO DWH_LOAD_DETAIL(dwh_load#,load_seq,load_server,plsql_map,map_parameters)
    VALUES(v_dwh_load#,v_load_seq+1,0,r1.plsql_map,r1.map_parameters||'| SEQ '||v_load_seq);
    COMMIT;
                   ELSE
                   RAISE_APPLICATION_ERROR(-20000,'Maximum '||v_reload_limit||' retrys reached, load aborted.');
    END IF;
    END;
    BEGIN
    OPEN c1;
    FETCH c1 INTO r1;
    IF c1%NOTFOUND THEN
    RETURN FALSE;
    ELSIF c1%FOUND AND r1.job_end_time IS NULL THEN
    RETURN TRUE;
    ELSIF c1%FOUND AND r1.job_end_time IS NOT NULL THEN
    IF r1.job_end_time = 'BROKEN' THEN
    try_resubmit_job(r1.load_seq); -- Oracle Errors
    END IF;
    RETURN FALSE;
    END IF;
    CLOSE c1;
    END job_server_running;
    FUNCTION get_next_load_seq(p_dwh_load_server IN NUMBER) RETURN NUMBER IS
    CURSOR c1 IS SELECT * FROM DWH_LOAD_DETAIL
    WHERE dwh_load# = v_dwh_load#
    AND load_server = 0
    ORDER BY dwh_load#,load_seq
    FOR UPDATE OF load_server;
    r1 c1%ROWTYPE;
    BEGIN
    OPEN c1;
    FETCH c1 INTO r1;
    IF c1%FOUND THEN
    UPDATE DWH_LOAD_DETAIL
    SET load_server = p_dwh_load_server
    WHERE CURRENT OF c1;
    END IF;
    CLOSE c1;
    COMMIT;
    RETURN r1.load_seq;
    END get_next_load_seq;
    BEGIN
    v_dwh_load# := p_dwh_load#;
    -- Defining the Max Retry to load
    SELECT COUNT(*) + GLOBAL.max_reloads INTO v_reload_limit
    FROM DWH_LOAD_DETAIL
    WHERE dwh_load# = v_dwh_load#;
    FOR i IN 1..99 LOOP
    v_server(i) := NULL;
    END LOOP;
    LOOP
    pending_jobs := FALSE;
    FOR i IN 1..p_servers LOOP
    IF NOT job_server_running(v_server(i)) THEN
    v_server(i) := get_next_load_seq(i);
    IF v_server(i) IS NOT NULL THEN
    load_datamart.create_job_load(v_dwh_load#,v_server(i),p_batch);
    IF p_batch = 'batch01_rbs' THEN
    p_batch :='batch02_rbs';
    ELSIF p_batch = 'batch02_rbs' THEN
    p_batch :='batch03_rbs';
    ELSIF p_batch = 'batch03_rbs' THEN
    p_batch :='batch01_rbs';
    END IF;
    END IF;
    END IF;
    IF v_server(i) IS NOT NULL THEN
    pending_jobs := TRUE;
    END IF;
    END LOOP;
    EXIT WHEN NOT pending_jobs;
    dbms_lock.sleep(05);
    END LOOP;
    COMMIT;
    UPDATE DWH_LOAD_HEADER
    SET plsql_error = 'Completed'
    WHERE dwh_load# = v_dwh_load#;
    COMMIT;
    EXCEPTION WHEN OTHERS THEN
    v_plsql_error := SUBSTR(SQLERRM,1,4000);
    load_datamart.send_mail(load_datamart.GLOBAL.mail_sender,load_datamart.GLOBAL.mail_error,
    'Load Datamart - Load '||TO_CHAR(p_date,'MM/DD/YYYY HH24:MI:SS')||' not completed',
    v_plsql_error||CHR(10)||
    ':::::::::::::::::::::::::::::::::::::::::'||CHR(13)||
    '- Parameter Date '||TO_CHAR(p_date,'MM/DD/YYYY')||CHR(13)||
    ':::::::::::::::::::::::::::::::::::::::::'||CHR(13)||
    '- Transmission time '||TO_CHAR(p_date,'hh24:mi:ss')||CHR(13)||
    '- Load Seq# '||TO_CHAR(v_dwh_load#)||CHR(13)||
    ':::::::::::::::::::::::::::::::::::::::::'||CHR(13));
    v_plsql_error := SUBSTR(SQLERRM,1,4000);
    UPDATE DWH_LOAD_HEADER
    SET plsql_error = v_plsql_error
    WHERE dwh_load# = v_dwh_load#;
    COMMIT;
                        RAISE_APPLICATION_ERROR(-20000,v_plsql_error);
    END monitor_load;
    PROCEDURE start_load(p_dwh_load# IN NUMBER, p_load_seq IN NUMBER, p_rbs IN VARCHAR2) IS
    v_plsql_map VARCHAR2(200);
    v_sqlerrm VARCHAR2(4000);
    BEGIN
    UPDATE DWH_LOAD_DETAIL
    SET job_start_date = TRUNC(SYSDATE) ,
    job_start_time = TO_CHAR(SYSDATE,'HH24:MI:SS')
    WHERE dwh_load# = p_dwh_load#
    AND load_seq = p_load_seq
    RETURN plsql_map INTO v_plsql_map;
    COMMIT;
    EXECUTE IMMEDIATE 'set transaction use rollback segment '||p_rbs;
    v_plsql_map := 'begin '||v_plsql_map||' end;';
    EXECUTE IMMEDIATE v_plsql_map;
    EXECUTE IMMEDIATE 'begin
    UPDATE DWH_LOAD_DETAIL
    SET job_end_date = SYSDATE,
    job_end_time = TO_CHAR(SYSDATE,''HH24:MI:SS''),
    rta_iid = '||global.plsql_map||'.get_runtime_audit_id,
    rta_select = '||global.plsql_map||'.get_selected,
    rta_update = '||global.plsql_map||'.get_updated,
    rta_insert = '||global.plsql_map||'.get_inserted,
    rta_errors = '||global.plsql_map||'.get_errors,
    rta_delete = '||global.plsql_map||'.get_deleted
    WHERE dwh_load# = :p_dwh_load#
    AND load_seq = :p_load_seq;
    UPDATE DWH_LOAD_HEADER
    SET rows_inserted = NVL(rows_inserted,0) + NVL('||global.plsql_map||'.get_inserted,0)
    WHERE dwh_load# = :p_dwh_load#;
    END;' using p_dwh_Load#,p_load_seq;
    COMMIT;
    EXCEPTION WHEN OTHERS THEN
    v_sqlerrm := SUBSTR(SQLERRM,1,3999);
    EXECUTE IMMEDIATE ' begin
    UPDATE DWH_LOAD_DETAIL
    SET job_end_date = SYSDATE,
    job_end_time = ''BROKEN'',
    rta_iid = '||global.plsql_map||'.get_runtime_audit_id,
    rta_select = '||global.plsql_map||'.get_selected,
    rta_update = '||global.plsql_map||'.get_updated,
    rta_insert = '||global.plsql_map||'.get_inserted,
    rta_errors = '||global.plsql_map||'.get_errors,
    rta_delete = '||global.plsql_map||'.get_deleted,
    plsql_error = :v_sqlerrm
    WHERE dwh_load# = :p_dwh_load#
    AND load_seq = :p_load_seq;
    UPDATE DWH_LOAD_HEADER
    SET rows_inserted = NVL(rows_inserted,0) + NVL('||global.plsql_map||'.get_inserted,0)
    WHERE dwh_load# = :p_dwh_load#;
    END; ' using v_sqlerrm, p_dwh_load#,p_load_seq;
    COMMIT;
    END start_load;
    PROCEDURE create_job_load(p_dwh_load# IN NUMBER, p_load_seq IN NUMBER, p_rbs VARCHAR2 DEFAULT 'batch01_rbs' ) IS
    p_job INTEGER;
    v_date DATE;
    BEGIN
    -- Submitting Job Load
    DBMS_JOB.SUBMIT(p_job,'load_datamart.start_load('||p_dwh_load#||','||p_load_seq||','||''''||p_rbs||''');');
    COMMIT;
    END create_job_load;
    FUNCTION dependency_on(p_type IN VARCHAR2, p_date IN DATE) RETURN BOOLEAN IS
    CURSOR c1 IS SELECT * FROM DWH_DATA_LOADS
    WHERE data_type = p_type
    AND file_date >= TRUNC(p_date);
    r1 c1%ROWTYPE;
    BEGIN
    OPEN c1;
    FETCH c1 INTO r1;
    IF c1%FOUND AND r1.status = 'Done' THEN
    RETURN FALSE;
    END IF;
    CLOSE c1;
    RETURN TRUE;
    END;
    PROCEDURE send_mail (p_sender IN VARCHAR2,
    p_recipient IN VARCHAR2,
    p_subject IN VARCHAR2,
    p_message IN VARCHAR2) IS
    * This procedure is usefull for sending e-mails for single or multiples recipients up to 50 *
    * the limitation is Lotes Notes e-mail service. *
    * Lewis Cunnigham Package is good also for massive distribuition to multiples e-mails, *
    v_mailhost VARCHAR2(30) := '172.27.2.157'; -- Titan and Eagle available SMTP service, through the GATEWAY
    v_mailhost    VARCHAR2(30) := 'STPMTA1ML';      old one
    v_mailhost    VARCHAR2(30) := 'stpnh1ml';       Main SMTP, all other are replicated, not available.
    v_mailhost    VARCHAR2(30) := 'STPMS6ML';       Replicated server, not available.
    v_mail_conn utl_smtp.connection;
    v_crlf VARCHAR2(2) DEFAULT CHR(13)||CHR(10);
    v_date VARCHAR2(255) DEFAULT TO_CHAR( SYSDATE, 'MM/DD/YYYY hh24:mi AM' ); -- Lotus Notes default format.
    --pragma autonomous_transaction;
    PROCEDURE writeData( p_text IN VARCHAR2 ) AS
    BEGIN
    IF ( p_text IS NOT NULL ) THEN
    utl_smtp.write_data( v_mail_conn, p_text || v_crlf );
    END IF;
    END;
    BEGIN
    v_mail_conn := utl_smtp.open_connection(v_mailhost, 25); -- Default port
    utl_smtp.helo(v_mail_conn, v_mailhost);
    utl_smtp.mail(v_mail_conn, p_sender);
    utl_smtp.rcpt(v_mail_conn, p_recipient);
    utl_smtp.open_data(v_mail_conn);
    writeData( 'To: '|| p_recipient ); -- Redundant, but necessary to complete format
    writeData( 'From: ' || p_sender); -- Redundant, but necessary to complete format
    writeData( 'Date: ' || v_date ); -- Database completion time
    writeData( 'Subject: ' || NVL( p_subject , '(no subject) ' ) ); -- Default Subject
         --writeData( 'Content-Type: text/html');
    utl_smtp.write_data(v_mail_conn, '' || v_crlf );
    utl_smtp.write_data(v_mail_conn, p_message ); -- Message body
    utl_smtp.close_data(v_mail_conn );
    utl_smtp.quit(v_mail_conn);
    --commit;
    EXCEPTION WHEN OTHERS THEN null;                                Since we are just sending e-mails,
    -- We don't care about mail errors like when server down, only when needed.
    END;
    PROCEDURE start_load_guard IS
    v_job INTEGER;
    BEGIN
    DBMS_JOB.SUBMIT(v_job,'load_datamart.load_guard(100);',SYSDATE+100);
         DBMS_JOB.CHANGE(v_job,'load_datamart.load_guard('||v_job||');',SYSDATE,'sysdate+((1/60)*1/24)');
         COMMIT;
    END start_load_guard;
    PROCEDURE load_guard(p_job IN INTEGER) IS
    v_job INTEGER;
         CURSOR c1 IS SELECT * FROM DWH_DATA_LOADS
         WHERE file_date BETWEEN TRUNC(SYSDATE) AND TRUNC(SYSDATE)+(86399/86400);
    did_PAYC_load BOOLEAN := NULL;
    did_ARMS_load BOOLEAN := NULL;
    did_CLMS_load BOOLEAN := NULL;
    did_STAT_load BOOLEAN := NULL;
    did_TRAN_load BOOLEAN := NULL;
    did_VCOM_load BOOLEAN := NULL;
    did_BCRD_load BOOLEAN := NULL;
    did_PNET_load BOOLEAN := NULL;
    BEGIN
    FOR i IN c1 LOOP
         NULL;
         --if i.status in ('Ready','Done') then
         --if i.data_type = 'PAYC' then
         END LOOP;
         IF NOT ( SYSDATE >= TO_DATE(TO_CHAR(SYSDATE,'DD-MON-YYYY')||' 13:35:00','DD-MON-YYYY HH24:MI:SS') )THEN
    send_mail('"Load Datamart"','[email protected]','I am the guard','This is my body messaje at '||TO_CHAR(SYSDATE,'DD-MON-YYYY HH24:MI:SS')||'.');
    ELSE
    send_mail('"Load Datamart"','[email protected]','I am the guard, this is the last message.','This is my body messaje at '||TO_CHAR(SYSDATE,'DD-MON-YYYY HH24:MI:SS')||'.');
    DBMS_JOB.SUBMIT(v_job,'begin dbms_job.next_date('||p_job||',to_date('''||TO_CHAR(SYSDATE+1,'DD-MON-YYYY')||' 03'||''',''DD-MON-YYYY HH24'')); commit; exception when others then null; end;',TRUNC(SYSDATE));
         END IF;
    COMMIT;
    EXCEPTION WHEN OTHERS THEN
    load_datamart.send_mail('"Load Datamart"','[email protected]','I am the guard, I break at '||TO_CHAR(SYSDATE,'DD-MON-YYYY HH24:MI:SS'),SQLERRM);
    END load_guard;
    END load_datamart;

  • Perl script -use essbase

    In perl script , I am using
    use essbase; (This statement is required to use Essbase within a Perl script)
    But while compiling the perl script , this line is giving error (use essbase;)
    Do we need any prerequisites in order to utilze the command "use essbase"

    Successfully installed Runtime client (including ESSCMD and MaxL) on Win 2k machine and tested Essbase.pm functionality using regular Perl script (/sample/table.pl).Problem: trying to "use Essbase;" in a Perl CGI script running under Apache generates following error:"Can't load 'c:/Perl/site/lib/auto/Essbase/Essbase.dll' for module Essbase: load_file:The specified module could not be found at c:/Perl/lib/Dynaloader.pm line 206."Any one found a way to "use Essbase;" in a Perl CGI script?

  • Transparent background after using rotobrush

    I used the rotobrush on an object and now want to isolate that object and "delete" the background. I turned on the transparency and set it to zero, and exported it to premiere (i only get the option of exporting it to premiere or flash, nothing else). when I do this, the background is still with the object I used the rotobrush on. How can I completely get rid of the background so I can just superimpose the footage in premiere?
    thanks!

    You don't set transparency to zero... that means all of your layer will be transparent.
    Don't use File>Export, use Add composition to Render Cue or Composition>Make Movie
    Read up on exporting with an alpha chanel
    Or, if you have Creative Suite, Save your After Effects project and import into Premiere as a dynamic link.
    If you don't know what I'm talking about then read the basics of AE and look at a few of the tutorials. RotoBrush is a little bit of an advanced procedure that takes experience to properly use, making AE deliver a usable product (a movie) is the most rudimentary of basics.

  • Using analog output in the background

    Hi,
    I need to use the analog output channel on a NI PCIe-6351 to play an audio signal, and while the signal plays i need make some changes the UI dialog box, is it possible for me to move the playing of the audio to the background and proceed with program execution?
    Here is a simple piece of code that explains what I'm trying to do: 
    #include<stdio.h>
    #include<stdlib.h>
    #include<conio.h>
    #include<math.h>
    #include<string.h>
    #include<memory.h>
    #include<wchar.h>
    #include "sndfile.h" //include file for the sound library
    #include "NIDAQmx.h"
    #define DAQmxErrChk(functionCall) { if( DAQmxFailed(error=(functionCall)) ) { goto Error; } }
    float *fWavSample;
    SNDFILE *SoundFile;
    SF_INFO SoundFileInfo;
    int iNoOfSamples=0;
    int32 error=0;
    TaskHandle AOtaskHandle = 0;
    float64* AIOSample;
    char errBuff[2048]={'\0'};
    int32 fnCreateTask(TaskHandle *AOTaskHandle)
    int32 error=0;
    DAQmxErrChk(DAQmxCreateTask("", AOTaskHandle));
    Error:
    return error;
    int ReadWavFile()
    //Open the wav file for reading
    SoundFile=sf_open("sin_10s.wav",SFM_READ,&SoundFileInfo);
    //Check if file is opened sucessfully
    if (SoundFile == NULL)
    puts("File not opened");
    return FALSE;
    //allocate memory for the buffer that is to hold the wav data&colon;
    fWavSample = new float[SoundFileInfo.channels * SoundFileInfo.frames];
    iNoOfSamples = SoundFileInfo.channels * SoundFileInfo.frames;
    //Read data into the float structure that has been copied in
    sf_readf_float(SoundFile, fWavSample, SoundFileInfo.frames);
    //Allocate memory for the structure that is to hold the sound samples
    AIOSample = new float64[iNoOfSamples+660];
    //Copy wavefile data into the new float64 array (needs to be typecasted to float64)
    int i=0;
    for(i=0;i<(SoundFileInfo.channels * SoundFileInfo.frames);i++)
    AIOSample[i] = (float64)fWavSample[i];
    //After the float64 array has been filled, release the memory used by fWavSample
    free(fWavSample);
    return 0;
    int main(int argc, char** argv)
    DAQmxErrChk(fnCreateTask(&AOtaskHandle));
    //Create an analog out channel
    DAQmxErrChk (DAQmxCreateAOVoltageChan(*(&AOtaskHandle),"Dev1/ao1","",-10.0000000,+10.00000,DAQmx_Val_Volts,NULL));
    //16 bit output resolution needed, sampling rate matched to the WAV file's
    DAQmxErrChk (DAQmxCfgSampClkTiming(AOtaskHandle,"",44100.0,DAQmx_Val_Rising,DAQmx_Val_ContSamps,1000));
    //Set the output to trigger on a rising edge on PFI6
    //DAQmxErrChk (DAQmxCfgDigEdgeStartTrig (AOtaskHandle,"PFI6",DAQmx_Val_Rising));
    //Start the task in the background
    DAQmxStartTask(AOtaskHandle);
    ReadWavFile();
    DAQmxErrChk(DAQmxWriteAnalogF64(AOtaskHandle,(SoundFileInfo.channels * SoundFileInfo.frames),true,10.0, DAQmx_Val_GroupByChannel,AIOSample,NULL,NULL));
    printf("Playing audio\n");
    Error:
    if( DAQmxFailed(error) )
    DAQmxGetExtendedErrorInfo(errBuff,2048);
    //puts(errBuff);
    puts(errBuff);
    return TRUE;//DefWindowProc(hwndmon,message,wParam,lParam);
    getch();
    The program reads a 10 seconds long 1kHz sine wave signal from a WAV file and plays it over AO0.
    I want the program to  print "Playing Audio" on the console window while the audio is still playing, i.e when DAQmxWriteAnalogF64 is executing.
    I'm using Visual Studio 2005 on Windows XP and an NI PCIe6351.
    I'd really appreciate any help I can get.
    Thanks a lot!
    RaziM

    Hi RaziM, 
    It sounds like you will need to implement some sort of multithreading to accomplish playing audio in the background and also making changes in the UI dialog box in the foreground. Since DAQmx is thread safe this should definitely be possible, but it will probably take a little more work on your part.
    You may want to take a look at this page which gives a walkthrough to Multithreading with a Background component, http://msdn.microsoft.com/en-us/library/ywkkz4s1.aspx
    Here is another forum post about how DAQmx runs multiple threads, http://forums.ni.com/t5/Measurement-Studio-for-VC/DAQmx-how-does-it-multithread/td-p/221953
    I hope some of this helps!
    Rachel M.
    Applications Engineer
    National Instruments

  • Schedule Background job using transaction CATM

    Hi all,
    Since we cannot schedule a background job using transaction CATM, I have created a program calling the CATM transaction through batch-input.
    I have done a recording and entered the coding in a Z-program. For a vendor, I have recorded time in CAT2 for multiple purchase orders.
    After entering the vendor number in CATM, all the purchase orders showed up. I have clicked 'select all' and posted.
    When I run the program in the background, it posts only for one purchase order.
    When I  run the program in the foreground, using the Select All-button it only proceeds with the first line in my list of PO's.
    How to read the whole stack and post the whole stack of purchase orders? 
    Please help me out with this.
    Thanks
    Regards
    Srinivasan Desingh
    408 368 3837

    Hi,
    When I run the program in the background, it posts only for one purchase order.
    When I  run the program in the foreground, using the Select All-button it only proceeds with the first line in my list of PO's.
    See..it's a Z-program so Its difficult to answer without checking the program. But I think, you should check your BDC again from Debugging, with the help of your abaper. You will find, why its is processing only one entry.
    Regards
    Shishir

  • Schedule background job using system variant

    Dear gurus,
    We're planning to schedule background job using system variant, for example, current fiscal year and current posting period (transaction AFAB). Is it possible? So for example, for this month, "Posting Period" value will be 6, and then next month will be 7.
    Can you tell me how to do this, if I want to set up the schedule only once?
    Thanks for your help.
    Best Regards,

    done using abap

  • How to schedule a background job using the Event concept..?

    Hi Folks,
    I have a requirement that, I need a schedule a background job.
    Once after the previous job successful only, new job should get triggered. How to go ahead with this..?
    For Eg, I am scheduling a job called ZTEST periodically for 1 minute. If the job is not get completing with in 1 minute, I dont want to start my new job. Only after the success of my old job, I want my new job to run.
    Waiting for ur replies.
    Regards,
    Savi.

    Hi,
    You can use events that have already been defined, or you can create new events for scheduling background jobs.
    If you wish to use new events, do the following to implement the event scheduling:
    Define and transport the event as a user event with transaction SM62.
    You must define only event IDs; event arguments are not defined in the R/3 System. Instead, you specify event arguments when you schedule a job to wait for an event and when you trigger the event.
    If you define a new event, you must also transport it to your production systems. The event transaction does not have a connection to the transport system. Instead, you must create a transport request for the event yourself.
    Do this to transport an event:
    Create a transport request.
    Start the editor in the transport request and enter the following:
    R3TR TABU <table name> where table name is BTCSEV for a system event ID, BTCUEV for a user event ID.
    Press F2 with the cursor on the table name to call up the screen for specifying the table entries to transport. In this screen, enter the event ID’s that you have created.
    Save and release the transport request. Ensure that it is imported into your production system(s).
    To trigger an event, add:
    – the function module BP_EVENT_RAISE to your ABAP program, or
    – the program SAPEVT to your external script, batch file, or program.
    When your programs execute these keywords, an event will be triggered in the R/3 background processing system. The event-based scheduler is started immediately. It in turn starts all jobs that were waiting upon the event, subject to normal background processing restrictions, such as the requirement that the job has been released to start.
    Schedule the jobs that are to run when your events are triggered.
    You can schedule jobs for one-time start or to be started whenever an event is triggered.
    Regards,
    Raj.

  • How to schedule the background job using current selection screen field val

    Hello Friends,
    How to schedule the background job using current selection screen field values.
    after completion of the job the spool should be sent as a mail to SAP Inbox.
    Is there any way to create the variant dynamically by reading the current selection screen values.
    Thanks,
    Ravi

    Hi,
    To get the variant details you can use teh following FM.
    'RS_VARIANT_CONTENTS'.
    Regards,
    Ankur Parab

  • How can I change fullscreen background color, so that it is the same when viewing on mac and iPad? I want this to be able to use MathType in widget text.

    How can I change fullscreen background color, so that it is the same when viewing on mac and iPad? I want this to be able to use MathType in widget text.
    As an example, html widget has white background on iPad, and black on mac. The same goes for interactive widget.
    The MathType text inserted is inserted as a image, and will have the same color when in fullscreen as when not. So I need the textcolor to be the same in both views. Anyone know how to fix this?

    We're still not communicating. This is why I wanted an example .iba.
    Here's a re-creation of my own, going off what you described. You said "all html widgets and all gallery widgets" have this problem. So I inserted a blank HTML widget and a blank Gallery widget, and typed into both. Inserted a MathType equation into both. I don't see any difference when I preview it on my Mac compared to the preview on the iPad. I want to help, but I can't help if I can't duplicate the issue.
    I've attached the screen shots and the .iba file [link to .iba file].
    Feel free to email me directly at bobm at dessci dot com. If you're uncomfortable giving some information here, tell me anything you want in email. I work for the "MathType company", Design Science.

  • I would like to change the setting so that the whole lap-top screen apart from the bookmarks column is used for the information - at the moment I have only a strap using 2/3 of the screen, and the rest is mozlla background

    The previous version of Firefox used the whole screen; this version (Firefox Beta 4.0) uses only about 2/3 of the screen, leavig a space above and below the part-screen that it does use,and filling the rest with a background. I was able to chose which background when I first updated to this version, but I wasn't given the choice, as far as i remember, to have no background and use the whole screen.

    How recently did you switch?  If it's less than 60 days, then Verizon simply reinstates your previous account.  The fact that you were on the EDGE plan and mailed the devices back, and they apparently are somewhere in the system, could cause complications, and it might just work out that you just go back on the same plan and they set you up with the same devices.  I'm not sure how it will go - but since you are still being billed for the devices... 

  • I need help Centering a div box to a background image using dreamweaver cs5.5.

    I need help Centering a div box to a background image using dreamweaver cs5.5. Everything shift left when viewing on different size monitors?  See what I mean at
    www.woodlandhospice.com

    Have you looked at your page with images disabled?
    I urge you to re-think this approach to web design because images of text are not indexed by search engines, screen readers or translators.  Given the demographic group your site is targeting, you really need to ensure maximum web accessibility for all users.
    Navigation, headings and descriptions all need to be in real text -- not images of text.
    Ken is right.  Absolute positioning is pure poison for such a simple layout.  My advice is to start over with one of the pre-built Starter Pages in DW.  Go to File > New > Blank page > HTML.  Select a layout from the 3rd column and hit CREATE button.
    Nancy O.

  • Using a photo as the background when creating a book.

    In the 08 version, the photo background could be used no matter which page layout was selected. For some unknown reason with 09, you can only use a photo as the background when you select "two" and click on the choice that has one picture frame as the page layout. When other layouts are selected, to include "two" with the two pictures frames, when you try to drag a photo into the background it will take that picture and add a photo to the page, but not as the background. Instead of having a photo in the background you went from two frames to three, or three to four, etc., with a blank background.

    I got it to work. I went to another theme, added the photo to the background and then went back to the Travel theme. I got it to stick. I also could change the layout to more or fewer photos per page and keep the background photo. Not the best solution but at least it worked. Be sure to post a bug report at http://www.apple.com/feedback/iphoto.html
    OT

Maybe you are looking for

  • Solution manager 7.1 installation in ECC 6.0 landscape

    Dear All, I am planning to install solman 7.1 SP04 in my landscape where the managed systems are running on ECC 6.0. SP 07(PRD, DEV,...). Is it fine to start installation with current landscape or i need to upgrade the ECC version. Any documents avai

  • Output file from ABAP program

    I am using the program Z_SAP_HIERARCHY_DOWNLOAD to output a hierarchy in BW to a specified drive. It works fine when I go to SE38 and run it. However, when I run it from a process chain, it doesn't output the file. How can I generate the output file

  • Cannot install Windows Server 2012 R2

    Hi I've been able to install Windows Server 2012 standard on a VMWare ESXi 5.1 host. I've noticed our license was a Windows Server 2012 R2 standard, so I went on eOpen and download the appropriate software. Now when I try to install it, I get a Windo

  • 'int' not serializable!?

    Hello all, When deploying my application to WLS 8.1, I keep getting warnings along the lines of <Warning> <EJB> <BEA-012034> <The Remote interface method: '//snip// Foo.bar(java.lang.String,int) throws java.rmi.RemoteException //snip// contains a par

  • How to set multi fonts in one textItem?

    I have a textItem with Chinese & English. I want to set Chinese and English in different fonts, but the script can only set one font. So, when I set the textItem in western fonts, the Chinese can't display correctly (display block). When I set it to