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

Team,

I've 3 RadComboBox inside RadListview. I just want to get the selectedIndex of the each Radcombobox items lying inside the RadListView.
Aready am using RadListView_ItemDataBound event for databing.
What way I can retrieve the SelectedIndex?


//Thanks....

Shinu
Top achievements
Rank 2
 answered on 20 Feb 2012
1 answer
71 views
I have a page that requires about 100 combo boxes with some ajax features. RadComboBox consumes a whooping 100K of HTML on the client side. When I looked into the combo box I found that it is rendered with table tag and have big names for the styles as well as using inline styles.

Maybe a lightweight combobox (with simple div and less heavyweight classes would be useful). I can understand all the flexibility etc, but IMHO this is not very efficiently designed (comparing with the free ones like flexbox etc.)

Now my question is, is there any trick to stylesheet or template etc. that can reduce the size of the html rendered by the combobox? maybe I would be allowed to use cascading stylesheet and reduce the size?
Princy
Top achievements
Rank 2
 answered on 20 Feb 2012
1 answer
79 views
Hi there-

I want to detect if a DropDown field had an empty value before entering editmode but can't seem to tell how. What's happening is when I open inline editing for a item, the DropDown autoselect the first item in the datasource that the dropdown is bound to... even if previously there was no value in there. 

So for example I have no text values in this column:
 <telerik:GridDropDownColumn DataField="DataCenterCode" DataSourceID="SqlDataSource_DataCenters"
                            HeaderText="DataCenterCode" ListTextField="Acronym" ListValueField="Acronym"
                            UniqueName="DataCenterCode" ColumnEditorID="GridDropDownColumnEditor2">
                      </telerik:GridDropDownColumn>

But then once I enter edit mode, the first value is automatically selected. How can I determine if the value is actually empty for this field so that I can highlight it as requiring selection. Otherwise, it appears as though the first value was already selected.

Thanks for any help.
Princy
Top achievements
Rank 2
 answered on 20 Feb 2012
1 answer
211 views
I'm looking for some example markup/code or direction on what I think is probably a fairly common thing.  But I'm having a bit of trouble figuring out the right pieces. 

I need a grid that has two checkboxes (in 2 columns) along with some other columns.  I'd also like to put a checkbox in the grid's header area above each checkbox column so that the user can toggle the checked state of all the checkboxes in that column.  I'd like that to all be done client-side.

Any guidance would be greatly appreciated.


I should mention a couple of points

1) I'm not trying to select grid rows.  In the header, if I click "Check All", I just want to iterate through all rows and set the checked state of 2 checkboxes. I don't know if the ColumnClick event is the right place to start.  And if so, how then do I loop through all the rows, find the checkbox in the row and set it's checked state to match?

2) I'm also trying to implement mutually exclusive checkboxes.  So when I click an individual checkbox in a row, I want to be sure to deselect/uncheck the other checkbox in the row.

All client-side.

Thanks in advance.
Shinu
Top achievements
Rank 2
 answered on 20 Feb 2012
6 answers
322 views
Hi

I have an ASP.NET 3.5 web project running in a fraemewok 4.0 pool on IIS 6.  We have an old ComboBox control (RadComboBox.Net2.dll version 2.8.4.0) that seems to not render properly. 

Each individual item renders a <div> tag with the same id (the name of the control).

Is there some fancy way we can get this to render correctly - so that it works - using the web.config file or something?

 
Ace
Top achievements
Rank 1
 answered on 20 Feb 2012
3 answers
135 views
have a hierarchical (nested) (multi-level) tabstrip with root tabs (level 1) and child tabs (level 2).  How do I auto select a child tab be default auto-selected child tab when I select a root tab??
thanks
Kevin Mason
Top achievements
Rank 1
 answered on 20 Feb 2012
4 answers
144 views
I just wanted to post this so someone else doesn't waste the 9 hours I wasted the other day.  If you are using the RadCompression Module, in conjunction with jquery/javascript ajax calls to the web server you WILL have the following issue on your Visual Studio development web server.

The following demonstrates the issue:

Standard Telerik module includes in the system.web section of the web.config:
<httpModules>
<add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule"/>
<add name="RadCompression" type="Telerik.Web.UI.RadCompression"/>
</httpModules>

Standard Telerik module includes in system.webServer section of the web.config:
<modules runAllManagedModulesForAllRequests="true">
    <remove name="RadUploadModule"/>
    <add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule" preCondition="integratedMode"/>
    <remove name="RadCompression"/>
    <add name="RadCompression" type="Telerik.Web.UI.RadCompression" preCondition="integratedMode"/>
</modules>

The results of the Ajax call with the compression module included can be seen in the screen4.png attachment.

If we turn the compression module off (as follows):
<httpModules>
<add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule"/>
</httpModules>


<modules runAllManagedModulesForAllRequests="true">
<remove name="RadUploadModule"/>
<add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule" preCondition="integratedMode"/>
<remove name="RadCompression"/>
</modules>


The results of the Ajax call with the compression module not included can be seen in the screen5.png attachment.

Please note:  This is only an issue with the Web development server.  IIS handles the compression correctly.

I hope this helps anyone struggling with thier Ajax Calls while using telerik. 

Thanks,
Anthony
Andrew
Top achievements
Rank 1
Iron
Iron
 answered on 20 Feb 2012
4 answers
397 views
Hello,

I have a standard DateTimePicker control and I'd like to have a custom validator (server side) against it, something like this:

<telerik:RadDateTimePicker ID="picker1" runat="server" SelectedDate="<%#((DateTime)((DataRowView)Container.DataItem)[1])%>"  > 
  <DateInput DateFormat="d.M.yyyy H:mm" DisplayDateFormat="d.M.yyyy H:mm"  /> 
  <TimeView StartTime="10:0:0" EndTime="21:01:00" Interval="0:15:0" Columns="7" TimeFormat="HH:mm" Culture="cs-CZ" />  
