asp.net mvc 3 - MVC3 Razor view not rendering dynamically added controls on postback -


i have upload selected files , display these files links on post back. in view adding each of uploaded files links using

  @if (model.incidentloginfodetails.attachmentcollection.attachmentitemcollection.any())   {       foreach (eml.container.attachment attachmentitem in model.incidentloginfodetails.attachmentcollection.attachmentitemcollection)       {            @html.actionlink(attachmentitem.filename, "testing")       }   } 

this controller action:

 public actionresult uploadingfiles(httppostedfilebase imagefile)     {         // converting attachment object         attachment fileattachment = new attachment();         fileattachment.filename = "imagefile.filename";         fileattachment.contenttype = imagefile.contenttype;         fileattachment.sizeinbytes = imagefile.contentlength;          using (memorystream ms = new memorystream())         {             imagefile.inputstream.copyto(ms);             fileattachment.binarydata = ms.getbuffer();         }          incidentdetails incidentdetails = new incidentdetails();         incidentdetails.incidentloginfodetails = new incidentloginfo();         incidentdetails.incidentloginfodetails.attachmentcollection.attachmentitemcollection = new list<attachment>();          incidentdetails.incidentloginfodetails.attachmentcollection.attachmentitemcollection.add(fileattachment);         return view("fileuploadingtest", incidentdetails);     } 

my problem though loop getting executed , action links created ( on debugging), not displayed after post back.
what missing ?


Comments

Popular posts from this blog

android - getbluetoothservice() called with no bluetoothmanagercallback -

sql - ASP.NET SqlDataSource, like on SelectCommand -

ios - Undefined symbols for architecture armv7: "_OBJC_CLASS_$_SSZipArchive" -