Click here to Skip to main content
15,891,828 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
i have model which contains

1 textbox,1 dropdownlist,1 checkbox,and again 1 textbox.
my flow is i firt insert data into textbox by checking checkbox.
and that textbox value should populate in dropdownlist and that time checkbox is unchecked. how to do that in same model using one key? or what is the another way?

What I have tried:

my model is like this:
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace AccountModule.Models
{
public class AccountGroup

{
[Key]
public int Group_Id { get; set; }
public String Group_Name { get; set; }

public int New_Id { get; set; }
public IEnumerable<SelectListItem> UnderGroup { get; set; }
public virtual AccountGroup Acc { get; set; }

public bool Nature { get; set; }
public String Comment { get; set; }

}
}
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900