1. Ganne Gannene
  2. PowerBuilder
  3. Monday, 19 February 2018 14:28 PM UTC

Hi to all !

Of_getclienttype function return only "PB" value (pbl in C:\inetpub\wwwroot\appeon\developTempFile\appeon_workarounds release of september '17).

I deploy a web app to local powerserver web, but this function return "".

Is the function complete? Where I can find the complete pbl?

I would like to use of_callwebservice function

I'm using PB version 2017 build 1666 with powerserver web.

Thanks in advance.

//------------------------------------------------------------------------------
// Function: appeonextfuncs::of_getclienttype()
//------------------------------------------------------------------------------
// Description:
//     Gets the type of an application.
//                Returns "PB" if the application runs in PowerBuilder.
// 
// Arguments: (None) 
// 
// Returns:  string
//        WEB     :Runs on the Web .
//        PB      :Runs in the PowerBuilder enviorment.
//        MOBILE  :Runs on the Mobile.
//------------------------------------------------------------------------------
// Author: APPEON  Date: 2005-11
//------------------------------------------------------------------------------
// Revision History:
//    1.0   Initial version
//==============================================================================

RETURN "PB"

Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Monday, 19 February 2018 22:25 PM UTC
  2. PowerBuilder
  3. # 1

Please make sure your application target includes the workaround .PBL, and then do a full build and full deployment of your Web application to IIS.  I'm not aware of any bugs related to this feature, but if your issue still persists please open a support ticket.

Comment
  1. Ganne Gannene
  2. Tuesday, 20 February 2018 07:23 AM UTC
Thanks Armeen. I include .pbl in my target application and I do a full build and full deployment. .pbl was in C:\inetpub\wwwroot\appeon\developTempFile\appeon_workarounds directory.

  1. Helpful
There are no comments made yet.
Govinda Lopez @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 20 February 2018 01:09 AM UTC
  2. PowerBuilder
  3. # 2

Hi Ganne,

They are located in the \appeon_workaroundsxxxe (xxx indicates the PowerBuilder version) folder under the Appeon Developer installation directory. For example, C:\Program Files\Appeon\Developer2013R2\appeon_workarounds125e.

As Armeen said: you need to include the pbl in your target. Then do a full build and a new full deployment. If the problem persists, please open a support ticket.


Regards,

Comment
  1. Ganne Gannene
  2. Tuesday, 20 February 2018 07:24 AM UTC
Hi Govinda,



I include .pbl in my target application and I do a full build and full deployment. .pbl was in C:\inetpub\wwwroot\appeon\developTempFile\appeon_workarounds directory.

  1. Helpful
  1. Ganne Gannene
  2. Tuesday, 20 February 2018 07:26 AM UTC
I installed yesterday Appeon PB Universal Edition Version 2017 R2 Build 1756 But nothing has changed.

  1. Helpful
There are no comments made yet.
Marco Meoni Accepted Answer Pending Moderation
  1. Tuesday, 20 February 2018 08:59 AM UTC
  2. PowerBuilder
  3. # 3

Hello Ganne,

in PB2017 the workarounds libs is indeed located under C:\inetpub\wwwroot\appeon\developTempFile\appeon_workarounds.

You must instantiate the appeonextfuncs object first!

appeonextfuncs apb
apb = CREATE appeonextfuncs
If apb.of_getClientType() = ‘WEB’ Then
    // PowerServer Web code
ElseIf apb.of_getClientType() = ‘PB’ Then
    // PB Desktop code
ElseIf apb.of_getClientType() = ‘MOBILE’ Then
    // PowerServer Mobile
End If
DESTROY apb

Alternatively, you can just use the global function

If AppeonGetClientType()  = 'WEB' Then ...

You asked why the implementation only returns ‘PB’: like many objects in the workarounds lib, it is just a placeholder to Appeon. When PB code is converted to the Web/Mobile, the function will be replaced by target-platform code. But if you compile it for a standard PB desktop application, it returns, indeed, ‘PB’.

Since you mentioned “I would like to use of_callwebservice function”, please consider what just said above. You must instantiate the appeonwebservicecomponent object first.
Cheers,
Marco

Comment
  1. Ganne Gannene
  2. Tuesday, 20 February 2018 09:27 AM UTC
Hi Marco, thank you for answer.



This is my pb code:



 



appeonwebservicecomponent appeonws

appeonws = create appeonwebservicecomponent



setnull(ll_null)



 la_params[1] = ...

 la_params[2] = ...

 la_params[3] = ...

 la_params[4] = ..

 

appeonws.calltype="1"

appeonws.proxydllorurl=ls_webserviceurl

appeonws.classdescript=""

 

ll_rc = appeonws.of_callwebservice("....",la_params)

 

if isnull(ll_rc) then ll_rc = -1

 

if ll_rc > 0 then

else

 ls_path_client = AppeonGetCacheDir()

 ...

end if

 

destroy appeonws



 



 



of_callwebservice function works fine. Global function AppeonGetCacheDir() and AppeonGetClientType() return empty string, not a "WEB" string.



I'll try to replace the global functions with the appeonextfuncs object.



Thank you very much.



 

  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.