1. Melissa Malubay
  2. PowerBuilder
  3. Tuesday, 26 September 2017 01:04 AM UTC

I am trying to do an integration testing with PB 12.5.2 and some APIs. I have managed to make it work on the client server version but can't seem to make it work after deploying to Appeon (EAServer) Appeon for PowerBuilder 2013 R2 Build 0126.00 . I just get a blank return when running the application from the Appeon Server.  

I read Appeon supports OLEObject. Are there any dlls I should be deploying as part of the application deployment to make this work? Not sure what I am missing and couldn't find and documentation about this. Appreciate any help

GET: 

integer li_rc, ll_status_code 

string ls_return, ls_status_text, ls_response_text 

OLEObject PBObject 

PBObject = Create OLEObject 

PBObject.ConnectToNewObject("Msxml2.XMLHTTP.6.0") 

PBObject.OPEN ("GET" , "https://jsonplaceholder.typicode.com/posts/2",FALSE) 

PBObject.send() 

//Get response 

ls_status_text = PBObject.StatusText 

ll_status_code = PBObject.Status 

ls_response_text = PBObject.ResponseText 

 

POST: 

string ls_args, ls_headers_content_type, ls_return, ls_status_text, ls_response_text

OLEObject PBObject 

PBObject = Create OLEObject 

PBObject.ConnectToNewObject("Msxml2.XMLHTTP.6.0") 

PBObject.OPEN ("POST" , "https://reqres.in/api/users", FALSE) 

ls_headers_content_type = "application/json" 

PBObject.setRequestHeader("Content-Type", ls_headers_content_type) 

ls_args = '{"name":"test","job":"leader"}' 

PBObject.send(ls_args) 

ls_status_text = PBObject.StatusText 

ll_status_code = PBObject.Status 

ls_response_text = PBObject.ResponseText

Appeon Support Team Accepted Answer Pending Moderation
  1. Friday, 29 September 2017 01:47 AM UTC
  2. PowerBuilder
  3. # 1

Hi,

Your script work well our end. What's the OS version? if PB application work well on this machine?

Please note that OLE is only supported by Appeon Web but not supported by Appeon Mobile.If you want to run application on web only, please make sure the project type is ‘Web’ (Appeon Developer> Application Profile Configuration> Basic Settings), thus the unsupported features report would only include the unsupported features by Appeon Web (the report will include ll the unsupported features by Web and Mobile if the project type is ‘Universal’).

Regards,
ZhaoKai

 

 

Comment
  1. Melissa Malubay
  2. Friday, 29 September 2017 19:00 PM UTC
Hi ZhaoKai,



Thanks for the response.  I updated my deployment project type to use Web and it worked! It was initially set to Universal.  Thanks again!

  1. Helpful
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.