Register Register Member Login Member Login Member Login Forgot Password ??
PHP , ASP , ASP.NET, VB.NET, C#, Java , jQuery , Android , iOS , Windows Phone
 

Registered : 109,027

HOME > ASP.NET > ASP.NET Web Control - Standard Control > ASP.NET FileUpload - asp:FileUpload



Clound SSD Virtual Server

ASP.NET FileUpload - asp:FileUpload

ASP.NET FileUpload เป็นคอนโทรลใช้ในการอัพโหลดไฟล์ (Upload files)

Language Code : VB.NET || C#

ASP.NET FileUpload

Framework : 2,3,4

Syntax

<asp:FileUpload id="[Name]" runat="server"></asp:FileUpload>


Declarative Syntax
<asp:FileUpload
    AccessKey="string"
    BackColor="color name|#dddddd"
    BorderColor="color name|#dddddd"
    BorderStyle="NotSet|None|Dotted|Dashed|Solid|Double|Groove|Ridge|
        Inset|Outset"
    BorderWidth="size"
    CssClass="string"
    Enabled="True|False"
    EnableTheming="True|False"
    EnableViewState="True|False"
    Font-Bold="True|False"
    Font-Italic="True|False"
    Font-Names="string"
    Font-Overline="True|False"
    Font-Size="string|Smaller|Larger|XX-Small|X-Small|Small|Medium|
        Large|X-Large|XX-Large"
    Font-Strikeout="True|False"
    Font-Underline="True|False"
    ForeColor="color name|#dddddd"
    Height="size"
    ID="string"
    OnDataBinding="DataBinding event handler"
    OnDisposed="Disposed event handler"
    OnInit="Init event handler"
    OnLoad="Load event handler"
    OnPreRender="PreRender event handler"
    OnUnload="Unload event handler"
    runat="server"
    SkinID="string"
    Style="string"
    TabIndex="integer"
    ToolTip="string"
    Visible="True|False"
    Width="size"
>
</asp:FileUpload>


Sample

FileUpload.aspx

<%@ Page Language="VB" %>
<script runat="server">

    Sub btnSubmit_Click(sender As Object, e As EventArgs)
        If Me.fiUpload.HasFile Then
            Me.fiUpload.SaveAs(Server.MapPath("Myfiles/"&fiUpload.FileName))
            Me.lblText1.Text = "File Name: " & fiUpload.PostedFile.FileName
            Me.lblText2.Text = "File Size: " & fiUpload.PostedFile.ContentLength
            Me.lblText3.Text = "File Type: " & fiUpload.PostedFile.ContentType
        End IF
    End Sub

</script>
<html>
<head>
</head>
<body>
    <form runat="server">
        <asp:FileUpload id="fiUpload" runat="server"></asp:FileUpload>
        <asp:Button id="btnSubmit" onclick="btnSubmit_Click" runat="server" Text="Submit"></asp:Button>
        <hr />
        <asp:Label id="lblText1" runat="server"></asp:Label>
        <br>
        <asp:Label id="lblText2" runat="server"></asp:Label>
        <br>
        <asp:Label id="lblText3" runat="server"></asp:Label>
    </form>
</body>
</html>









Screenshot

ASP.NET Web Control

ASP.NET Web Control

ASP.NET Web Control




ASP.NET WebMatrix - Control & Element

ASP.NET & Visual Studio .Net 2003 - Control & Element

ASP.NET & Visual Studio 2005,2008 - Control & Element

ASP.NET & Visual Studio 2010 - Control & Element

   
Share


ช่วยกันสนับสนุนรักษาเว็บไซต์ความรู้แห่งนี้ไว้ด้วยการสนับสนุน Source Code 2.0 ของทีมงานไทยครีเอท


ลองใช้ค้นหาข้อมูล


   


Bookmark.   
       
  By : ThaiCreate.Com Team (บทความเป็นลิขสิทธิ์ของเว็บไทยครีเอทห้ามนำเผยแพร่ ณ เว็บไซต์อื่น ๆ)
  Score Rating :  
  Create/Update Date : 2008-11-05 18:11:49 / 2017-03-28 20:42:44
  Download : Download  ASP.NET FileUpload - asp:FileUpload
 Sponsored Links / Related

 
