Results 1 to 5 of 5

Thread: Odd Direct_Output behavior

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Sep 2011
    Location
    Minneapolis, MN
    Posts
    269

    Default Odd Direct_Output behavior

    THIS IS SUPPOSED TO BE IN THE WINDOWS APPLICATION THREAD. DF 24.0

    Ran into a somewhat odd behavior when writing to a log.txt file within process A and and calling a function from a business process.

    As the process runs, many log entries are created within the log.txt file.
    Once the call to a function of a business process is made, writing to the log is suspended and send directly to my default printer.

    Code:
    Direct_Output "\log\process_output.txt"
    Writeln ("Start Update procedure: "+String(dtCurrent))
    Writeln (">>> Searching for active Employer records...")
    //Call to bp to create attachment for employer.
    Get CreateAttachment of oAttachments sDownloadFilePath hTable hColumn iEmployerIdno (iContrId<>0) hTable sEmployerName "" (&iAttachIdno) to bSuccess
    // When CreateAttachment is called, writeln will no longer write to "process_output.txt" file but instead will send the remainder of the writeln output directly to my printer.
    Writeln (String(CurrentDateTime())*"Attachment record created: iAttachIdno:"*String(iAttachIdno)*"|"*sDocumentId)
    Writeln (String(CurrentDateTime())*"Attachment record updated with: ContractID:"*String(iContrId)*' and ContractFlag:'*String(iContrId<>0))
    Writeln (">>> Updating contract record with new file path...")
    What is that all about?
    Last edited by Benjamin; 13-Nov-2024 at 11:28 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •