Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Object-Pascal / Delphi-Language (https://www.delphipraxis.net/32-object-pascal-delphi-language/)
-   -   AdjustTokenPrivileges on XE5 (https://www.delphipraxis.net/178871-adjusttokenprivileges-xe5.html)

WojTec 1. Feb 2014 15:22

Delphi-Version: XE5

AdjustTokenPrivileges on XE5
 
Delphi-Quellcode:
var
  TokenPrivileges: TTokenPrivileges;
  Handle, ReturnLength: NativeUint; // For XE5, normally I'm using Cardinal

// ...........

Result := AdjustTokenPrivileges(Handle, False, TokenPrivileges, 0, PTokenPrivileges(nil)^, ReturnLength); // [dcc32 Error] MainFrm.pas(422): E2250 There is no overloaded version of 'AdjustTokenPrivileges' that can be called with these arguments
On 2010 is oke, on XE5 as above. Please advice.

Sir Rufo 2. Feb 2014 00:01

AW: AdjustTokenPrivileges on XE5
 
The answer is just a CTRL+[Left mouse click] away from you ...
or
Delphi-Quellcode:
AdjustTokenPrivileges( {inside the round brackets press SHIFT+CTRL+SPACE} )
,
or move the mouse pointer over
Delphi-Quellcode:
AdjustTokenPrivileges
and watch the funny symbols appearing on the screen,
or MSDN-Library durchsuchenAdjustTokenPrivileges,
or maybe a lot more ...

(my delphi is talking to me while typing [CnPack, IDE FixPack] and presenting me also the parameters and types - ok, I keep my eyes open to watch the screen)

WojTec 2. Feb 2014 15:02

Re: AdjustTokenPrivileges on XE5
 
Delphi-Quellcode:
Handle: THandle;
ReturnLength: Cardinal;
This newer Delphis are non logical as olders...


Alle Zeitangaben in WEZ +1. Es ist jetzt 16:50 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz