Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
213 views

Hi, is there a way to override the radwindow default styles in the code behind? For example for something like this:

 

    .RadWindow .rwStatusbar,
    .RadWindow_Default table .rwTopLeft,
    .RadWindow_Default table .rwTopRight,
    .RadWindow_Default table .rwFooterCenter,
    .RadWindow_Default table .rwFooterLeft,
    .RadWindow_Default table .rwFooterRight,
    .RadWindow_Default .rwCorner,
    .RadWindow_Default .rwBodyLeft,
    .RadWindow_Default .rwBodyRight {
        display: none !important;
    }

 

using something like this in the code behind instead

 

 

window.class.Add.Style(RadWindow .rwStatusbar, display:none)

 

...

Jesse

 

Vessy
Telerik team
 answered on 02 Apr 2020
1 answer
293 views

Hi is there  away to override radwindow default styles in the code behind for example

 

 

    .RadWindow .rwStatusbar,
    .RadWindow_Default table .rwTopLeft,
    .RadWindow_Default table .rwTopRight,
    .RadWindow_Default table .rwFooterCenter,
    .RadWindow_Default table .rwFooterLeft,
    .RadWindow_Default table .rwFooterRight,
    .RadWindow_Default .rwCorner,
    .RadWindow_Default .rwBodyLeft,
    .RadWindow_Default .rwBodyRight {
        display: none !important;
    }

 

using something like this

window.class[.RadWindow .rwStatusbar]. add.style( "display", "none")

window.class[. .RadWindow_Default table .rwTopLeft,]. add.style( "display", "none")

 

...

 

 

Thanks in advance.

 

Attila Antal
Telerik team
 answered on 02 Apr 2020
17 answers
652 views
hi,
I am using 2009.3.1103.20 version of Telerik Controls.
Now I simply added filtering to columns in my grid and that worked fine on my machine.
But when I deployed it to Test Server, the problem is that the filter icon is displayed on next line, underneath filter textbox, for my first column.
For rest of the columns, its looking good and this is happening only on my Test Server.
I tried giving FiltercontrolWidth, HeaderStyle-Width but didnt work.

Any idea why the filter icon is displayed underneath filter textbox?
Here is my grid. I have about 15 fields so I kept only few fields here.
The first column 

<

 

telerik:GridNumericColumn DataField="RequestInfoID"

 

is displaying Filter Icon underneath filter textbox, any idea how do I make it display next to textbox?


<div class="Scrollgrid" style="width: 1100px; height: 600px;">
                                                <telerik:RadGrid ID="RadGridAllRequests" runat="server" AllowPaging="true" AllowSorting="true"
                                                    AllowFilteringByColumn="true" AutoGenerateColumns="False" BorderStyle="None"
                                                    GridLines="Both" OnNeedDataSource="RadGridAllRequests_needdatasource" OnItemDataBound="RadGridAllRequests_ItemDataBound"
                                                    OnItemCreated="RadGridAllRequests_ItemCreated" OnItemCommand="RadGridAllRequests_ItemCommand"
                                                       
                                                       
                                                    AllowMultiRowSelection="true" SelectedItemStyle-CssClass="SelectedItem" Width="100%"
                                                    Skin="WebBlue">
                                                    <PagerStyle Mode="NextPrevNumericAndAdvanced" Position="TopAndBottom" AlwaysVisible="true" />
                                                    <ClientSettings EnableRowHoverStyle="true" EnablePostBackOnRowClick="true">
                                                        <Selecting AllowRowSelect="true" />
                                                    </ClientSettings>
                                                      
                                                      
                                                      
                                                    <MasterTableView 
                                                         
                                                    ShowHeadersWhenNoRecords="true" 
                                                    AllowFilteringByColumn="true" DataKeyNames="RequestInfoID">
                                                        <Columns>
                                                              
                                                            <telerik:GridNumericColumn DataField="RequestInfoID" HeaderText="Request No." SortExpression="RequestInfoID"
                                                                DataType="System.Int64" FilterControlWidth="40px" HeaderStyle-Width="100px"
                                                                    
                                                                >
                                                                     
                                                            </telerik:GridNumericColumn>
                                                            <telerik:GridDateTimeColumn HeaderStyle-Width="130px" DataField="CreationDate" HeaderText="Created On"
                                                                FilterControlWidth="100px" CurrentFilterFunction="Contains" PickerType="DatePicker"
                                                                DataFormatString="{0:MM/dd/yyyy}" SortExpression="CreationDate">
                                                            </telerik:GridDateTimeColumn>
                                                            <telerik:GridNumericColumn DataField="TotalAmount" HeaderText="Total Amount" SortExpression="TotalAmount"
                                                                HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right" DataType="System.Decimal"
                                                                FilterControlWidth="70px" DataFormatString="{0:#,##0.00}">
                                                                <FooterStyle Font-Bold="true" />
                                                            </telerik:GridNumericColumn>
                                                            <telerik:GridBoundColumn DataField="RequestedFrom_Email" HeaderText="Requested From"
                                                                SortExpression="RequestedFrom_Email">
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn DataField="SuggestedVendor" HeaderText="Suggested Vendor"
                                                                SortExpression="SuggestedVendor" UniqueName="SuggestedVendor">
                                                            </telerik:GridBoundColumn>
