Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
106 views
Hi,

I'm facing a problem with my grid. I want to fill or edit a extra database field that is not shown in de datagrid or editform.
I'm using a linq datasource.
Is this possible?

thanks in advance..
Rik
Top achievements
Rank 1
 answered on 15 Oct 2009
1 answer
244 views
Hi
    We have used Rad Telerik AJAX Q2 2008 version's Rad Grid.

I want follwing functionality on Rad Grid.
       Right now when user clcik on grid column header then sorting data as ascendig first time.
But I want to set descending sorting when user click on grid column header first time.

Please give you reply.

Thanks
Swapnil

Princy
Top achievements
Rank 2
 answered on 15 Oct 2009
4 answers
227 views
HI,

I want to display an empty line in the RadComboBox as a first element without checkbox in it. see the code below,

<Telerik:GridBoundColumn HeaderText="DEmo" DataField="DEmo">
<FilterTemplate>
<Telerik:RadComboBox ID="RadCombo1" runat="server" DataTextField="CMBITEM" DataValueField="CMBITEM" DataSourceID="SQLDS" SelectedValue='<%# TryCast(Container,GridItem).OwnerTableView.GetColumn("DEmo").CurrentFilterValue %>' AppendDataBoundItems="true" Width="100" OnClientDropDownClosing="mouseouts" EmptyMessage="">
<ItemTemplate>
<div  id="div1" onclick="StopPropagation(event)" />
<asp:CheckBox runat="server" ID="CheckBox1" Text='<%# Eval("CMBITEM") %>' onClick="onCheckBoxClick(this);" />
</ItemTemplate>
</Telerik:RadComboBox>

Withthis Combobox is displaying like

Combo: 
CheckBox with Item1
CheckBox with Item2
CheckBox with Item3

I want
Combo: 
[Empty Line]
CheckBox with Item1
CheckBox with Item2
CheckBox with Item3

If I use this code below,

    Protected Sub RadCombo1_DataBound(ByVal sender As Object, ByVal e As System.EventArgs)
        Dim RAB As RadComboBox = DirectCast(sender, RadComboBox)
        RAB.Items.Insert(0, New RadComboBoxItem(""))
    End Sub

I am getting,

Combo: 
Checkbox [Empty Line]
CheckBox with Item1
CheckBox with Item2
CheckBox with Item3
Sebastian
Telerik team
 answered on 15 Oct 2009
5 answers
256 views
Hello,

I have strange problem with AppointmentTemplate.Even if I declared my custom template, I can still see only the built in one.I am stuck on this for few hours and cannot get it to work.Please can You give me some advice.I am using Web service binding in ASP.NET MVC
Here is my code:


<%@ Page Title="" Language="C#" AutoEventWireup="true" MasterPageFile="~/Views/Shared/Site.Master"
    Inherits="System.Web.Mvc.ViewPage" %>

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    <%= Html.PageTitle() %>
</asp:Content>

<script runat="server">

    protected override void OnLoad(EventArgs e)
    {
        RadScheduler1.Culture = CRM.Web.Code.Globalization.GlobalizationManager.CurrentUICulture;
        base.OnLoad(e);
    }
</script>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <form runat="server">
    <h2>
        <%= Html.PageTitle() %></h2>

    <script type="text/javascript">

        /* Firefox resize scrollable content */
        function hideScrollableArea(sender, eventArgs) {
            if ($telerik.isFirefox)
                $telerik.$('.rsContentScrollArea').css('overflow', 'hidden');
        }
        function showScrollableArea(sender, eventArgs) {
            if ($telerik.isFirefox)
                $telerik.$('.rsContentScrollArea').css('overflow', 'auto');
        }

        function OnClientAppointmentDoubleClick(sender, eventArgs) {
            var apt = eventArgs.get_appointment();

            document.location = '<%= HttpContext.Current.CreateUrl("/Appointment/Detail/") %>' + apt._id;
        }

        function OnClientTimeSlotClick(sender, eventArgs) {

            document.location = '<%= HttpContext.Current.CreateUrl("/Appointment/Create?") %>StartTime=' + eventArgs.get_time().format('dd/MM/yyyy H:mm');
        }
        //]]>


    </script>

    <telerik:RadScheduler runat="server" ID="RadScheduler1" AllowDelete="false" AllowEdit="true"
        AllowInsert="false" StartEditingInAdvancedForm="false" OnClientAppointmentDoubleClick="OnClientAppointmentDoubleClick"
        OnClientTimeSlotClick="OnClientTimeSlotClick" Height="900px">
        <AppointmentTemplate>
            <div>
                Test :
                <%= Eval("Subject") %>
            </div>
        </AppointmentTemplate>
        <TimelineView GroupBy="Calendar" GroupingDirection="Vertical" />
        <WebServiceSettings Path="~/Models/SchedulerWebService.asmx" />
    </telerik:RadScheduler>
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server" EnableScriptLocalization="true"
        EnableScriptGlobalization="true">
    </telerik:RadScriptManager>
    </form>
</asp:Content>
Peter
Telerik team
 answered on 15 Oct 2009
2 answers
212 views
Hi there 

