日期:2009-09-01  浏览次数:21061 次

<HTML>

<script language="VB" runat=server>


Sub UploadBtn_Click(Sender as Object, E as EventArgs)

UploadFile.PostedFile.SaveAs(Server.MapPath("test.jpg"))
MyImage.ImageUrl = "test.jpg"
MyImage.Visible = true

End Sub

</script>

<body>

<form enctype="multipart/form-data" runat=server>

<h3>

Select File To Upload: <input id="UploadFile" type=file runat=server>

<ASP:button Text="Upload Me!" OnClick="UploadBtn_Click" runat=server/>

<hr>

<ASP:image id="MyImage" Visible=false runat=server/>

</form>

</body>
</HTML>