Click here to Skip to main content
15,896,111 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: need example navigations pls Pin
Mike Ellison15-Oct-06 16:20
Mike Ellison15-Oct-06 16:20 
AnswerRe: need example navigations pls Pin
Faisal Khatri15-Oct-06 18:39
Faisal Khatri15-Oct-06 18:39 
GeneralRe: need example navigations pls Pin
neodeaths16-Oct-06 5:38
neodeaths16-Oct-06 5:38 
QuestionDATA LIST PROBLEM IN ASP.NET ver 1.1 Pin
Faisal Khatri15-Oct-06 10:20
Faisal Khatri15-Oct-06 10:20 
AnswerRe: DATA LIST PROBLEM IN ASP.NET ver 1.1 Pin
Mike Ellison15-Oct-06 16:04
Mike Ellison15-Oct-06 16:04 
GeneralRe: DATA LIST PROBLEM IN ASP.NET ver 1.1 Pin
Faisal Khatri15-Oct-06 18:37
Faisal Khatri15-Oct-06 18:37 
QuestionAccess Function in Page from App_Code??? Pin
code-frog15-Oct-06 8:00
professionalcode-frog15-Oct-06 8:00 
AnswerRe: Access Function in Page from App_Code??? Pin
Mike Ellison15-Oct-06 9:12
Mike Ellison15-Oct-06 9:12 
It looks like you're accessing your DropDownList within your GetVenderSelection() function, yes?

If that's the case, you probably wouldn't want to define the function in your App_Code folder. You'd probably just want to include it in the code-behind for your .aspx page.

I think of App_Code as a place to hold custom class definitions, like a simple Data tier class. I might for example define something like this in a .cs file that is stored in App_Code:
public Class DataProvider
{
  public static DataSet GetVendors()
  {
    ... code that returns a dataset of vendors from the database ...
  }
 
}
then call it from an .aspx page like this:
private void Page_Load()
{
  if (!IsPostBack)
  {
    myDropDownList.DataSource = DataProvider.GetVendors();
    myDropDownList.DataBind();
  }
}
In your case, if your function is directly referencing the dropdownlist, it might make more sense to leave it in the .aspx page with the dropdownlist.
GeneralRe: Access Function in Page from App_Code??? Pin
code-frog15-Oct-06 9:21
professionalcode-frog15-Oct-06 9:21 
GeneralRe: Access Function in Page from App_Code??? Pin
Mike Ellison15-Oct-06 9:33
Mike Ellison15-Oct-06 9:33 
QuestionRefresh? Pin
drc_no115-Oct-06 7:43
drc_no115-Oct-06 7:43 
AnswerRe: Refresh? Pin
Guffa15-Oct-06 16:52
Guffa15-Oct-06 16:52 
GeneralRe: Refresh? Pin
miniThomas15-Oct-06 21:06
miniThomas15-Oct-06 21:06 
GeneralRe: Refresh? Pin
miniThomas15-Oct-06 21:07
miniThomas15-Oct-06 21:07 
QuestionPop Up Problem ... Pin
just3ala215-Oct-06 2:49
just3ala215-Oct-06 2:49 
AnswerRe: Pop Up Problem ... Pin
Guffa15-Oct-06 3:54
Guffa15-Oct-06 3:54 
GeneralRe: Pop Up Problem ... Pin
just3ala215-Oct-06 20:22
just3ala215-Oct-06 20:22 
QuestionASP Menu Pin
Ahmed_soft14-Oct-06 23:19
Ahmed_soft14-Oct-06 23:19 
Questionsite map path [modified] Pin
kitokatakito14-Oct-06 22:59
kitokatakito14-Oct-06 22:59 
Questionasp Pin
athivak14-Oct-06 18:47
athivak14-Oct-06 18:47 
AnswerRe: asp Pin
Tad McClellan15-Oct-06 17:24
professionalTad McClellan15-Oct-06 17:24 
QuestionGood solution to updating site in ASP.NET 2.0 ??? Pin
devboycpp14-Oct-06 8:41
devboycpp14-Oct-06 8:41 
AnswerRe: Good solution to updating site in ASP.NET 2.0 ??? Pin
Tad McClellan15-Oct-06 17:22
professionalTad McClellan15-Oct-06 17:22 
Questionget value as a number Pin
TheEagle14-Oct-06 8:31
TheEagle14-Oct-06 8:31 
AnswerRe: get value as a number Pin
Guffa14-Oct-06 10:08
Guffa14-Oct-06 10:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.