Getting PBL comment in Powerscript

Back Up Next

Author: Eric Aling (18 aug 1999)
Accessed:

This is a pretty simple request but there's no way to get this done through native PowerBuilder calls or via ORCA. The answer is pretty simple though because this information is stored in the first line of the PBL, on a specific location. So, the following code will read the first 32K of the PBL, and get the information of position 29 and further.

long ll_fp
blob lbl_line
ll_fp = fileopen('yourpbl.pbl',streammode!)

fileread(ll_fp, lbl_line)
fileclose(ll_fp)

messagebox(string(len(lbl_line)),string(blobmid(lbl_line,29)))

Simple, but it works.

Back Up Next