1. Joe Hess
  2. PowerBuilder
  3. Wednesday, 31 October 2018 21:11 PM UTC

Every now and then, I receive an error using Base64Encode. The message is "Please make sure that the encryption dynamic library has already existed." The code is below, offending line in bold. This message does not appear to come from a thrown exception. The reported error line is 16 of this function.

Any ideas what may cause this?

Thanks!

 

// Convert the current user/password to base64.
STRING    ls_userName, ls_authorizationKey
CODEROBJECT    lnv_coderObject

lnv_coderObject = Create CODEROBJECT

// Avatax-defined key to convert
IF ( f_invalidstr ( as_userName ) ) THEN
    ls_userName = SQLCA.LogID + ':' + cs_prefix + SQLCA.LogPass
ELSE
    ls_userName = as_userName
END IF

// Base 64 encoding
try
    as_authorizationKey = lnv_CoderObject.Base64Encode(Blob(ls_userName,EncodingUTF8!))
catch (Exception se)
    astr_error = f_logError ('Encoding Error', se.getMessage(), '')
end try

RETURN (f_invalidstr(astr_error.message))

Accepted Answer
Mark Lee @Appeon Accepted Answer Pending Moderation
  1. Thursday, 1 November 2018 05:28 AM UTC
  2. PowerBuilder
  3. # Permalink

Hi Joe,

 

I verified with your code but can’t reproduce the issue.

  1. If you get this error on PB IDE

     Please verify if you have the pbcrypt170.dll file in the PowerBuilder share folder (by default it is: C:\Program Files (x86)\Appeon\Shared\PowerBuilder)

     If it is not there, we suggest that you try to uninstall PB R3 and reinstall it to see if it resolves the issue.

 

  1. If you get this error in runtime environment, please make sure the pbcrypt170.dll file is in the running application’s directory.

In normal condition, this dll will be created after you install PB R3 runtime package.

For more detail please see the following link:

https://www.appeon.com/support/documents/appeon_online_help/pb2017r3/application_techniques/ch35s04.html

 

Regards,

Mark Lee

Comment
There are no comments made yet.
Joe Hess Accepted Answer Pending Moderation
  1. Tuesday, 13 November 2018 22:27 PM UTC
  2. PowerBuilder
  3. # 1

Sorry, I took so long to get back to this. I think that was it.

 

Thank you!

Joe

Comment
There are no comments made yet.
Joe Hess Accepted Answer Pending Moderation
  1. Wednesday, 31 October 2018 21:18 PM UTC
  2. PowerBuilder
  3. # 2

I forgot to mention this is PB2017 R3. Windows 7 if that matters.

 

Joe

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.