<telerik:GridTemplateColumn HeaderText="Describe Reason and Reject" UniqueName="rejectrequest"
                                                                AllowFiltering="false">
                                                                <ItemTemplate>
                                                                    <table width="240px" cellpadding="0" cellspacing="0">
                                                                        <tr valign="top">
                                                                            <td>
                                                                                <asp:Label ID="lblNextApprovalRequiredFor" runat="server" Visible="false" Text='<%#Eval ( "NextApprovalRequiredFor").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblUnder5000ApprovedORRejected" runat="server" Visible="false" Text='<%#Eval ( "Under5000ApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblOver5000ApprovedORRejected" runat="server" Visible="false" Text='<%#Eval ( "Over5000ApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblFinanceApprovedORRejected" runat="server" Visible="false" Text='<%#Eval ( "FinanceApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblOver25000CFOApprovedORRejected" runat="server" Visible="false"
                                                                                    Text='<%#Eval ( "Over25000CFOApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblOver25000COOApprovedORRejected" runat="server" Visible="false"
                                                                                    Text='<%#Eval ( "Over25000COOApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblOver25000CEOApprovedORRejected" runat="server" Visible="false"
                                                                                    Text='<%#Eval ( "Over25000CEOApprovedORRejected").ToString()%>'></asp:Label>
                                                                                <asp:Label ID="lblRejectedMessage" runat="server" Text="Rejected"></asp:Label>
                                                                                <asp:TextBox Width="150px" runat="server" MaxLength="150" ValidationGroup="vgRejection"
                                                                                    ID="txtRejectionReason" ToolTip="Enter Rejection Reason"></asp:TextBox>
                                                                                <%--                                                            <asp:RequiredFieldValidator 
                                                                ID="rvRejectionReason" 
                                                                Display="Dynamic"
                                                                ValidationGroup="vgRejection"
                                                                runat="server" 
                                                                SetFocusOnError="true"
                                                                ControlToValidate="txtRejectionReason" 
                                                                ErrorMessage="Enter Rejection Reason" 
                                                                ToolTip="Enter Rejection Reason">
                                                            </asp:RequiredFieldValidator>                        