</telerik:RadDateTimePicker> 
                     
<asp:CustomValidator ID="custValCasVykopu" runat="server" ControlToValidate="picker1" Display="dynamic" Text="Enter correct date and time" OnServerValidate="custValCasVykopu_Validate" /> 
                     

and on the server:

protected void custValCasVykopu_Validate(object source, ServerValidateEventArgs args) 
            string txtCasVykopu = args.Value; 
            DateTime casVykopu; 
            if (DateTime.TryParse(txtCasVykopu, out casVykopu)) 
            { 
                args.IsValid = true
            } 
            else 
            { 
                args.IsValid = false
            } 

Now, the problem is that in this setup, args.value is looking like this: "2010-02-27-15-00-00" and this will not parse thru DateTime.TryParse (or at least I have not found a proper combination of culture and DateTimeStyles settings that will parse this string).

My question is - is there any way to modify value property of DateTimePicker so it will produce string that will parse thru DateTime.TryParse ?

Thanks,

Antonin



Uday Anthony
Top achievements
Rank 1
 answered on 19 Feb 2012
0 answers
76 views
Hi,

I have a problem when the RadTextBox is placed within a RadAjaxPanel control as below.
By clicking submit, the RadTextBox text doesn't submitted. By removing the AutoPostBack attribute and the OnSelectedIndexChanged event of the RadComboBox controls then the RadTextBox text does submit. In addition If I don't use the RadAjaxPanel control then the RadTextBox text does submit too.

aspx:
<telerik:RadAjaxPanel ID="SSS" runat="server">
<table border="0" cellpadding="0" cellspacing="0" width="700px">
    <tr>
        <td width="120">
            <asp:Label ID="CyclLabel" runat="server" SkinID="FieldLabel" Text="Cycle:"></asp:Label>
        </td>
        <td  width="250">
            <telerik:RadComboBox ID="CycleRadComboBox" runat="server" Enabled="true" Width="215px" AutoPostBack="true" OnSelectedIndexChanged="CycleRadComboBox_SelectedIndexChanged">
                <Items>
                    <telerik:RadComboBoxItem runat="server" Text="Select Cycle" Value="" />
                    <telerik:RadComboBoxItem runat="server" Text="BVT" Value="BVT" />
                    <telerik:RadComboBoxItem runat="server" Text="GQL" Value="GQL" />
                </Items>
                <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation>
            </telerik:RadComboBox>
        </td>
        <td  width="100">
            <asp:Label ID="StatusLabel" runat="server" SkinID="FieldLabel" Text="Status:"></asp:Label>
        </td>
        <td width="*">
            <telerik:RadComboBox ID="StatusRadComboBox" runat="server" Enabled="false" Width="215px" AutoPostBack="true" OnSelectedIndexChanged="StatusRadComboBox_SelectedIndexChanged">
                <Items>
                    <telerik:RadComboBoxItem runat="server" Text="Select Status" Value="" />
                    <telerik:RadComboBoxItem runat="server" Text="Passed" Value="Passed" />
                    <telerik:RadComboBoxItem runat="server" Text="Failed" Value="Failed" />
                    <telerik:RadComboBoxItem runat="server" Text="Passed with known issues" Value="Passed with known issues" />
                </Items>
                <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation>
            </telerik:RadComboBox>
        </td>
    </tr>
    <tr style="height:55px;" >
        <td valign="top" width="120">
          <div style="margin-top:9px;" >
            <asp:Label ID="CmntLabel" runat="server" SkinID="FieldLabel" Text="Comment:"></asp:Label>
          </div>
        </td>
        <td colspan="3"  width="*">
            <telerik:RadTextBox ID="CommentRadTextBox" runat="server"  Width="560px" TextMode="MultiLine" Rows="2"></telerik:RadTextBox>
        </td>
    </tr>
    <tr style="height:50px;">
        <td colspan="4">
            <asp:Button ID="SubmitButton" runat="server" SkinID="ImageAndTextButton" OnClick="SubmitButton_Click" Text="Submit" />
        </td>
    </tr>
</table>
<asp:Label ID="CommentTextLabel" runat="server" Text=""></asp:Label>
</telerik:RadAjaxPanel>

c#:
protected void Page_Load(object sender, EventArgs e)
        {
 
        }
 
        protected void SubmitButton_Click(object sender, EventArgs e)
        {
            CommentTextLabel.Text = CommentRadTextBox.Text;
        }
 
        protected void CycleRadComboBox_SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
        {
            if (!Convert.ToString(e.Value).Equals(string.Empty))
                StatusRadComboBox.Enabled = true;
            else
            {
                StatusRadComboBox.Enabled = false;
                CommentRadTextBox.Enabled = false;
            }
        }
 
        protected void StatusRadComboBox_SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
        {
            if (!Convert.ToString(e.Value).Equals(string.Empty))
                CommentRadTextBox.Enabled = true;
            else CommentRadTextBox.Enabled = false;
        }


Can you please expalin to me how to fix this problem?

Regards,
Bader
Bader
Top achievements
Rank 1
 asked on 19 Feb 2012
1 answer
46 views
I'm using the RadToolBar in a project and the client has requested now that instead of simply having a textbox show when "Search" is clicked (like by using itemtemplate), they want > 1 textbox to appear to the right of the menu option. All of these textboxes will be autocomplete with a button available to clear the search at the farthest right point. Any suggestions on how to make this work in the toolbar?
Kate
Telerik team
 answered on 18 Feb 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?