• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 542
  • Last Modified:

Problem with HTMLInputFile

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
Hermund
Asked:
Hermund
1 Solution
 
DotNetLover_BaanCommented:
Need more details... What is "HTMLInputFile" ? How are you using that ? Need some code to...
-Baan
0
 
ThogekCommented:
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
 
ThogekCommented:
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
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

 
Timbo87Commented:
Yes, it's an HTML limitation/feature. No custom control or fancy code can circumvent that.
0
 
ThogekCommented:
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
 
HermundAuthor Commented:
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
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now