Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to avoid GPF when assigning lots of data to String or Blob

Status
Not open for further replies.

miguelleeuwe

Programmer
Oct 17, 2007
242
NL
A string or Blob can hold quite a lot of data.
The problem I've been having in more than one application over the years is that there seems to be no way at all in powerbuilder to make sure your assignment of data to string or blob will end successfully. It'll work or it'll GPF.

In C (the language pb is written in if I'm not wrong), you can do a MemAlloc() for example that'll garantee the success of your assignment. In powerbuilder there seems to be a sort of 'HEAP' of memory that pb gets from windows (process that can't be controlled by programmer if not wrong) and that is the memory used when working with data. It's not like you can check windows' free memory amount and be sure there's enough. There probably will be enough free memory in windows, but your memory assignment will likely 'GPF' when passing limits like 400 MB/ 600MB, while having 2 GB of free memory in windows.

Something that really makes me wonder why pb still hasn't given us a solution.

¿Am I missing something, since this must be a problem to lots of programmers?

Any help/information is appreciated,

miguel Leeuwe

regards,
Miguel L.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top