Uploading a file
-
I want to programatically upload a file from the local computer to the server without any intervention from the user. I tried using the FileUpload control but it requires the user to click the browse button to select a file. Can't I programatically set the file to be uploaded? Or is there another way to do this?
-
I want to programatically upload a file from the local computer to the server without any intervention from the user. I tried using the FileUpload control but it requires the user to click the browse button to select a file. Can't I programatically set the file to be uploaded? Or is there another way to do this?
dptalt wrote:
without any intervention from the user
Leave alone the implementation, tell me how you plan to decide which file needs to uploaded.
Manas Bhardwaj Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
-
dptalt wrote:
without any intervention from the user
Leave alone the implementation, tell me how you plan to decide which file needs to uploaded.
Manas Bhardwaj Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
Manas Bhardwaj wrote:
tell me how you plan to decide which file needs to uploaded.
Using
Artificial Intelligence
;PAbhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
I want to programatically upload a file from the local computer to the server without any intervention from the user. I tried using the FileUpload control but it requires the user to click the browse button to select a file. Can't I programatically set the file to be uploaded? Or is there another way to do this?
dptalt wrote:
it requires the user to click the browse button to select a file.
Yes It should be !
dptalt wrote:
Can't I programatically set the file to be uploaded? Or is there another way to do this?
Is it a fix file ? If yes, you can try it using ActiveX Components. But it will work only on IE.
Abhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
Manas Bhardwaj wrote:
tell me how you plan to decide which file needs to uploaded.
Using
Artificial Intelligence
;PAbhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
Abhijit Jana wrote:
Artificial Intelligence
Or Born negligence :) (I did not want to use exact word here ;P )
Manas Bhardwaj Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
-
dptalt wrote:
without any intervention from the user
Leave alone the implementation, tell me how you plan to decide which file needs to uploaded.
Manas Bhardwaj Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
-
The file name and path to be uploaded is stored in a session variable. In the code behind I would like to have a method that uploads this file.
dptalt wrote:
The file name and path to be uploaded is stored in a session variable.
From where these file name will come to session variable ?
Abhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
Abhijit Jana wrote:
Artificial Intelligence
Or Born negligence :) (I did not want to use exact word here ;P )
Manas Bhardwaj Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
Manas Bhardwaj wrote:
I did not want to use exact word here
:rolleyes:
Abhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
Manas Bhardwaj wrote:
tell me how you plan to decide which file needs to uploaded.
Using
Artificial Intelligence
;PAbhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
Abhijit Jana wrote:
Using Artificial Intelligence
:omg: :cool::confused::rose::cool:
If It Helps Click It as Answer
:jig: :badger: :jig:
Abhijit Jana | Codeproject MVP Web Site : abhijitjana.net Don't forget to click "Good Answer" on the post(s) that helped you.
-
I want to programatically upload a file from the local computer to the server without any intervention from the user. I tried using the FileUpload control but it requires the user to click the browse button to select a file. Can't I programatically set the file to be uploaded? Or is there another way to do this?
-
I want to programatically upload a file from the local computer to the server without any intervention from the user. I tried using the FileUpload control but it requires the user to click the browse button to select a file. Can't I programatically set the file to be uploaded? Or is there another way to do this?
Jokes apart. Its not possible. There is no possibility to have input type="file" control to set the value without human intervention. Even you cannot copy the input type="file" control. Thus if you create a dynamic form and copy the control to that form and send.. it wont be possible. So forget about this.. Moreover you can do one thing, is to programmatically open the File browser dialog... :-D :-D
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.