in the aspx page:
<asp:FileUpload ID="FileUpload1" runat="server" />
in the codebehind (c#):
string contentType = FileUpload1.PostedFile.ContentType
More Related Contents:
- Building a menu similar to stackoverflow [closed]
- A potentially dangerous Request.Form value was detected from the client
- ASP.NET MVC – Set custom IIdentity or IPrincipal
- Returning binary file from controller in ASP.NET Web API
- Store pictures as files or in the database like MSSQL for a web app?
- How do I get the current location of an iframe?
- ‘Operation is not valid due to the current state of the object’ error during postback
- How can I implement Ninject or DI on asp.net Web Forms?
- How to retrieve form values from HTTPPOST, dictionary or?
- IIS Request Timeout on long ASP.NET operation
- Why order matters in this RegEx with alternation?
- IIS URL Rewriting vs URL Routing
- Is there a way to force ASP.NET Web API to return plain text?
- HTTPS with Visual Studio’s built-in ASP.NET Development Server
- Unmanaged DLLs fail to load on ASP.NET server
- Preventing CSRF with the same-site cookie attribute
- Pagemethods in asp.net
- What SqlDbType maps to varBinary(max)?
- Log4net does not write the log in the log file
- How to return raw string with ApiController?
- Can SignalR be used with asp.net WebForms?
- Stopping onclick from firing when onclientclick is false?
- Profiling ASP.NET websites with EQATEC Profiler
- ASP.NET MVC ViewModel Pattern
- How to POST a FORM from HTML to ASPX page
- How to configure SMTP settings in web.config
- how to submit query to .aspx page in python
- The entry ” has already been added error
- What is the difference between AsyncPostBackTrigger & PostBackTrigger?
- DataBinding: ‘System.Data.DataRowView’ does not contain a property with the name