0
votes

I am facing really strange problem in my vb6 Application. It is working fine on every other machines but when I run it on my client's machine, Images do not show properly.

This is how problem looks like demonstrationSpecifications:

Windows 8 Pro (6.2 Build 9200) 32 Bit
Processor Architecture 64 Bit
Core 2 Duo T9600 2.80 Ghz
Dell Latitude 6400.

I have deployed the same application on many other machines and tested on different resolutions with different Operating systems. Everywhere it is working prefect. but not working properly on client's Machine.

1
How are you setting the size of the image control?Boann
Is desktop scaling in use on either PC?Rowland Shaw
try change the resolution of the client's screen as yours..Nadeem_MK

1 Answers

6
votes

Without more information it is hard to be sure, but here is a guess:

Starting in Windows 7, if the system notices you have a monitor with excessive resolution it automatically chooses a high DPI setting.

If your program is not DPI-aware then one of several forms of appcompat are applied (based on the version of Windows, some system options, and application characteristics). Depending on which remediation is attempted by Windows, bitmap graphics can end up scaled and pixelated or not scaled and show as "smaller than expected."

Just to add fuel to the fire, people often try to do UI layout using ScaleMode = vbPixels and/or manual conversions and rely on a fixed ratio between these virtual pixels and actual screen metrics. Hard-coding 15 Twips/Pixel (1440/96) is very common because 96 DPI VGA (and VGA-derivative) square-pixeled screens were in use for a long time.

This fallacy can cause such a program to size controls improperly even when others get resized by the DPI remediation.

You might try reading though High DPI for information on this subject.

In the case of something like a Form backdrop image you either need several bitmaps of varying sizes from which you choose at runtime or else you'll need to scale the image yourself.