Whats wrong with using the Anchor property? The functionality you are having
a problem with is perfectly OK, if it did anything else, it would be a bug.
It is annoying you can't specify no border on the listview, but to get around
this you simply draw the control outside of the viewable client area. The
Anchor and Dock are pretty much the same except the Anchor allows more
control.
In terms of border width, on hi-res devices, the border will not be 1px
probably 2px. To calculate this simply use: [val] * [dpi] / [designDPI].
See if this helps:
http://simonrhart.blogspot.com/2007/10/targeting-both-vga-and-qvga-screens.html

Signature
Simon Hart
Visual Developer - Device Application Development MVP
http://simonrhart.blogspot.com
> > It's not wider (although it appears wider) it's the fact that the
> > listview is drawing a 1px border on each side which is giving the
[quoted text clipped - 17 lines]
>
> ----Scott.
Scott Gifford - 27 May 2008 16:24 GMT
Thanks for your answer Simon,
> Whats wrong with using the Anchor property? The functionality you
> are having a problem with is perfectly OK, if it did anything else,
> it would be a bug. It is annoying you can't specify no border on
> the listview, but to get around this you simply draw the control
> outside of the viewable client area. The Anchor and Dock are pretty
> much the same except the Anchor allows more control.
Since Anchor is based on counting pixels from the edges of the screen
and Dock is more policy based, I expected Dock to do a better job of
automatically adapting to different-sized screens, saving me from
having to do things like the DPI calculation you describe below. But
I can certainly use Anchor if that's the best option.
> In terms of border width, on hi-res devices, the border will not be
> 1px probably 2px. To calculate this simply use: [val] * [dpi] /
> [designDPI].
>
> See if this helps:
> http://simonrhart.blogspot.com/2007/10/targeting-both-vga-and-qvga-screens.html
Thanks, I didn't know about the device DPI stuff, I'll keep it in
mind while doing GUI development!
----Scott.
Scott Gifford - 28 May 2008 20:31 GMT
[...]
> In terms of border width, on hi-res devices, the border will not be 1px
> probably 2px. To calculate this simply use: [val] * [dpi] / [designDPI].
Should the value of [dpi] / [designDPI] be equal to Form.AutoScaleFactor?
Thanks!
----Scott.