Share via


WMRMKeys.GenerateKeyEx

banner art

Previous Next

WMRMKeys.GenerateKeyEx

The GenerateKeyEx method creates a content key of a specific length, which is used to encrypt content.

Syntax

  String
  
  =
  
  WMRMKeys
  .GenerateKeyEx(
  lReqLen
  )

Parameters

lReqLen

[in] Long integer containing the required length of the content key, in bytes.

Return Values

If the method succeeds, it returns a String containing the content key. If it fails, it returns a number in the error object.

Return code Description
0x80004005 An unspecified error occurred.
0x80070057 The specified parameter is not valid.

Remarks

After setting the WMRMKeys.KeyID and WMRMKeys.Seed properties, call the GenerateKeyEx method to generate an 8-byte key for the root license in a license chain.

Requirements

Version: Windows Media Rights Manager 7 SDK or later

Reference: wmrmobjs 1.0 Type Library

Library: wmrmobjs.dll

Platform: Windows Server 2003

See Also

Previous Next

© 2007 Microsoft Corporation. All rights reserved.