Problem in Three Tier

Posted by Nuwan under C# on 6/27/2012 | Points: 10 | Views : 935 | Status : [Member] | Replies : 2
Dear All,

I want to how to bind ComboBox Without SqlData Source (using coding) In Three Tier Architecture.
How I do that.Please help me.

Rathnayake


Responses

Posted by: Jawed_Akhtar786 on: 6/27/2012 [Member] Starter | Points: 25

Up
0
Down
You can return Dataset from 3-Their architecture using ExecuteDataset with store procedure. And fill your dropdown as like
Business bs=new Business(); //Your business layer method
DataSet ds=bs.getuser();
ddl.DataSource = ds
ddl.DataTextField = "username"
ddl.DataValueField = "id"
ddl.DataBind()

Nuwan, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Ajay.Kalol on: 6/27/2012 [Member] Starter | Points: 25

Up
0
Down

in DLL
public Dataset Dataset ()
{
//write your Code for getting Data from DB
}

in BLL:
public Dataset getuser()
{
DLL dl = new dl();
return dl.Dataset ();
}

in UI:
BL bl=new BL(); //Your BLL obj.
DataSet ds=bl.getuser(); / BLL method
ddl.DataSource = ds
ddl.DataTextField = "username"
ddl.DataValueField = "id"
ddl.DataBind()


Ajay
ajaypatelfromsanthal.blogspot.in

Nuwan, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response