|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2007-06-24 14:26 UTC] mona dot arabi at yahoo dot co dot uk
Description:
------------
i can't instanciate an object from .net
Reproduce code:
---------------
<?
$test = new DOTNET("System", "System.Diagnostics.Process");
?>
WHILE
?php
$stack = new DOTNET("mscorlib", "System.Collections.Stack");
$stack->Push(".Net");
$stack->Push("Hello ");
echo $stack->Pop() . $stack->Pop();
?>
WORKING
Expected result:
----------------
CREATING AN OBJECT TO PROCESS
Actual result:
--------------
Fatal error: Uncaught exception 'com_exception' with message 'Failed to instantiate .Net object [CreateInstance] [0x80070002] The system cannot find the file specified. ' in C:\webs\test\index.php:7 Stack trace: #0 C:\webs\test\index.php(7): dotnet->dotnet('System', 'System.Diagnost...') #1 {main} thrown in C:\webs\test\index.php on line 7
my php
PHP 5.2.3 (cli) (built: may 31 2007 09:37:22)
copyright (c) 1997-2007 THE PHP GROUP
Zend Engin v2.2.0 , copyright(c)1998-2007 zend Technologies.
Apache/2.0.59 (Win32)
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 10:00:01 2025 UTC |
i mean that this code is working ?php $stack = new DOTNET("mscorlib", "System.Collections.Stack"); $stack->Push(".Net"); $stack->Push("Hello "); echo $stack->Pop() . $stack->Pop(); ?> but this <? $test = new DOTNET("System", "System.Diagnostics.Process"); ?> generate Fatal error: Uncaught exception 'com_exception' with message 'Failed to instantiate .Net object [CreateInstance] [0x80070002] The system cannot find the file specified. ' in C:\webs\test\index.php:7 Stack trace: #0 C:\webs\test\index.php(7): dotnet->dotnet('System', 'System.Diagnost...') #1 {main} thrown in C:\webs\test\index.php on line 7<?php $stack = new DOTNET("mscorlib", "System.Collections.Stack"); $stack->Push(".Net"); $stack->Push("Hello "); echo $stack->Pop() . $stack->Pop(); ?> is no longer working either in 5.3.1 <? $test = new DOTNET("System", "System.Diagnostics.Process"); ?> This also still fails in 5.3.1 -- it appears as though DOTNET functionality is not going to be fixed, there are numerous bug reports and no activity.