Re: Struck with CopyMemory API
- From: "Mike D Sutton" <EDais@xxxxxxxx>
- Date: Fri, 22 Jul 2005 20:51:07 +0100
> There is one of two possible problems here. Is pDevMode a pointer or a UDT?
>From a prior post in the thread:
<quote>
Dim pDevMode as DEVMODE
</quote>
> If it is not a pointer, then the only problem is that the name (the "p"
> prefix) implies it is; however that is only a convention; VB and Windows of
> course do not care. If pDevMode is not a pointer, it is important to ensure
> that it is not used as a pointer anywhere. The "p" prefix can cause
> confusion.
The original MSDN example code was more than likely originally ported from C++ source where the type would have been
declared as "DEVMODE* pDevMode;", Microsoft's example VB code has never been particularly good though and many of the
API oriented examples look like ported code rather than being working up in VB from scratch.
FWIW,
Mike
- Microsoft Visual Basic MVP -
E-Mail: EDais@xxxxxxxx
WWW: Http://EDais.mvps.org/
.
- Follow-Ups:
- Re: Struck with CopyMemory API
- From: Sam Hobbs
- Re: Struck with CopyMemory API
- References:
- Struck with CopyMemory API
- From: Electronic Screw
- Re: Struck with CopyMemory API
- From: Karl E. Peterson
- Re: Struck with CopyMemory API
- From: Mike D Sutton
- Re: Struck with CopyMemory API
- From: Karl E. Peterson
- Re: Struck with CopyMemory API
- From: Electronic Screw
- Re: Struck with CopyMemory API
- From: Mike D Sutton
- Re: Struck with CopyMemory API
- From: Electronic Screw
- Re: Struck with CopyMemory API
- From: Sam Hobbs
- Struck with CopyMemory API
- Prev by Date: Re: How to Implement an Idle Period Timeout?
- Next by Date: Re: How to Implement an Idle Period Timeout?
- Previous by thread: Re: Struck with CopyMemory API
- Next by thread: Re: Struck with CopyMemory API
- Index(es):
Relevant Pages
|