国产成人精品亚洲777人妖,欧美日韩精品一区视频,最新亚洲国产,国产乱码精品一区二区亚洲

您的位置:首頁技術文章
文章詳情頁

手把手教你使用Java來編寫ASP組件(2)

瀏覽:41日期:2024-03-01 17:54:30
5、 雙擊JavaASP.java,會出現一個代碼框,把下面的代碼輸入代碼框,并保存。import com.ms.iis.asp.*;import com.ms.mtx.*;這兩句應當出現在程序的最前面,它們是導入命令,導入我們在工程中需要用到的某些Java類的包,我下面給出完整的程序/** * This class is designed to be packaged with a COM DLL output format. * The class has no standard entry points, other than the constructor. * Public methods will be exposed as methods on the default COM interface. * @com.register ( clsid=ADE14872-9CF6-42A0-A8F2-7A571E51A840, typelib=5E11D496-7229-4283-A40B-139E05DEF44C ) */ //上面我們看到一個clsid,它是用來標記微軟COM組件所用的。import com.ms.iis.asp.*;//導入兩個包import com.ms.mtx.*;public class JavaASP { public boolean HelloWorld() {Response newRes = AspContext.getResponse();//創建一個ResponsenewRes.write("Hello World,Maybe it is your first JavaASP COM!");return true; }}
標簽: Java
主站蜘蛛池模板: 长治市| 星座| 宜丰县| 博湖县| 汉川市| 浦县| 漠河县| 恩施市| 昭通市| 罗田县| 武冈市| 定州市| 清徐县| 蒙自县| 山东| 剑川县| 河源市| 西林县| 沈丘县| 通城县| 河北区| 旬阳县| 隆昌县| 饶河县| 墨竹工卡县| 田东县| 平泉县| 武乡县| 长乐市| 惠东县| 天津市| 利川市| 濮阳县| 保康县| 涞源县| 平罗县| 涞源县| 和田市| 长沙县| 越西县| 铁力市|