--%>
                                                                                <asp:Button CssClass="ButtonCSS" runat="server" ID="btnRejectRequest" Text="Reject"
                                                                                    ToolTip="Click Here to Reject Request" CausesValidation="true" ValidationGroup="vgRejection"
                                                                                    OnClick="btnRejectRequest_Click" OnClientClick="javascript:var agree= confirm('Are you sure you want to reject this Request? '); if(agree){ Page_BlockSubmit = false;buttonClicked_WithObj(this); return true; };else {return false;};"
                                                                                    CommandArgument='<%# 
                                                                Eval ( "RequestInfoID").ToString() 
                                                                + ";" +
                                                                Eval ( "NextApprovalRequiredFor").ToString() 
                                                                + ";" +
                                                                Eval ( "TotalAmount").ToString() 
                                                                  
                                                                %>' />
                                                                            </td>
                                                                        </tr>
                                                                    </table>
                                                                </ItemTemplate>
                                                            </telerik:GridTemplateColumn>
                                                            <telerik:GridBoundColumn DataField="Request_Current_Status_DisplayText" HeaderText="Current Status"
                                                                SortExpression="Request_Current_Status_DisplayText" UniqueName="Request_Current_Status_DisplayText">
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridTemplateColumn HeaderText="Cancel Request" UniqueName="cancelrequest">
                                                                <ItemTemplate>
                                                                    <asp:Label ID="lblCancelled" runat="server" Visible="false" Text='<%#Eval ( "Cancelled").ToString()%>'></asp:Label>
                                                                    <asp:Label runat="server" ID="lblCompleted" Text='<%# Eval("Completed").ToString()%>'
                                                                        Visible="false"></asp:Label>
                                                                    <asp:Label runat="server" ID="lblCompletedMessage" Text='<%# Eval("CompletedStatus").ToString()%>'></asp:Label>
                                                                    <asp:Label runat="server" ID="lblCancellationStatus" Text='<%# Eval("CancellationStatus").ToString()%>'></asp:Label>
                                                                    <asp:Button CssClass="ButtonCSS" runat="server" ID="btnCancelRequest" Text="Cancel Request"
                                                                        ToolTip="Click Here to cancel Request" CausesValidation="False" OnClick="btnCancelRequest_Click"
                                                                        OnClientClick="javascript:var agree= confirm('Are you sure you want to cancel/delete this Request? '); if(agree){ Page_BlockSubmit = false;buttonClicked_WithObj(this); return true; };else {return false;};"
                                                                        CommandArgument='<%# Eval ( "RequestInfoID").ToString() %>' />
                                                                </ItemTemplate>
                                                            </telerik:GridTemplateColumn>
                                                            <telerik:GridTemplateColumn HeaderText="Request No." SortExpression="RequestInfoID"
                                                                AllowFiltering="false" Visible="false" UniqueName="requestinfoid">
                                                                <ItemTemplate>
                                                                    <asp:Label ID="lblRequestInfoID" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "RequestInfoID")%>'></asp:Label></ItemTemplate>
                                                            </telerik:GridTemplateColumn>
                                                        </Columns>
                                                        <EditFormSettings>
                                                            <PopUpSettings ScrollBars="None" />
                                                        </EditFormSettings>
                                                        <ExpandCollapseColumn Resizable="False" Visible="False">
                                                            <HeaderStyle />
                                                        </ExpandCollapseColumn>
                                                        <RowIndicatorColumn Visible="False">
                                                            <HeaderStyle />
                                                        </RowIndicatorColumn>
                                                    </MasterTableView>
                                                </telerik:RadGrid>
                                            </div>






Ajay
Top achievements
Rank 1
 answered on 02 Apr 2020
1 answer
473 views

I'm trying to get the RadDatePicker to work with the CompareValidator with the DataTypeCheck operator. Initially, I wanted to use this as a dynamically created control in the code-behind. (It works great with a normal validator, but it also validates blank textboxes when I don't want it to). I noticed this seemed to be an issue 10 years ago from what I've searched, but is this still the case?

I did a little testing here -

    <form id="form1" runat="server">
    <div>
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        </telerik:RadScriptManager>
 
        <asp:Label ID="lblDate" Text="Date:" AssociatedControlID="txtDate" runat="server" />
 
        <asp:TextBox ID="txtDate" runat="server" />
 
         <asp:CompareValidator
            ID="txtDatecompare"
            Text="(Invalid Date)"
            ControlToValidate="txtDate"
            Type="Date"
            Operator="DataTypeCheck"
            runat="server" />
 
        <hr />
 
         <asp:Label ID="lblTelerikDate" Text="Date:" AssociatedControlID="rdDate" runat="server" />
 
        <telerik:RadDatePicker ID="rdDate" runat="server">
        </telerik:RadDatePicker>
 
        <asp:CompareValidator
            ID="txtRadDateCompare"
            Text="(Invalid Date)"
            ControlToValidate="rdDate"
            Type="Date"
            Operator="DataTypeCheck"
            runat="server" />
 
        <br />
 
        <asp:Button ID="btnSubmit" Text="Submit" runat="server" />
 
    </div>
