N
netasp
hi guys,
I am having the following problem:
I am trying to access some textbox & dropdown controls from my function
located in the app_code folder but I can't see them, it complains about not
being declared! or not found.
it was working in VS 2003 before the migration; since there is no App_Code
but now since I moved it, I can't seem to figure out how to make it see the
controls sitting on the aspx form from a shared class sitting in the
app_code folder?
for example lets say the function is:
public shared MarkScheduleLength()
dim i as integer
dim s as string
i = ctype(txtLength.Text,integer) 'it complains about txtLength.Text
is not declared
s = cmbName.SelectedValue 'it complains about cmbName is not
declared
........
I don't want to create an instance of the form because I am trying to
capture the exact value of that control at that time(as it changes) and not
creating a new instance of it with a new value, I am trying to capture
cmbName_SelectedIndexChanges(....) everytime the user changes the drop down
menu selection
how can I work around this?. I have a lot of functions and methods that
access textboxes, dropdown menus, labels, ...etc as their value changes at
runtime and now I am stuck, it can not see any of them.
did Microsoft disable controls access because of this move to App_Code
folder? they didn't think of that?
Please let me know
thanks
I am having the following problem:
I am trying to access some textbox & dropdown controls from my function
located in the app_code folder but I can't see them, it complains about not
being declared! or not found.
it was working in VS 2003 before the migration; since there is no App_Code
but now since I moved it, I can't seem to figure out how to make it see the
controls sitting on the aspx form from a shared class sitting in the
app_code folder?
for example lets say the function is:
public shared MarkScheduleLength()
dim i as integer
dim s as string
i = ctype(txtLength.Text,integer) 'it complains about txtLength.Text
is not declared
s = cmbName.SelectedValue 'it complains about cmbName is not
declared
........
I don't want to create an instance of the form because I am trying to
capture the exact value of that control at that time(as it changes) and not
creating a new instance of it with a new value, I am trying to capture
cmbName_SelectedIndexChanges(....) everytime the user changes the drop down
menu selection
how can I work around this?. I have a lot of functions and methods that
access textboxes, dropdown menus, labels, ...etc as their value changes at
runtime and now I am stuck, it can not see any of them.
did Microsoft disable controls access because of this move to App_Code
folder? they didn't think of that?
Please let me know
thanks