upload 2 different files to 2 different destinations in table and folders
问题 I have a form that I'm posting 2 different files that belongs to 2 different values in my Db table. Eg. file1=user image , file2=user company logo . So I need to attach the files url to it's db value with my viewModel , something like this:(Will never work) public ActionResult Create(LectureFormViewModel viewModel) { foreach ((string item in Request.Files).viewModel.Image1) { //Do } foreach ((string item in Request.Files).viewModel.Image2) { //Do } var lecture = new Lecture { Image1 = xxx,