Telerik.Web.UI, Version=2012.2.607.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4
3.) Replace "Assembly" on UserControl with strong name:
<%@ Register Assembly="Telerik.Web.UI, Version=2012.2.607.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" ...
4.) Open Package.package -> Advanced -> Add -> Add existing assembly...
4.a) Source Path, e.g: C:\Program Files (x86)\Telerik\RadControls for ASP.NET AJAX Q2 2012\Bin35\Telerik.Web.UI.dll
4.b) Deployment Target: GlobalAssemblyCache
4.c) Location: Telerik.Web.UI.dll
4.d) Safe Controls: -> Click here to add new item...
4.e) Namespace: Telerik.Web.UI
4.f) TypeName: *
4.g) Assembly Name (e.g.): Telerik.Web.UI, Version=2012.2.607.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4
4.f) Safe: =Checked
<
telerik:RadGrid
ID
=
"ProfileGrid"
Width
=
"100%"
AllowFilteringByColumn
=
"True"
AllowSorting
=
"True"
PageSize
=
"12"
ShowFooter
=
"True"
AllowPaging
=
"True"
ViewStateMode
=
"Enabled"
runat
=
"server"
OnNeedDataSource
=
"ProfileGrid_NeedDataSource"
AutoGenerateColumns
=
"false"
GridLines
=
"None"
ShowStatusBar
=
"true"
AllowMultiRowSelection
=
"True"
DataKeyNames
=
"ProfileID"
>
<
GroupingSettings
CaseSensitive
=
"false"
/>
<
MasterTableView
>
<
Columns
>
<
telerik:GridBoundColumn
HeaderText
=
"ProfileID"
DataField
=
"ProfileID"
ReadOnly
=
"True"
UniqueName
=
"ProfileID"
Display
=
"False"
/>
<
telerik:GridClientSelectColumn
UniqueName
=
"CheckboxSelectColumn"
/>
<
telerik:GridBoundColumn
DataField
=
"Email"
HeaderText
=
"Email"
/>
<
telerik:GridBoundColumn
DataField
=
"FirstName"
HeaderText
=
"First Name"
/>
<
telerik:GridBoundColumn
DataField
=
"LastName"
HeaderText
=
"Last Name"
/>
<
telerik:GridBoundColumn
DataField
=
"Occupation"
HeaderText
=
"Occupation"
/>
<
telerik:GridBoundColumn
DataField
=
"CompanyName"
HeaderText
=
"Company"
/>
<
telerik:GridBoundColumn
DataField
=
"Source"
HeaderText
=
"Source"
/>
<
telerik:GridBoundColumn
DataField
=
"ProfileLastModifiedDate"
HeaderText
=
"Modified"
/>
<
telerik:GridButtonColumn
Text
=
"Delete"
CommandName
=
"Delete"
/>
<
telerik:GridButtonColumn
Text
=
"View Full Profile"
CommandName
=
"View Full Profile"
/>
</
Columns
>
</
MasterTableView
>
<
ClientSettings
EnableRowHoverStyle
=
"true"
>
<
Selecting
AllowRowSelect
=
"True"
/>
</
ClientSettings
>
</
telerik:RadGrid
>
public
partial
class
ProfilesGridControl : ProfileControlBase
{
protected
override
void
FillProfiles()
{
List<IProfile> profilesList =
new
List<IProfile>();
ProfileDal profileDal =
new
ProfileDal();
profilesList = profileDal.SelectAll();
ViewState[
"Profiles"
] = profilesList;
ProfileGrid.DataSource = ViewState[
"Profiles"
];
}
protected
void
ProfileGrid_NeedDataSource(
object
source, GridNeedDataSourceEventArgs e)
{
if
(ViewState[
"Profiles"
] !=
null
)
{
ProfileGrid.DataSource = ViewState[
"Profiles"
];
}
{
FillProfiles();
}
}
}