</form>

 

The submit button simply returns the time of day. What I expected to happen is -

Textbox is left blank - Do nothing. I would expect this, and handle required field validators late in the code.
Textbox has a valid date - Do nothing.
Textbox has an invalid date - Display a message and cancel the postback. However, the above code still causes a postback. If I put an invalid date into the normal textbox, it works fine. If I put an invalid date into the raddatepicker, the submit button still fires. My goal is to do this dynamically, so if it's not possible, I could always create a server-side validation to loop through the added controls.

 

Eyup
Telerik team
 answered on 01 Apr 2020
11 answers
433 views

I have HtmlChart control which works from Visual Studio 2015, but not when deployed on a Web Server. When View Source, the Web Server page source does not have the svg tag. The source is below. The Telerik dll version is 2016.2.504.45, size 26,416 KB, dated 5/23/2016 11:25 AM. How can I correct the behavior on the web server please?

<svg xmlns="http://www.w3.org/2000/svg" style="left: 0px; top: -0.36px; width: 100%; height: 100%; overflow: hidden;" version="1.1">

<telerik:RadHtmlChart ID="rhcSummary" runat="server"
    Height="200"
    Width="700">
    <PlotArea>
        <Series>
            <telerik:ColumnSeries Name="OpenClaims" DataFieldY="Value">
                <Appearance FillStyle-BackgroundColor="Green" />
                <TooltipsAppearance BackgroundColor="LightGray">
                    <ClientTemplate>
                        #= dataItem.Tooltip #
                    </ClientTemplate>
                </TooltipsAppearance>
            </telerik:ColumnSeries>
        </Series>
        <XAxis Name="Statuses"
            DataLabelsField="Meaning"
            MajorTickSize="1"
            MinorTickSize="1"
            Step="1" />
        <YAxis Name="Counts"
            MajorTickSize="5"
            MinorTickSize="5"
            Step="10" />
    </PlotArea>
    <Legend>
        <Appearance Visible="false" />
    </Legend>
</telerik:RadHtmlChart>
Alfredo Rohweder
Top achievements
Rank 1
 answered on 31 Mar 2020
9 answers
366 views
Hello,

Is it possible to attach a eventhandler to a double click event on a task and get the taskId?

Thanks,
Martin
bassam
Top achievements
Rank 1
Veteran
 answered on 31 Mar 2020
2 answers
356 views

Hi,

I am trying to adjust the width of the input box but it's not working. Weirdly other properties work but I am not getting to reflect the changes in width.

My CSS code:

html .RadAutoCompleteBox .racInput {
 font-family: sans-serif;
 font-size: 1.2em;
 height: 30px;
 width: 1000px !important;
}

 

 

My aspx code:

<telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
<telerik:RadAutoCompleteBox RenderMode="Lightweight" runat="server" ID="RadAutoCompleteBox1"
    autopostback="true" EmptyMessage="Type in data..."
    DataSourceID="SqlDataSource1"
    DataTextField="edesc"
    DataValueField="ecode"
    InputType="Token"
    Width="450"
    DropDownWidth="150px"
    OnEntryAdded="RadAutoCompleteBox1_EntryAdded"
    OnEntryRemoved="RadAutoCompleteBox1_EntryRemoved"
    >
</telerik:RadAutoCompleteBox>

 

Notice that I define a default value of 450 in ASPX code but as far as I know the CSS should override it, correct? Anyway, I tried to remove the initial definition but CSS still won't work.

As I mentioned all other properties work fine but the "width" one. Any idea?

 

Thanks in advance!

Yan Moura
Top achievements
Rank 1
Veteran
Iron
 answered on 31 Mar 2020
5 answers
917 views
Im attempting to build a combobox and populate it with data. everything works, but I would also like to add tooltips using data from my database. My code is as follows:
radcombo_mns_severity.DataTextField = "SEVERITY";
radcombo_mns_severity.DataValueField = "ID";
radcombo_mns_severity.ToolTip = "DESC";
radcombo_mns_severity.DataSource = from c in quarkdb.MNS_SEVERITies
                                   orderby c.SEVERITY
                                   select new
                                   {
                                       c.SEVERITY,
                                       c.ID,
                                       c.DESC
                                   };
