My report works fine on Windows XP, but on Windows 7 it simply displays a
small 1/3" line instead of the BMP image.
Here is my code that I am testing with that has helped me identify the
problem:
1. Create Cursor cur_image(gPic g)
2. APPEND BLANK
3. APPEND GENERAL gpic FROM "C:\Temp\Test.bmp"
4. BROWSE
In XP when I browse and open the General field, I get the image.
In Windows 7 I get an icon. I then must click on the icon I get the image.
I believe Windows 7 is doing the same thing when I run my report.
Does anyone have any helpful advice to get it to work on Windows 7?
Thank you,
Mike Fechter
VFP doesn't do any of the displaying when it comes to general fields.
That is handed off to the Windows ooze where Windows yells "Hey! Who
owns this type?" and whatever software answers is expected to do the
display. As you're seeing, they don't all do it the same way.
You can either muck around with installing other programs hoping one of
them will display your bmp properly, or don't put it in a general field
in the first place. (Put it in a memo field and copy it to disk as
needed. VFP can display BMP files natively!)
Dan
Michael Fechter wrote :
Thanks for the information. I hope you can help me further.
I want to put a logo on a report. It will be dynamic and change with each
customer. I store the logo filename and path in my customer record and simply
read it when I print my report.
1) I put the logo on the report using the OLE Picture/Active X control.
2) I can get the picture from a "File" or "Field" (must be a General field).
I mentioned in my previous post the problem using the "Field" option.
The problem I run into when using the "File" option is, the picture doesn't
dynamically change when I print for a different customer. It prints the same
one for everyone! We speculate that it gets compiled into the report.
Question:
a) Does my appoach sound correct?
b) Is there another way to do it?
c) You mention a memo field, but I'm not sure how I would use it.
d) Is there a way to flush out the image so it will display the new one?
I'm toying with the idea of compiling the report outiside my project with
the hope that it would pull in the logo properly when printing. But this
creates it's own set of issues!
Thank you,
Mike Fechter
But without knowing how you are doing the deed nobody can see where
you're going wrong. Not enough information. Sorry.
Dan
It happens that Michael Fechter formulated :
Mike Fechter
"Dan Freeman" wrote:
> .
>
The problem is that VFP caches the bitmap between the different records,
thus you will always only see the first one. You need to do a CLEAR RESOURCE
between each record to get the new one.
--
wOOdy
Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" 1996 to 2009
"*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
..·`.Visual FoxPro: It's magic !
(¸.·``··*