powerbuilderpowerbuilder-build-deploy

Images powerbuilder


I am about to compile my PBL to a working PBD. My problem is how can I call the image folder properly. e.g. Toolbars, icons, pictures of some command buttons properly and dynamically. For example I installed mine at C:\MyProgram\ but when my users they will put it in C:\Program Files\HisProgram .. do i have to state that the images should be in the same place as I do. C:\images\ because now I am having missing toolbar icons when i tried it on my test machine. i tried the resource pbr but it also must define the proper location of the image. Any techniques you could refer me to?

i tried the GetCurrentDirectory() but i was looking for a much more suitable way

GetCurrentDirectory Link i found http://www.pbsql.info/2011/01/relative-path-to-images-problem-in.html


Solution

  • No need to wonder about the current directory, you can just use a relative path in the pbr file.

    For example, put all your pictures into the resource folder and in the pbr, you can refer to resource\image.jpg and so on, without need to refer to c:\project\resource\image.jpg.