Edit report at https://bugs.php.net/bug.php?id=51205&edit=1
ID: 51205 Updated by: php-bugs@lists.php.net Reported by: zelnaga at gmail dot com Summary: Fatal error: com_exception: The parameter is incorrect -Status: Feedback +Status: No Feedback Type: Bug Package: COM related Operating System: Windows XP PHP Version: 5.3.1 New Comment: No feedback was provided. The bug is being suspended because we assume that you are no longer experiencing the problem. If this is not the case and you are able to provide the information that was requested earlier, please do so and change the status of the bug back to "Open". Thank you. Previous Comments: ------------------------------------------------------------------------ [2010-06-24 10:57:52] T-K-N at gmail dot com I too was using DOTNET when I got this error. After trying the suggested solution using this code: $arr = array(1); $var = new VARIANT($arr, VT_UI1|VT_ARRAY); I got this error: Variant type conversion failed: Type mismatch. ------------------------------------------------------------------------ [2010-04-12 02:20:01] ka...@php.net You cannot use VT_ARRAY as the only type sent to VARIANT's ctor. VT_ARRAY is a flag that needs to be OR'd with another type, e.g.: $variant = new VARIANT($..., VT_UI1 | VT_ARRAY); ------------------------------------------------------------------------ [2010-03-26 18:47:12] zelnaga at gmail dot com the $rng->GetBytes($v); line. ------------------------------------------------------------------------ [2010-03-15 15:27:30] ka...@php.net In what line does this happen? ------------------------------------------------------------------------ [2010-03-04 22:31:57] zelnaga at gmail dot com Description: ------------ Hi, I need to use RNGCryptoServiceProvider in PHP. I have tried: $rng = new DOTNET("mscorlib", "System.Security.Cryptography.RNGCryptoServiceProvider"); $arr = array(0); $v = new VARIANT($arr,VT_ARRAY); $rng->GetBytes($v); unset($rng); The component loads fine. But I got this error: Fatal error: Uncaught exception 'com_exception' with message 'Error [0x80070057] The parameter is incorrect. Any ideas? ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=51205&edit=1