Answer the question
In order to leave comments, you need to log in
How to get POST parameters and file in a form?
I submit a form with data and a file, but I can't then save the file and get the select option
value.
I do this
string newPay_Money = Request.Form["newPay_Money"];
string newPay_Paket = Request.Form["newPay_Paket"]; //here I can't get the value select>option.value
string newPay_MyPurse = Request.Form["newPay_MyPurse"];
var files = Request.Form.Files;
how can i save the file?
Answer the question
In order to leave comments, you need to log in
The form must be with enctype = "multipart/form-data"
.
Further, I would recommend using some kind of model, rather than working directly with Request.
Does Request.Form even have it? Set a breakpoint at this point, and look in Watch what's there.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question