Simple process of ActiveX control from creation to reference

Source: Internet
Author: User

In the form of. net, the original COM technology still has its own unique use. I recently saw this post on csdn, which is also very enlightening.

Hjk1 ():Recently, the project needs to process data transmitted from devices through serial ports on the client. I think this project can only be made into a C/S structure, because all the business logic of the B/S structure is on the server, it is impossible to receive data from the serial port of the device directly connected to the client. At first, the boss agreed with me,

Zhilunchen (heshan jushi): Boss, this stuff can be implemented! I have successfully read and written the IC card through the card reader (Serial Port) on the client (B/S!
The method is to first encapsulate the code for reading and writing the serial port into a COM component, and then call the COM Component Interface on the client through Js.

At first, I also agreed with the idea of hjk1 (), which is difficult to implement in B/S. But I can see the reply below, so I won't be satisfied with it. I think back to my previous projects, in fact, this method has been used. COM component + JavaScript method. So you can try it yourself. Create an ActiveX control with VB6.0, and then register the control with regsvr32. net to create a web application, select Add COM component in the tool panel, and drag and drop the ActiveX control from the tool panel to the page, this completes a simple process from creation to reference. You can complete a lot of functions in your ActiveX control and provide the method for calling the foreground script Js.

 

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.