Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
422 views
I need to be able to have a calendar which only allows the user to select a saturday if a 7 nights is chosen from a combo box on a form and to allow the user to just select a monday if an 4 nights is chosen from the combo box.

I am currently using the RadDatepicker and have set it up to add the disabled dates for the year to the special days. So if a 7 is selected the dt variable will be every day except a saturday.
RadCalendarDay holiday = new RadCalendarDay();
        holiday.Date = dt;
        holiday.IsSelectable = false;
        holiday.IsDisabled = true;
        CalendarPopup1.Calendar.SpecialDays.Add(holiday);

I don't seem to be able to get this to work. I am also trying to reset the calendar whenever the combo box value changes. But can't get this to work either.
public void ResetCalendar()
{
    CalendarPopup1.Clear();
    CalendarPopup1.Calendar.SpecialDays.Clear();
}

Katie
Top achievements
Rank 1
 answered on 05 Jul 2012
3 answers
249 views
Hi Forum,
I have a RADGrid with a RADComboBox column with EnableLoadOnDemand=true and ItemsRequest event defined.

<telerik:RadComboBox ID="cboLocalita"

EnableVirtualScrolling="true"

OnItemsRequested="cboLocalita_ItemsRequested"

ShowMoreResultsBox="true"

EnableLoadOnDemand="true"

DataTextField ="descrizione"

DataValueField ="idlocalita"

runat="server">

</telerik:RadComboBox>

Protected Sub cboLocalita_ItemsRequested(ByVal o As Object, ByVal e As Telerik.Web.UI.RadComboBoxItemsRequestedEventArgs)
    Dim context As New JLogTabelleDataContext
    Dim allLocalita = From localita In context.localita _
     Order By localita.descrizione _
     Select localita
    If Not [String].IsNullOrEmpty(e.Text) Then
        allLocalita = From localita In context.localita _
         Where localita.descrizione.StartsWith(e.Text) _
         Order By localita.descrizione _
         Select localita
    End If
    Dim Lstlocalita = allLocalita.Skip(e.NumberOfItems).Take(10)
    CType(o, RadComboBox).DataSource = Lstlocalita
    CType(o, RadComboBox).DataBind()
    Dim endOffset As Integer = e.NumberOfItems + Lstlocalita.Count()
    Dim totalCount As Integer = allLocalita.Count()
    If endOffset = totalCount Then
        e.EndOfItems = True
    End If
    e.Message = [String].Format("Rec <b>1</b>-<b>{0}</b> Tot <b>{1}</b>", endOffset, totalCount)
End Sub

The automatic CRUD operation enabled on the Grid doesn't work, so the value of RADComboBox never change after update of then EditForm and is setted to NULL when I perform a created operation.

If I bind the Combobox to a Datasource object by the property DataSourceID and I disable EnableLoadOnDemand without implement OnItemsRequest event , CRUD works fine. I have a lot of records to show in ComboBox therefore Loading data on demand is very important.
Thanks to all for any response.
Gaetano
Tsvetina
Telerik team
 answered on 05 Jul 2012
3 answers
424 views
How can I make RadNotification stay in 1 place at all times despite scrolling? I would like to position it relative (below) an image.
Princy
Top achievements
Rank 2
 answered on 05 Jul 2012
1 answer
161 views

How can i get the Add Expression or Remove item ID of the RadFilter in server side.
It's Urgent
See The Image

Thanks Advance,
Mohamed.
Martin
Telerik team
 answered on 05 Jul 2012
1 answer
126 views

How I get RadFilter Add expression Click Id ,
It's Urgent
See The Image

Thanks Advance,
Mohamed.
Martin
Telerik team
 answered on 05 Jul 2012
5 answers
284 views
Hi,

I have a tree view control. In that I have tree view populted with Node Image and Text Property.

I have added a new node template column with asp.Image button control inside node template column.
But when I added node template column Text property of Rad Tree view is not showing :(.
 
Please give some hints on this scenario.
A2H
Top achievements
Rank 1
 answered on 05 Jul 2012
3 answers
326 views
Hi All,
I have a grid which is perfectly fine and fill with data.
Now i need to loop through the grid in order to read out its column name and data in a button click event.I have search online and try with few  alternatives and it is not working.Can anyone help?
I have try with :

1). ajaxExport.Columns(0).HeaderText

2). For Each column As GridDataItem In ajaxExport.Items
                If TypeOf column Is GridDataItem Then
                    Dim col As GridDataItem = TryCast(column, GridDataItem)

                    a = col(0).Text
                    'col.Width = 90
                    'col.HeaderText = "Column count: " + i.ToString
                    i = i + 1
                End If
            Next


Help Please!!
Shinu
Top achievements
Rank 2
 answered on 05 Jul 2012
