We help IT Professionals succeed at work.

Set picCoupon.FormattedPicture = LoadPicture(App.Path & "\Coup20.bmp")

SatnamGambhir
on
Hello there,

Using RDC object model within PowerBuilder at runtime I would like to know is there a way to set an image ?

In VB it's possible using following line of code :
Set picCoupon.FormattedPicture = LoadPicture(App.Path & "\Coup20.bmp")

If I were to do this using PowerBuilder I would I do it ? What is the PowerBuilder equivalent function of LoadPicture. Somehow at runttime we are unable to set an image.

Thanks in advance.
SPS
Comment
Watch Question

Mike McCrackenSenior Consultant
CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2013

Commented:
Can you call VB functions from PowrBuilder?

The LoadPicture funstion is part of the VB environment.

What version of Crystal?  CR XI allows you to store the directory path to the picture in the database and simply retrieve it with Crystal.

mlmcc

Author

Commented:
Hello mimcc,

We can't call vb function from PB. The other issue is this needs to be done from Section_Formatted event as well which may not be possible from the PowerBulder.

We are using CR 10 advanced version. Is there a way we can fetch these details from the DB in this version ? Could you help us with the steps ?

Thanks
SPS
Mike McCrackenSenior Consultant
CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2013

Commented:
I don't know enough about PB so,sorry I can't help.  I thought perhapsyou could call an external function in a dll.

It may not be possible.

mlmcc

Author

Commented:
Hi,
I can call external function from PB but need to know is there a way to simulate VBs Section_Format event without PowerBuilder ?

Thanks
SPS
Senior Consultant
CERTIFIED EXPERT
Most Valuable Expert 2011
Top Expert 2013
Commented:
It is actually the Crystal format event that fires.

There is probably no way to do that.

mlmcc

Author

Commented:
I would have really liked to know if CR triggers format event within PB as well. It could be PB event or windows event but trigger by CR's format event.

Explore More ContentExplore courses, solutions, and other research materials related to this topic.