Solved

Problem with HTMLInputFile

Posted on 2004-09-07
6
474 Views
Last Modified: 2008-02-01
Hi!

I'm trying to edit a script made by someone else.

The problem I'm having is that the fileupload module doesn't work?

It says that the value property in HTMLInputFile not can be set.

Where should I look for answers?

Thanks!
0
Comment
Question by:Hermund
6 Comments
 
LVL 18

Expert Comment

by:DotNetLover_Baan
ID: 11998425
Need more details... What is "HTMLInputFile" ? How are you using that ? Need some code to...
-Baan
0
 
LVL 15

Accepted Solution

by:
Thogek earned 500 total points
ID: 11999503
The HtmlInputFile.Value Property appears to be read-only:

http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemwebuihtmlcontrolshtmlinputfileclassvaluetopic.asp

"Note   The Value property is read-only. If you attempt to assign a value to this property, a System.NotSupportedException is thrown."
0
 
LVL 15

Expert Comment

by:Thogek
ID: 11999517
Silly question: Why would you want to modify the property that stores "the full path of the file on the client's computer" anyway?
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 15

Expert Comment

by:Timbo87
ID: 12000632
Yes, it's an HTML limitation/feature. No custom control or fancy code can circumvent that.
0
 
LVL 15

Expert Comment

by:Thogek
ID: 12002225
Well, the HtmlInputFile.Value property contains the path of the submitted file indicated where _on the client's computer_ it is located.  Client.  As is browser.  Not something the server should have any need or reason to want to change, since it's only indicating where the file came from -- not where it's going or anything else relevant to its handling on the server.

Hence my question above: What it is that you are trying to do that led you to try modifying the HtmlInputFile.Value property?  (If we understand that, perhaps we can suggest an alternative way to do it.)
0
 

Author Comment

by:Hermund
ID: 12003990
Thanks for your help!

This is not my code. I've been assigned the job of fixing code from someone else. I don't know yet why they would want to change the value property.

0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now