radcombo_mns_severity.DataBind();

Is there away to do this?
Peter Milchev
Telerik team
 answered on 31 Mar 2020
1 answer
813 views

Hi All,

 

I have RadGrid inside RadWindow, i want to remove border on RadGrid. Any have solution..? 

 

This my RadWindow Code
<telerik:RadWindow ID="RwEmployeeBrowser" runat="server" Modal="true" Width="1200px" Height="550px" KeepInScreenBounds="true" Title="Select Employee">
    <ContentTemplate>
        <UC:UCEmploye ID="UCEmploye" runat="server" />
    </ContentTemplate>
</telerik:RadWindow>
 
This My RadGridCode
<telerik:RadGrid RenderMode="Lightweight" ID="RgData" PagerStyle-AlwaysVisible="true" runat="server" AllowFilteringByColumn="True" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CellSpacing="-1" GridLines="Both" OnPreRender="RgData_PreRender" OnItemCommand="RgData_ItemCommand" OnItemDataBound="RgData_ItemDataBound"  OnNeedDataSource="RgData_NeedDataSource">
                    <GroupingSettings CaseSensitive="false" />
                    <MasterTableView CommandItemDisplay="Top" Width="100%" AllowMultiColumnSorting="false">
                        <CommandItemSettings ShowAddNewRecordButton="false" ShowExportToExcelButton="false" ShowRefreshButton="false" />
                        <Columns>
                            <telerik:GridTemplateColumn UniqueName="TemplateColumn" HeaderStyle-Width="2px">
                                <FilterTemplate>
                                    <asp:ImageButton ID="btnClearFilter" CausesValidation="false" runat="server" ImageUrl="/Style Library/bower_components/Telerik/Delete.gif" AlternateText="Clear Filter"
                                        ToolTip="Clear Filter" OnClick="btnClearFilter_Click" Style="vertical-align: middle" />
                                </FilterTemplate>
                                <ItemTemplate>
                                    <asp:LinkButton runat="server" ID="ImgBtn" Text="Select" ForeColor="Blue" CausesValidation="false" CommandName="Select" />
                                    <asp:Label runat="server" ID="lblId" Text='<%# Eval( "PersonId" ) %>' Visible="false"></asp:Label>
                                    <asp:Label runat="server" ID="lblEmpLogin" Text='<%# Eval( "EmployeeLogin" ) %>' Visible="false"></asp:Label>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn UniqueName="TemplateColumn" HeaderText="No" AllowFiltering="false">
                                <ItemTemplate>
                                    <asp:Label ID="numberLabel" runat="server" />
                                </ItemTemplate>
                                <HeaderStyle Width="15px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn HeaderStyle-HorizontalAlign="Left" AutoPostBackOnFilter="true" UniqueName="Un1" FilterControlWidth="100%" DataField="EmployeeNumber" HeaderText="NIK" HeaderStyle-Width="10%" CurrentFilterFunction="Contains" ShowFilterIcon="false" HeaderButtonType="TextButton">
                                <HeaderStyle Width="10%"></HeaderStyle>
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn HeaderStyle-HorizontalAlign="Left" AutoPostBackOnFilter="true" UniqueName="Un2" FilterControlWidth="100%" DataField="EmployeeName" HeaderText="Employee Name" HeaderStyle-Width="30%" CurrentFilterFunction="Contains" ShowFilterIcon="false" HeaderButtonType="TextButton">
                                <HeaderStyle Width="15%"></HeaderStyle>
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn HeaderStyle-HorizontalAlign="Left" AutoPostBackOnFilter="true" UniqueName="Un3" FilterControlWidth="100%" DataField="Position" HeaderText="Position" HeaderStyle-Width="30%" CurrentFilterFunction="Contains" ShowFilterIcon="false" HeaderButtonType="TextButton">
                                <HeaderStyle Width="25%"></HeaderStyle>
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn HeaderStyle-HorizontalAlign="Left" AutoPostBackOnFilter="true" UniqueName="Un4" FilterControlWidth="100%" DataField="DepartmentName" HeaderText="Department" HeaderStyle-Width="30%" CurrentFilterFunction="Contains" ShowFilterIcon="false" HeaderButtonType="TextButton">
                                <HeaderStyle Width="25%"></HeaderStyle>
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn HeaderStyle-HorizontalAlign="Left" AutoPostBackOnFilter="true" UniqueName="Un5" FilterControlWidth="100%" DataField="CompanyName" HeaderText="Company" HeaderStyle-Width="30%" CurrentFilterFunction="Contains" ShowFilterIcon="false" HeaderButtonType="TextButton">
                                <HeaderStyle Width="25%"></HeaderStyle>
                            </telerik:GridBoundColumn>
                        </Columns>
                    </MasterTableView>
                    <ClientSettings Selecting-AllowRowSelect="false" EnablePostBackOnRowClick="false" EnableRowHoverStyle="false">
                        <Resizing AllowColumnResize="false" ResizeGridOnColumnResize="false" AllowResizeToFit="false" />
                    </ClientSettings>
                    <HeaderStyle HorizontalAlign="Center" />
                    <FilterMenu RenderMode="Lightweight"></FilterMenu>
                    <HeaderContextMenu RenderMode="Lightweight"></HeaderContextMenu>
                </telerik:RadGrid>
