R
Randel Bjorkquist
Hi all,
I'm extremly new to building web-applications, C#, and the whole Microsoft
Visual Studio 2003 .NET IDE, so please bare with me.
What I have:
I have a web-application that communicates to an SQL Server. My aspx file
is on a Windows 2000 Server running IIS. The base of the program is working
just ducky.
My problem:
I'm trying to set the "ControlToValidate" property of a
"RequiredFieldValidator" at run time and get an exception when my code
executes. The error is "Unable to find control id
'System.Web.UI.WebControls.ListBox' referenced by the 'ControlToValidate'
property of 'rfv_Parts'."
CODE:
:
private void cmd_Submit_Click(object sender, System.EventArgs e){
rfv_Parts.ControlToValidate = lstbox_Parts.ToString();
:
}//END OF "cmd_Submit_Click" METHOD
:
Can someone tell me why this isn't working?
Thanks,
Randel Bjorkquist
I'm extremly new to building web-applications, C#, and the whole Microsoft
Visual Studio 2003 .NET IDE, so please bare with me.
What I have:
I have a web-application that communicates to an SQL Server. My aspx file
is on a Windows 2000 Server running IIS. The base of the program is working
just ducky.
My problem:
I'm trying to set the "ControlToValidate" property of a
"RequiredFieldValidator" at run time and get an exception when my code
executes. The error is "Unable to find control id
'System.Web.UI.WebControls.ListBox' referenced by the 'ControlToValidate'
property of 'rfv_Parts'."
CODE:
:
private void cmd_Submit_Click(object sender, System.EventArgs e){
rfv_Parts.ControlToValidate = lstbox_Parts.ToString();
:
}//END OF "cmd_Submit_Click" METHOD
:
Can someone tell me why this isn't working?
Thanks,
Randel Bjorkquist