PowerBuilder 2022 R3 on Windows 10. I am trying to use OleCustomControl - 32 bit ActiveX control from nsoftware.com: www.nsoftware.com/platforms/activex/setup?sku=ISAJ-A&type=demo
I used the control for many years but the vendor made a change which PowerBuilder cannot handle. It is an event in OCX control. This is how it worked before:
Sub webdavcontrol_DirList(ResourceURI As String, DisplayName As String, ContentLanguage As String, ContentLength As String, ContentType As String, LastModified As String)
All event arguments are String.
The new problematic version:
Sub webdavcontrol_DirList(ResourceURI As String, DisplayName As String, ContentLanguage As String, ContentLength As Long64, ContentType As String, LastModified As String)
ContentLength is now Long64. In PowerBuilder I see ContentLength as type Any and this what caused the problem, I cannot get the value of ContentLength.
The code which used to be working:
long ll_row
string ls_size
long ll_size
ls_size = contentlength //Does not work anymore
If I do:
ls_size = string (contentlength) // then ls_zise is '', so it returns an empty string
Ok, I tried to do:
LongLong ll_size
ll_size = Long(contentlength) // returns 0
Then I tried:
ll_size = contentlength*1 //runtime error
I tried to modify an argument type in the event painter - change Any to LongLong, String, Long. If I change the type for ContentLength from Any - then the even simply is not fired anymore. I am out of ideas. Any ideas - is it possible to read Any datatype in this situation? I sent a question to the control's vendor and asked to change the argument type back to string, not sure what will be the result.