PHP and COM

Source: Internet
Author: User
Tags unsupported
PHP can operate COM and DCOM objects on Win32 platforms. 1. I have created a DLL to calculate something. Is there any way to run this DLL in PHP? 2. what does Unsupportedvarianttype: xxxx (0 xxxxx) mean? 3. is it possible to operate on visual objects in PHP? 4. SyntaxHighli

PHP can operate COM and DCOM objects on Win32 platforms. 1. I have created a DLL to calculate something. Is there any way to run this DLL in PHP? 2. what does Unsupported variant type: xxxx (0 xxxxx) mean? 3. is it possible to operate on visual objects in PHP? 4. can I store COM objects in the session? 5. how can I capture COM errors? 6. how can I generate DLL files in PHP, just as I did in Perl? 7. what does Unable to obtain IDispatch interface for CLSID {xxxxxxxx-xxxx-xxxxxxxxxx} mean? 8. how can I run COM objects from a remote server? 9. I got the message: DCOM is disabled in C: path... scriptname. php on line 6. what should I do? 10. can ActiveX objects be loaded on the PHP page? 11. can I get a COM runtime instance? 12. Is there a way to handle events sent from COM objects? 13. I encountered an error when calling a COM object (with multiple interfaces) method. what should I do? 14. PHP can work on COM. what about COM +? 15. can PHP operate on COM objects? can we use MTS to manage component resources and PHP? 1. I created a DLL to calculate something. Is there any way to run this DLL in PHP? You cannot operate simple DLL in PHP. if the DLL contains the COM server and implements the IDispatch interface, you can operate it. 2. unsupported variant type: xxxx (0 xxxxx? There are many VARIANT types and their collections. the vast majority have been supported, but a few do not. arrays are not fully supported. only one-dimensional arrays are supported. if you still find unsupported data types: Send a bug report (if no report is available) and provide as much information as possible. 3. is it possible to operate on visual objects in PHP? It is usually possible. however, PHP is mostly used to run scripts on web server devices, and visualization objects never appear on the server desktop. if you use PHP as an application script such as a PHP-GTK, there is no limit to operating visualization objects through COM. 4. can I store COM objects in the session? No. COM instances are considered resources. Therefore, they can only work in a single script program. 5. how can I capture COM errors? No other tools can be used to track COM errors, except PHP (@, track_errors ,..), we are considering a method to implement it. 6. I can generate DLL files in PHP, just like what I do in Perl? No. Unfortunately, there is no such PHP tool. 7. Unable to obtain IDispatch interface for CLSID {xxxxxxxx-xxxx-xxxxxxxxxxxx? There are many reasons for this error: The CLSID number is incorrect. the DLL component where COM is not found has not implemented the IDispatch interface 8. how can I run COM objects from a remote server? Just like running a local object. you only need to pass the remote IP address as the second parameter to the COM constructor. confirm your php. com. allow_dcom = true. 9. I got the message: DCOM is disabled in C: path... scriptname. php on line 6, what should I do? Edit the php. ini file and set com. allow_dcom = true. 10. can ActiveX objects be loaded on the PHP page? This should be unrelated to PHP. activeX is a client object called by HTML pages. it has no direct relationship with PHP scripts. of course, there is no possibility of direct server interaction. 11. can I get a COM runtime instance?? Monikers can be used to implement this function. to obtain multiple references of the same Word instance, use the following code: that instance like shown: $ word = new COM ("C: docsword.doc ");

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.