hi, we use FormBaseAuthentication in WSS 3.0.
I create a "new user" aspx page to let new user to create a profile. We want to use Teletik control (Panel, textbox, ...) in this page.
I follow the great article to enable Telerik and .net 3.5 on WSS. I try with the webparts example that you provide, it work good. But now I try to add some telerik control to my custom NouvUsager.aspx. If I simply drag and drop a telerik control on my aspx page, deploy it and try, I god a "could not load assemblies" error. (but the Telerik.web.ui.dll are in the GAC).
my aspx code without the reference to telerik:
My vb class linked in the Inherit section:
Like you can see at the end of the init page, I add a radTexbox (like in the webpart example) but nothing appear on the form. But with this code not error are raised.
Question:
1- It ok to replace the GetType(Webpart1) to GetType(NouvUsager) in this:
Page.ClientScript.RegisterStartupScript(GetType(NouvUsager), Me.ID, "_spOriginalFormAction = document.forms[0].action;_spSuppressFormOnSubmitWrapper=true;", True)
2- How can I add with drag and drop control to my aspx page without the could not load assemblie error?
3- Do you have a good sample for creating a complex ascx (usercontrol) with some Telerik control added into a webpart?
Thanks
I create a "new user" aspx page to let new user to create a profile. We want to use Teletik control (Panel, textbox, ...) in this page.
I follow the great article to enable Telerik and .net 3.5 on WSS. I try with the webparts example that you provide, it work good. But now I try to add some telerik control to my custom NouvUsager.aspx. If I simply drag and drop a telerik control on my aspx page, deploy it and try, I god a "could not load assemblies" error. (but the Telerik.web.ui.dll are in the GAC).
my aspx code without the reference to telerik:
<%@ Assembly Name="Microsoft.SharePoint.ApplicationPages, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%> |
<%@ Page Language="vb" |
Inherits="ExtranetArbaultWssAddon.NouvUsager, ExtranetArbaultWssAddon, Version=1.0.0.0, Culture=neutral, PublicKeyToken=d71c63e255e32165" |
MasterPageFile="simple.master" %> |
<%@ Import Namespace="Microsoft.SharePoint.ApplicationPages" %> |
<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> |
<%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> |
<%@ Import Namespace="Microsoft.SharePoint" %> |
<asp:Content ID="Content5" ContentPlaceHolderId="PlaceHolderMain" runat="server"> |
<telerik:RadTextBox ID="RadTextBox1" runat="server"> |
</telerik:RadTextBox> |
</asp:Content> |
My vb class linked in the Inherit section:
Imports System |
Imports System.Runtime.InteropServices |
Imports System.Web.UI |
Imports System.Web.UI.WebControls |
Imports System.Web.UI.WebControls.WebParts |
Imports System.Xml.Serialization |
Imports Microsoft.SharePoint |
Imports Microsoft.SharePoint.WebControls |
Imports Microsoft.SharePoint.WebPartPages |
Imports Telerik.Web.UI |
Partial Public Class NouvUsager |
Inherits Microsoft.SharePoint.WebControls.UnsecuredLayoutsPageBase |
Protected Overloads Overrides ReadOnly Property AllowAnonymousAccess() As Boolean |
Get |
Return True |
End Get |
End Property |
Protected Overloads Overrides ReadOnly Property AllowNullWeb() As Boolean |
Get |
Return True |
End Get |
End Property |
Private Sub Page_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init |
'Ajout du scrip manager au besoin |
Dim scriptManager As RadScriptManager = RadScriptManager.GetCurrent(Me.Page) |
If scriptManager Is Nothing Then |
scriptManager = New RadScriptManager |
Me.Page.Form.Controls.AddAt(0, scriptManager) |
End If |
Page.ClientScript.RegisterStartupScript(GetType(NouvUsager), Me.ID, "_spOriginalFormAction = document.forms[0].action;_spSuppressFormOnSubmitWrapper=true;", True) |
If Me.Page.Form Is Nothing Then |
Dim formOnSubmitAtt As String = Me.Page.Form.Attributes("onsubmit") |
If Not String.IsNullOrEmpty(formOnSubmitAtt) AndAlso formOnSubmitAtt = "return _spFormOnSubmitWrapper();" Then |
Me.Page.Form.Attributes("onsubmit") = "_spFormOnSubmitWrapper();" |
End If |
End If |
Dim test As New RadTextBox |
Me.Controls.Add(test) |
End Sub |
Question:
1- It ok to replace the GetType(Webpart1) to GetType(NouvUsager) in this:
Page.ClientScript.RegisterStartupScript(GetType(NouvUsager), Me.ID, "_spOriginalFormAction = document.forms[0].action;_spSuppressFormOnSubmitWrapper=true;", True)
2- How can I add with drag and drop control to my aspx page without the could not load assemblie error?
3- Do you have a good sample for creating a complex ascx (usercontrol) with some Telerik control added into a webpart?
Thanks