Doncho
Telerik team
 answered on 31 Mar 2020
2 answers
383 views

I have a page that loads a list of controls based on report criteria. I've been converting some of these controls to Telerik, but I also have some controls that are custom controls. I've narrowed down the issue to when an ASP.NET control (ASP from the dropdown) gets loaded after a Telerik control (Telerik from the dropdown), I get a "Failed to load viewstate" error. It also happens if both controls are Telerik controls, but does not happen if all controls are ASP.NET controls.

DynamicControls.aspx

<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="DynamicControls.aspx.vb" Inherits="TestCode.DynamicContrls" %>
 
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
 
<!DOCTYPE html>
 
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <telerik:RadScriptManager ID="RadScriptManager1" Runat="server">
            </telerik:RadScriptManager>
            <asp:DropDownList ID="cboCriteria" runat="server" AutoPostBack="True">
                <asp:ListItem>Select a form</asp:ListItem>
                <asp:ListItem Value="Telerik">Form With Telerik Control</asp:ListItem>
                <asp:ListItem Value="ASP">Form With ASP Control</asp:ListItem>
            </asp:DropDownList>
            <br />
            <asp:PlaceHolder ID="PlaceHolder1" runat="server"></asp:PlaceHolder>
            <br />
        </div>
    </form>
</body>
</html>

 

DynamicControls.vb

Imports Telerik.Web.UI
Public Class DynamicContrls
  Inherits System.Web.UI.Page
 
  Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
 
    'If Not Session("ControlsCreated") = Nothing Then
    CreateControl(cboCriteria.SelectedItem.Value)
    'End If
 
  End Sub
 
 
  Private Sub CreateControl(ControlType As String)
 
    Select Case ControlType
      Case "Telerik"
        RenderTelerikControls()
      Case "ASP"
        RenderASPControls()
    End Select
 
    Session("ControlsCreated") = True
 
  End Sub
 
  Private Sub RenderTelerikControls()
    Dim txtFirst As New RadTextBox
 
    txtFirst.ID = "txtTelerik" & Guid.NewGuid.ToString
 
    PlaceHolder1.Controls.Add(txtFirst)
    PlaceHolder1.Controls.Add(New LiteralControl("<BR>"))
  End Sub
 
  Private Sub RenderASPControls()
    Dim txtFirst As New TextBox
 
    txtFirst.ID = "txtASP" & Guid.NewGuid.ToString
 
    PlaceHolder1.Controls.Add(txtFirst)
    PlaceHolder1.Controls.Add(New LiteralControl("<BR>"))
  End Sub
 
  Protected Sub cboCriteria_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cboCriteria.SelectedIndexChanged
    ' For this example, simply reload the page.
  End Sub
 
End Class
JenMaryland
Top achievements
Rank 1
 answered on 30 Mar 2020
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?