ASP.NET Web/Standard Control
Rating :

 
ASP.NET Button - asp:Button
Rating :

 
ASP.NET AdRotator - asp:AdRotator
Rating :

 
ASP.NET Calendar - asp:Calendar
Rating :

 
ASP.NET Checkbox - asp:CheckBox
Rating :

 
ASP.NET CheckboxList - asp:CheckBoxList
Rating :

 
ASP.NET DropDownlist - asp:DropDownList
Rating :

 
ASP.NET HyperLink - asp:HyperLink
Rating :

 
ASP.NET Image - asp:Image
Rating :

 
ASP.NET ImageButton - asp:ImageButton
Rating :

 
ASP.NET Label - asp:Label
Rating :

 
ASP.NET LinkButton - asp:LinkButton
Rating :

 
ASP.NET ListBox - asp:ListBox
Rating :

 
ASP.NET Literal - asp:Literal
Rating :

 
ASP.NET Panel - asp:Panel
Rating :

 
ASP.NET RadioButton - asp:RadioButton
Rating :

 
ASP.NET RadioButtonList - asp:RadioButtonList
Rating :

 
ASP.NET Table - asp:Table
Rating :

 
ASP.NET TableCell - asp:TableCell
Rating :

 
ASP.NET TableRow - asp:TableRow
Rating :

 
ASP.NET TextBox - asp:TextBox
Rating :

 
ASP.NET ImageMap - asp:ImageMap
Rating :

 
ASP.NET BulletedList - asp:BulletedList
Rating :

 
ASP.NET HiddenField - asp:HiddenField
Rating :

 
ASP.NET PlaceHolder - asp:PlaceHolder
Rating :

 
ASP.NET Xml - asp:Xml
Rating :

 
ASP.NET MultiView - asp:MultiView
Rating :

 
ASP.NET View - asp:View
Rating :

 
ASP.NET Wizard - asp:Wizard
Rating :


ThaiCreate.Com Forum


Comunity Forum Free Web Script
Jobs Freelance Free Uploads
Free Web Hosting Free Tools

สอน PHP ผ่าน Youtube ฟรี
สอน Android การเขียนโปรแกรม Android
สอน Windows Phone การเขียนโปรแกรม Windows Phone 7 และ 8
สอน iOS การเขียนโปรแกรม iPhone, iPad
สอน Java การเขียนโปรแกรม ภาษา Java
สอน Java GUI การเขียนโปรแกรม ภาษา Java GUI
สอน JSP การเขียนโปรแกรม ภาษา Java
สอน jQuery การเขียนโปรแกรม ภาษา jQuery
สอน .Net การเขียนโปรแกรม ภาษา .Net
Free Tutorial
สอน Google Maps Api
สอน Windows Service
สอน Entity Framework
สอน Android
สอน Java เขียน Java
Java GUI Swing
สอน JSP (Web App)
iOS (iPhone,iPad)
Windows Phone
Windows Azure
Windows Store
Laravel Framework
Yii PHP Framework
สอน jQuery
สอน jQuery กับ Ajax
สอน PHP OOP (Vdo)
Ajax Tutorials
SQL Tutorials
สอน SQL (Part 2)
JavaScript Tutorial
Javascript Tips
VBScript Tutorial
VBScript Validation
Microsoft Access
MySQL Tutorials
-- Stored Procedure
MariaDB Database
SQL Server Tutorial
SQL Server 2005
SQL Server 2008
SQL Server 2012
-- Stored Procedure
Oracle Database
-- Stored Procedure
SVN (Subversion)
แนวทางการทำ SEO
ปรับแต่งเว็บให้โหลดเร็ว


Hit Link
   







Load balance : Server 02
ThaiCreate.Com Logo
© www.ThaiCreate.Com. 2003-2024 All Rights Reserved.
ไทยครีเอทบริการ จัดทำดูแลแก้ไข Web Application ทุกรูปแบบ (PHP, .Net Application, VB.Net, C#)
[Conditions Privacy Statement] ติดต่อโฆษณา 081-987-6107 อัตราราคา คลิกที่นี่