amir mohammadi

amir mohammadi

  • 2.1k
  • 8
  • 631

Classification Html Table in ASP.net MVC

Mar 7 2018 3:24 PM
Hello
 
I have a list of Data the passed into my View
 
in View , It show Data like this Picture .  each data in 1 row :
 
I want to Divide Data result in 3 column across from other Like This Picture
 
 
 
my code is :
  1. <table>    
  2.  @{           
  3.         foreach (var item in Model)    
  4.         {     
  5.             int aa = Convert.ToInt32(item.Number);    
  6.             <tr>    
  7.                 <td class="tg-baqh"><a href="/Home/Fehrest/@item.Section_ID" >@item.Number</a></td>    
  8.                 <td class="tg-baqh">@item.Name</td>    
  9.                 <td class="tg-baqh">@Html.ActionLink("edit""EditSection"new { id = item.Section_ID })</td>    
  10.             </tr>  
  11.           }    
  12.     }    
  13. </table>    
Please Help me

Answers (2)