I am using the following code to load RadComboBox and insert the RadComboBox with a  text "select item" at the top which is fairly basic, but I am unable to see the text "select item" added when clicking the dropdown.  Please Advice!
[Code and error image attached]

Thanks
Siva

        <telerik:RadComboBox  ID="RadComboBox1" runat="server" Height="190px" Skin="Office2007" 
                        Width="300px" MarkFirstMatch="true"  NoWrap="true" DropDownWidth="420px" EnableLoadOnDemand="true" HighlightTemplatedItems="true" 
                        ItemRequestTimeout="500"> 
                        <HeaderTemplate> 
                            <ul> 
                                <li class="col1">Company Name</li> 
                            </ul> 
                        </HeaderTemplate> 
                        <ItemTemplate> 
                            <ul> 
                                <li class="col1"><%# DataBinder.Eval(Container.DataItem, "CompanyName") %></li> 
                            </ul> 
                        </ItemTemplate> 
                    </telerik:RadComboBox> 
  Dim sql As String = "SELECT * from Customers" 
        Dim adapter As New SqlDataAdapter(sql, ConfigurationManager.ConnectionStrings("NorthwindConnectionString").ConnectionString) 
 
        Dim dt As New DataTable() 
        adapter.Fill(dt) 
        RadComboBox1.DataTextField = "CompanyName" 
        RadComboBox1.DataValueField = "City" 
        RadComboBox1.DataSource = dt 
        RadComboBox1.DataBind() 
 
        RadComboBox1.Items.Insert(0, New Telerik.Web.UI.RadComboBoxItem("Select Item", "None")) 

Veselin Vasilev
Telerik team
 answered on 15 Oct 2009
3 answers
228 views
Hi All,

I am using Telerik Rad Grid for export pdf.
Q-1 : How can i add page no?
Q-2 : I have generic list and i wan to page break on new record than how can i do it?
Q-3 : How can i give file name for PDF and Excel?
Q-4: How can i give page title for Exporting Excel?
Q-5 How can change font size, font style in export to pdf?

Thanks in advance if anyone can help me.

Rajesh.
Bruno
Top achievements
Rank 2
 answered on 15 Oct 2009
1 answer
210 views
I have a PopUp editform within a <FormTemplate />.  The form has a DropDownList that can be manipulated at runtime by Javascript. 
Since its hidden by FormTemplate, is there any way to access it so that I can disable EventValidation?

Here's what I have:

       protected override void Render(System.Web.UI.HtmlTextWriter writer)  
        {  
            Page.ClientScript.RegisterForEventValidation(((DropDownList)((GridDataItem)RadGrid1.EditItems[0]).EditFormItem.FindControl("ddlCategory")).UniqueID);  
            base.Render(writer);  
        } 
Rosen
Telerik team
 answered on 15 Oct 2009
3 answers
122 views
Is it possible to prevent a window from being shown until after the content is loaded and after I set the height and width?  The problem I am having is with respect to dynamic content. So...  width=300, height=300 might work in some case but only a few. I want to eliminate the flicker of resizing the window. 

I have tried using the AutoSize feature and after find it does not suit my need.  AutoSize will also randomly resize the window to something smaller than the content.  I also do not want the animation that comes with the AutoSize feature.

Georgi Tunev
Telerik team
 answered on 15 Oct 2009
2 answers
114 views
Can anyone tell me which version of the RadGrid was the first to introduce the Export To PDF function?  We have several products on different releases and I need to document which ones will support PDF.

Thanks,
Brian
Bruno
Top achievements
Rank 2
 answered on 15 Oct 2009
0 answers
115 views
Hello, I was hoping someone could help me with this.

I've just recently started working on RadScheduler and I wasn't quite able to configure it the way I wanted.
I already managed to connect it to my database, which was no problems at all.
Here's a few steps on what I'm trying to achieve:

1. One or more resources needs to be displayed at the same time for each day, each resource have their own appointments.
2. Each resource have a certain time range that they can get appointments within.
3. This area where it's possible to have appointments, I would like to have the background on those cells in a different color. So as to mark which time range appointments are allowed to be in.
4. Only one appointment per resource per time is allowed. I'd like this to be checked on server-side.
5. Appointments are allowed to be moved from one resource to another.

A few examples of what I'm trying to achieve to help understand:

Resource A and Resource B are working on day x.
Resource A has his time range between 08:00 to 12:00
Resource B has his time range between 10:00 to 15:00
On the column for Resource A, the cells between 08:00-12:00 needs to have a different background color (green for example).
On the column for Resource B, the cells between 10:00-15:00 needs to have a different background color (green for example).
Resource A have an appointment(1) on between 09:00 and 10:00.
Resource B have an appointment(2) on between 10:00 and 11:00.
1 is allowed to be moved to Resource B to 11:00-12:00.
1 is not allowed to be moved to Resource B within 10:00-11:00.
1 is not allowed to be moved to Resource B at 08:00-09:00 (because of the time range)

I hope I was clear enough, please ask any questions if needed. Oh and I'm working with C#.

Thanks in advance,
Cristoffer
Patrik Holmberg
Top achievements
Rank 1
 asked on 15 Oct 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?