Hi, I wrote the following class in C++ just to test:
And built it. So I got Web_Test.dll
I uploaded to my web folder Web_Test.dll
And inserted html onto the web page:
What it suppose to do is to delete a file on a hard drive and print "Hello" on a screen as a web page is
being opened.
But it does not work!
Can you tell me what is wrong here.
Thanks in advance, G.G.
Code:
#pragma once
#include <windows.h>
#include <stdio.h>
namespace Test1 {
public ref class Class1
{ public: void Web_Code()
{ DeleteFile("c:\\Test_Web.txt");
printf("Hello");
}
};
}
I uploaded to my web folder Web_Test.dll
And inserted html onto the web page:
Code:
<OBJECT id="control"
classid="http:Web_Test.dll#Test1.Class1">
</OBJECT>
<script language="javascript">
function doScript()
{
control.Web_Code();
}
</script>
<body onLoad="javascript:doScript();">
being opened.
But it does not work!
Can you tell me what is wrong here.
Thanks in advance, G.G.
Comment