Dismiss Notice
We would like to remind you that we’re updating our login process for all 3CX forums whereby you will be able to login with the same credentials you use for the Partner or Customer Portal. Click here to read more.

Dynamic FileName Expression

Discussion in 'CRM / Helpdesk / App Integration' started by csa452, Dec 14, 2011.

Thread Status:
Not open for further replies.
  1. csa452

    Joined:
    Nov 11, 2010
    Messages:
    24
    Likes Received:
    0
    Hello,

    We are trying to name the WAV output of a Record Component dynamically, by concatenating the buffer of a User Input along with '.WAV'.

    So for the filename of the Record Component, we have specified CONCATENATE(EnterID.Buffer,’.wav’) but this does not produce any output and we get a syntax error in the 3cxIVRserver.log file. However, when we set the filename to EnterID.Buffer, it does produce the file but it is missing the .WAV extension.

    Could someone advise if there is a better way to do this?

    Thanks
     
  2. VAD_Support

    VAD_Support Active Member

    Joined:
    Aug 6, 2009
    Messages:
    690
    Likes Received:
    0
    Can you post the syntax error that you see in the log?
    You're on the right track, that is the way to go. It should be easy to fix.
    Thanks,
     
  3. csa452

    Joined:
    Nov 11, 2010
    Messages:
    24
    Likes Received:
    0
    Thank you for your response.

    In the debug file in the working directory we get this:

    Code:
    VARIABLE_CHANGED: Main_EnterID_Buffer=5555
    VARIABLE_CHANGED: Main_EnterID_Result=ValidDigits
    END_EXECUTION: Main.flow - EnterID - MF
    END_EXECUTION: Main.flow - componentBranch1 - MF
    VARIABLE_CHANGED: ID=5555
    END_EXECUTION: Main.flow - IDVar - MF
    VARIABLE_CHANGED: project$_CurrentErrorDescription$=
    VARIABLE_CHANGED: project$_CurrentErrorName$=error.semantic.ecmascript
    END_EXECUTION: Main.flow -  - EH
    END_EXECUTION: Main.flow - errorHandlerContainer1 - EH
    And in the 3cxIVRserver.log we are seeing:

    Code:
    Error! Module '3CX.com.OSBjsi'. Error ID 501. errmsgsyntax errorline1linetxtCONCATENATE_2('EnterID.Buffer',???.wav???)tokentxt???.wav???)
    11:55:30.860|4712|(0):Error! Module '3CX.com.OSBjsi'. Error ID 501. errmsgSyntaxError: syntax errorline1linetxtCONCATENATE_2('EnterID.Buffer',???.wav???)tokentxt???.wav???)
    Thanks again
     
  4. VAD_Support

    VAD_Support Active Member

    Joined:
    Aug 6, 2009
    Messages:
    690
    Likes Received:
    0
    It seems that it is not understanding the single quote, maybe you're not using the right character there. Try changing:
    CONCATENATE(EnterID.Buffer,’.wav’)
    with:
    CONCATENATE(EnterID.Buffer,'.wav')

    Pay attention to the single quote, it is different, the one you used is not the right one...

    Give it a try and let me know.

    Thanks,
     
  5. csa452

    Joined:
    Nov 11, 2010
    Messages:
    24
    Likes Received:
    0
    Thank you! That was the solution.
     
  6. VAD_Support

    VAD_Support Active Member

    Joined:
    Aug 6, 2009
    Messages:
    690
    Likes Received:
    0
    Great, thanks for letting me know!
     
Thread Status:
Not open for further replies.