c# - How to return a list of value from DataLayer -
c# - How to return a list of value from DataLayer -
this business layer ,this code returns single value, how homecoming list of value datalayer.
public class getlocal { public businessobj.tables.getlocal getitem(int transid) { datalayer.pl.getlocal objgetlocaldl = new datalayer.pl.getlocal(); seek { homecoming objgetlocaldl.getitem(transid); } grab (exception ex) { throw new exception(ex.message, ex.innerexception); } } }
modify info access layer create additional method e.g. getitems homecoming multiple items
you can utilize type of collection list of items dal layer.
example using list collection:
public list<businessobj.tables.getlocal> getitems(int transid) { //your code fill list collection }
call above method business layer multiple items
c# asp.net
Comments
Post a Comment