This article was previously published under Q274723
This article has been archived. It is offered "as is" and will no longer be updated.
There is an issue that involves the use of the FindUser method on the DiskQuota scripting object. When a logon name is provided for a user whose SID-Name pair is not yet in the operator's SID-Name cache, the FindUser method returns HRESULT_FROM_WIN32 (ERROR_FILE_NOT_FOUND) rather than S_OK as documented in the Software Development Kit (SDK).
The problem is in the C++ IDiskQuotaControl::FindUserName method and the corresponding scripting FindUser method, both of which are implemented in Dskquota.dll.
If the logon name that is provided to the method is for a valid user but there is no entry in the disk quota SID-Name cache for that user, the method returns HRESULT_FROM_WIN32 (ERROR_FILE_NOT_FOUND) rather than S_OK as documented in the SDK. If there is an entry in the SID-Name cache for that user, the method returns S_OK as required.
To resolve this problem, obtain the latest service pack for Windows 2000. For additional information, click the following article number to view the article in theMicrosoft Knowledge Base:
260910 How to Obtain the Latest Windows 2000 Service Pack
You can call the DiskQuota scripting TranslateLogonNameToSid method to obtain a SID string for the user. That string can be passed to "FindUser" rather than the name. This results in "FindUser" succeeding with S_OK.
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article. This problem was first corrected in Windows 2000 Service Pack 2.
This issue does not affect users of the Windows 2000 Disk Quota tool. It may affect developers or system administrators who want to use this call in the development of a quota tool or in script-based management.