title: if value null in radio button list does not show radio button mvc4
body: <p>I have in model having the questions and answer list. In some of the questions having 4 options and some of the questions having the 2 options.
  I am getting the options from the back end and i'm binding from model class into the razor view.
  Now if the answer value null means radio button is showing but i don't want to radio button if the radio button option value nulls.</p>
  
  <pre><code>   @for (int j = 0; j &lt; Model.Count; j++)
                              {
                                  i++;
                                  &lt;div class="panel-heading online-test" role="tab" id=""&gt;
                                      &lt;h5 class="panel-title"&gt;
                                          @Html.HiddenFor(m =&gt; m[j].ID)
                                          @Html.HiddenFor(m =&gt; m[j].SkillId)
                                          @i) @Html.DisplayFor(m =&gt; m[j].QuestionText)
                                      &lt;/h5&gt;
                                  &lt;/div&gt;
       foreach (var k in Model[j].Options)
                                  {
                                      &lt;div class="panel-collapse"&gt;
                                          &lt;div class="panel-body online-test-options"&gt;
                                              &lt;div class="input-group"&gt;
                                                  &lt;div class="col-lg-12" id="radiolist"&gt;
                                                      @Html.RadioButtonFor(m =&gt; m[j].SelectedAnswer, "A")
                                                      &lt;label for="@k.AnswerId"&gt;@k.Option1&lt;/label&gt;
                                                  &lt;/div&gt;
                                                  &lt;div class="col-lg-12"&gt;
                                                      @Html.RadioButtonFor(m =&gt; m[j].SelectedAnswer, "B")
                                                      &lt;label for="@k.AnswerId"&gt;@k.Option2&lt;/label&gt;
                                                  &lt;/div&gt;
                                                  &lt;div class="col-lg-12"&gt;
                                                      @Html.RadioButtonFor(m =&gt; m[j].SelectedAnswer, "C")
                                                      &lt;label for="@k.AnswerId"&gt;@k.Option3&lt;/label&gt;
                                                  &lt;/div&gt;
                                                  &lt;div class="col-lg-12"&gt;
                                                      @Html.RadioButtonFor(m =&gt; m[j].SelectedAnswer, "D")
                                                      &lt;label for="@k.AnswerId"&gt;@k.Option4&lt;/label&gt;
                                                  &lt;/div&gt;
                                              &lt;/div&gt;
                                          &lt;/div&gt;
                                      &lt;/div&gt;
                                  }
                           }
  
  
  
  public class QuestionsModel
      {
          public decimal ID { set; get; }
          public decimal SkillId { get; set; }
          public string QuestionText { set; get; }
          public List&lt;Answer&gt; Options { set; get; }
          public string SelectedAnswer { set; get; }
          public QuestionsModel()
          {
              Options = new List&lt;Answer&gt;();
          }
      }
      public class Answer
      {
          public int AnswerId { get; set; }
          public string Option1 { set; get; }
          public string Option2 { set; get; }
          public string Option3 { set; get; }
          public string Option4 { set; get; }
      }
      public class Evaluation
      {
          public List&lt;QuestionsModel&gt; Questions { set; get; }
          public Evaluation()
          {
              Questions = new List&lt;QuestionsModel&gt;();
          }
      }
  </code></pre>
  
  <p>Please help to solve..
  Thanks in Advance.</p>