3 answers
177 views
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="test.aspx.cs" Inherits="mtidb_app.test" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="radsm" runat="server" EnablePageMethods="true" EnablePartialRendering="true" />  
    <telerik:RadWindowManager ID="RadWindowManager2" runat="server" EnableShadow="true" ></telerik:RadWindowManager>
    <telerik:RadAjaxManager ID="radam" runat="server" EnableHistory="True"></telerik:RadAjaxManager>
    <telerik:RadAjaxLoadingPanel id="LoadingPanel" Runat="server" Transparency="30" EnableSkinTransparency="false" Width="100%" Height="100%" BackgroundPosition="Center"  >   
    </telerik:RadAjaxLoadingPanel>  
    
    <telerik:RadAjaxPanel ID="radp4" runat="server" LoadingPanelID="LoadingPanel" Width="100%" >
    <telerik:RadCodeBlock ID="RadCodeBlock4" runat="server">
        <script type="text/javascript">
            function CalculateAdjustment() {
                var reg = $find("<%= tbAdjustReg.ClientID %>");
                var tuition = $find("<%= tbAdjustTuition.ClientID %>");
                var admin = $find("<%= tbAdjustAdmin.ClientID %>");
                var supply = $find("<%= tbAdjustSupply.ClientID %>");
                var uniform = $find("<%= tbAdjustUniform.ClientID %>");
                var textbook = $find("<%= tbAdjustTextbook.ClientID %>");
                var other = $find("<%= tbAdjustOther.ClientID %>");
                var tax = $find("<%= tbAdjustTax.ClientID %>");
                var total = $find("<%= tbAdjustTotal.ClientID %>");

              if (reg.get_value() == '') reg.set_value('0');
               if (tuition.get_value() == '') tuition.set_value('0');
                if (admin.get_value() == '') admin.set_value('0');
                if (supply.get_value() == '') supply.set_value('0');
                if (uniform.get_value() == '') uniform.set_value('0');
                if (textbook.get_value() == '') textbook.set_value('0');
                if (other.get_value() == '') other.set_value('0');
                if (tax.get_value() == '') tax.set_value('0');

                total.set_value(reg.get_value() + tuition.get_value() + admin.get_value() + supply.get_value() + uniform.get_value() + textbook.get_value() + other.get_value() + tax.get_value());
            }
        </script>
    </telerik:RadCodeBlock>                    

<div><telerik:RadNumericTextBox ID="tbAdjustReg" runat="server" ClientEvents-OnValueChanged="CalculateAdjustment" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustTuition" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustAdmin" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustSupply" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustTextbook" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustUniform" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustOther" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustTax" ClientEvents-OnValueChanged="CalculateAdjustment" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
<div><telerik:RadNumericTextBox ID="tbAdjustTotal" ReadOnly="true" runat="server" Type="Currency" NumberFormat-DecimalDigits="2" Width="110" /></div>
</telerik:RadAjaxPanel>
</form>
</body>
</html>


The code working well in v2.0.50727 version but when i try to switch Q2 2012, it is just stop working.
Pls hlp
Shinu
Top achievements
Rank 2
 answered on 05 Jul 2012
5 answers
339 views
Firstly am very fresh to this components. I already used css to lay asp:labels and asp:textboxes etc ..even grid control and calender cntrls in asp.
We need UI help to design a big project which have lot of labels and its Associated Input fields to lay ...2 column ..3 column upto 4
So how we have to write our CSS.

I just go thru the a page which is fully filled with telerick controls. And i found we cant change their color or margins or paddings thru CSS. Only we can control its width from an external CSS file. Also dropdowns are rendering inside a table so i cant control its width with SELECT tag.

Also i found that in grid if column increase width also increase will break layout ..Pls help me am attaching a sample page in our present ASP application
Thanks in Adv
 
UI Designer
Vargis
Top achievements
Rank 1
 answered on 05 Jul 2012
2 answers
163 views
Problem 1

As you described in your own website
http://www.telerik.com/help/aspnet-ajax/input-css-width.html

CssClass="TextBoxClass" is not working in telerik:RadTextBox. Its default width is rendering. Here is the css and aspx part.

CSS---------------------------------------------------------------------------------------------------------------------------------------------------------------

.divcol-S .TextBoxClass {width:70%!important}

ASP Page---------------------------------------------------------------------------------------------------------------------------------------------------------------------

<div class="divcol-S">

<asp:Label ID="Label26" runat="server" Text="Vessel Name"></asp:Label>
<telerik:RadTextBox ID="txtVesselName" runat="server" CssClass="TextBoxClass"></telerik:RadTextBox>

<asp:Label ID="Label29" runat="server" Text="Vessel Type" ></asp:Label>
<telerik:RadComboBox ID="ddlVesselType" runat="server" CssClass="TextBoxClass"></telerik:RadComboBox>

</div>
_________________________________________________________________________________________________________________________________________________


Problem 2

As you described in your own website
http://www.telerik.com/help/aspnet-ajax/input-css-selectors.html

.riTextBox - INPUT OR TEXTAREA - The common class for the input area in all states. (from your own words)
(These class names are for the "Default" skin. For other skins, replace the string "Default" with the name of the skin.)

This means we can change the property of input/textarea globally in the entire application with this specific ClassName .riTextBox.
So no need to put CssClass on every <telerik:RadTextBox> control. But unfortunately this also not working.


CSS---------------------------------------------------------------------------------------------------------------------------------------------------------------

.divcol-S .riTextBox {width:70%!important}

ASP Page---------------------------------------------------------------------------------------------------------------------------------------------------------------------

<div class="divcol-S">

<asp:Label ID="Label26" runat="server" Text="Vessel Name"></asp:Label>
<telerik:RadTextBox ID="txtVesselName" runat="server" ></telerik:RadTextBox>

<asp:Label ID="Label29" runat="server" Text="Vessel Type" ></asp:Label>
<telerik:RadComboBox ID="ddlVesselType" runat="server" ></telerik:RadComboBox>

</div.

Thanks in Adv
Vargis
Top achievements
Rank 1
 answered on 05 Jul 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?