I managed to create a small activex control, but this requires that the DLL be registered on the client (using regasm).
How can I avoid this registration problem?
I am trying to write an activex control that is delivered over the Internet (to IE browsers) that will access the clients webcam (using directshow).
Here is my simple control:
using System;
using System.Runtime.InteropServices;
namespace HelloNS
{
public interface IHello
{
string Message();
}
[ClassInterface(ClassInterfaceType.AutoDual)]
public class Hello : IHello {
public string Message()
{
return "hello";
}
}
}
And here is my viewer:
<html>
<head>
<script language="javascript">
var x = new ActiveXObject("HelloNS.Hello");
alert(x.Message());
</script>
</head>
<body>
</body>
</html>
I am currently reading this on msdn: http://msdn.microsoft.com/en-us/library/aa751970(VS.85).aspx
If I find out, I will post the results.
source
share