Buho1
Member
Hey all. I've made a nice set of functions for my web applications. I've decided to make a class library out of it instead of copying the code to each project. What I found, however, is that the class library doesn't know what CustomValidator is. My first instinct was to write Imports System.Web.UI.WebControls at the top of the class, but I was shocked to find UI was missing from Web.
Google is not yielding any answers. Somebody had a similar situation to me, they couldn't find ListView, the solution was to Add Reference -> .NET -> System.Web.Extensions. I tried that and indeed I got much more under System.Web, including UI.WebControls. However, all of the classic webcontrols are still missing (CustomValidator, Textbox, Label, GridView).
Here is the type of code I'm trying to get to work:
Public Shared Function ScrubInput(ByVal Text As String, ByRef Validator As CustomValidator) As String. . .
I'm using .NET 3.5, but the same issue exists in .NET 4.0. Help appreciated!
Google is not yielding any answers. Somebody had a similar situation to me, they couldn't find ListView, the solution was to Add Reference -> .NET -> System.Web.Extensions. I tried that and indeed I got much more under System.Web, including UI.WebControls. However, all of the classic webcontrols are still missing (CustomValidator, Textbox, Label, GridView).
Here is the type of code I'm trying to get to work:
Public Shared Function ScrubInput(ByVal Text As String, ByRef Validator As CustomValidator) As String. . .
I'm using .NET 3.5, but the same issue exists in .NET 4.0. Help appreciated!