BOI UPD Object - Paperless Office

SOLVED

Has anyone ever successfully created a paperless office pdf when printing/updating a Sage register/journal via BOI?  I believe the documentation says to set the journal object's 'destination' property to 'PAPERLESS'.  While I'm able to post the register, despite my repeated attempts, I'm unable to generate the pdf in paperless.  The upd object's 'print journal' method is successful with 'PAPERLESS' being specified as the destination, but no pdf in paperless viewer, no pdf in the configured pdf directory.  Would be interested to hear if anyone got this to work and/or if they knew of any special tricks that are necessary. (I actually posted about this some time ago - based on the lack of responses to that post I'm guess no one has done this, but I thought I'd throw it out there again).  Thanks.

Parents
  • 0

    Continuing on with this - Is anyone aware of the correct BOI procedure to update a subledger register, then immediately update the resulting daily transaction register?  Ideally I would like to post the DTR for just the subledger batch I'm posting, but if I need to post everything that's sitting in the DTR, that would be fine.

    Right now, with the same session object, I'm running the SO Sales Journal's nUpdate() method, which is updating nicely, but if I attempt to create a GL_DailyTransaction_upd object and run nProcessReport/nUpdate, I'm getting 'File is empty'.  

    Any help would be appreciated!

  • 0 in reply to Justin K

    Before attempting to print the DTR, execute this method of the DTR object:  SetUpdateRegister() with an argument of Source Journal + Journal Number.  Source Journal is a two character value and the Journal Number is a six character zero filled value, example:  SO000100.  This method is used in the update programs when chaining to the DTR.

  • 0 in reply to Steve Passmore

    Thanks Steve.  I guess the next question is - is there a way to retrieve the SJ/Journal Number used from the Sales Journal UPD object after running nProcessReport?

Reply Children
  • 0 in reply to Justin K

    From the main update object you can retrieve that value with the method GetCurrentRegister$(), the return value of that method call is the Source Journal + Journal Number that was updated.  The value looks like it will have a carriage return character appended to it.

  • 0 in reply to Steve Passmore

    Thanks again Steve.  I have this in place, with the call of SetUpdateRegister being successfull, but unfortunately I'm still getting 'file is empty'.  I'm messing around with the other methods available in the documentation (below) but still not having any luck.  I'm also including my DTR code in case anyone sees a problem I'm missing.  Thanks in advance for any assistance offered.

     

    If Not CBool(oSession.nSetDate("S/O", "20180313") Then
    lastError = "Error setting daily transaction register module date. " & oSession.sLastErrorMsg
    End If

    If Not CBool(mbi.oSS.nSetModule("S/O")) Then
    lastError = "Error setting daily transaction register module. " & oSession.sLastErrorMsg
    End If

    If Not CBool(mbi.oSS.nSetProgram(mbi.oSS.nLookupTask("GL_DailyTransactionUpdate_ui"))) Then
    lastError = "Error setting G/L Daily Transaction Register program. " & oSession.sLastErrorMsg
    End If

    oUpdObj = mbi.oScript.NewObject("GL_DailyTransaction_upd", oSession)

    sourceJournal = “SO000026”

    If Not CBool(oUpdObj.nSetUpdateRegister(sourceJournal)) Then
    lastError = "Error setting source journal with '" + sourceJournal + "': " + oUpdObj.sLastErrorMsg
    End If

    If Not CBool(oUpdObj.nProcessReport(“PRINT”)) Then
    lastError = "Error printing GL Daily Transaction Register to '" + destination + "': " + oUpdObj.sLastErrorMsg
    End If
  • 0 in reply to Justin K

    Anyone else have any luck when calling the SetUpdateRegister method?  I've tried everything I can think of, even verifying after the Sales Journal update that the register I'm specifying has existing records in the GL_DailyPosting table, but still, 'file is empty'.

  • +1 in reply to Justin K
    verified answer

    Justin try this -

    Before nSetUpdateRegister(sourceJournal) change your sourceJournal= to one of these

    sourceJournal = “SO000026” + vbCR
    sourceJournal = “SO000026” + CHR(13)

  • 0 in reply to Alnoor

    So like a dummy I was explicitly removing those characters from the end after retrieving the source journal from the Sales Journal object (thinking they would cause a problem when assigning the source journal to the dtr object).  Looks like they were necessary. Thanks so much Alnoor!

  • 0 in reply to Justin K

    Welcome. I don't know the rationale but SetUpdateRegister() always returns Success no matter what you pass to it so it is misleading.