Microsoft KB Archive/57808

From BetaArchive Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

INFO: SizeofResource() Rounds to Alignment Size

Q57808



The information in this article applies to:


  • Microsoft Windows Software Development Kit (SDK)
  • Microsoft Win32 Software Development Kit (SDK)





SUMMARY

SizeofResource() returns the resource size rounded up to the alignment size. Therefore, if you have your own resource types, you cannot use SizeofResource() to get the actual resource byte count.

It has been suggested that this be changed to reflect the actual number of bytes in the resource so that applications can use SizeofResource() to determine the size of each resource. This suggestion is under review and will be considered for inclusion in a future release of the Windows Software Development Kit (SDK).

Additional query words:

Keywords : kbOSWinNT kbOSWin2000 kbResource kbSDKWin32 kbGrpDSUser kbOSWin
Issue type : kbinfo
Technology : kbWin32SDKSearch kbAudDeveloper kbSDKSearch kbWin32sSearch kbWinSDKSearch


Last Reviewed: July 9, 2000
© 2001 Microsoft Corporation. All rights reserved. Terms of Use.