Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
138 views
Hey !

I want to create a filter Template in Code Behind, but it's hard for me, can you help me ?

I would like to be able to filter the names of technicians with a combobox !

This is my code :

protected void Page_Load(object sender, EventArgs e)
{
    GetGestionDoc();
}

{
    if (Session["NumStation"] != null)
    {
        int numStation = Convert.ToInt32(Session["NumStation"]);
        document = entities.V_RAPPORTSVALIDES.Where(p => p.ID_STATION == numStation).ToList();
 
        List<DocumentObject> newList = new List<DocumentObject>();
 
        foreach (var item in document)
        {
            DocumentObject o = new DocumentObject(item.TYPE_VISITE, item.TYPE_DOCUMENT, Convert.ToDateTime(item.DATE_DOCUMENT), Convert.ToInt16(item.ANNEE_RAPPORTANNUEL), item.NOM_TECHNICIEN);
            newList.Add(o);
        }
 
        RadCommentGrid.DataSource = newList;
        RadCommentGrid.DataBind();
 
        ChangeHeaderName();
    }
}

private void ChangeHeaderName()
{
    foreach (GridColumn column in RadCommentGrid.MasterTableView.AutoGeneratedColumns)
    {
        switch (column.OrderIndex)
        {
            case 2:
                column.HeaderText = "Date du document";
                break;
            case 3:
                column.HeaderText = "Type de document";
                break;
            case 4:
                column.HeaderText = "Nom du technicien";
                break;
            case 5:
                column.HeaderText = "Type de visite";
                break;
            case 6:
                column.HeaderText = "AnnĂ©e du rapport annuel";
                break;
        }
    }
 
    GridColumn columnDateDoc = RadCommentGrid.MasterTableView.AutoGeneratedColumns.Where(p => p.UniqueName == "DATE_DOCUMENT").FirstOrDefault();
    columnDateDoc.OrderIndex = 1;
 
    GridColumn columnTypeDoc = RadCommentGrid.MasterTableView.AutoGeneratedColumns.Where(p => p.UniqueName == "TYPE_DOCUMENT").FirstOrDefault();
    columnTypeDoc.OrderIndex = 2;
 
    GridColumn columnTechnicien = RadCommentGrid.MasterTableView.AutoGeneratedColumns.Where(p => p.UniqueName == "NOM_TECHNICIEN").FirstOrDefault();
    columnTechnicien.OrderIndex = 3;
 
    GridColumn columnVisite = RadCommentGrid.MasterTableView.AutoGeneratedColumns.Where(p => p.UniqueName == "TYPE_VISITE").FirstOrDefault();
    columnVisite.OrderIndex = 4;
 
    GridColumn columnAnnee = RadCommentGrid.MasterTableView.AutoGeneratedColumns.Where(p => p.UniqueName == "ANNEE_RAPPORTANNEE").FirstOrDefault();
    columnAnnee.OrderIndex = 5;
}


I see in your demo, you can create a filter with a radcombobox but its in XML :

<telerik:RadComboBox
     
    ID="RadComboBoxTitle"
     
    DataSourceID="SqlDataSource2"
     
    DataTextField="ContactTitle"
     
    DataValueField="ContactTitle"
     
    Height="200px"
     
    AppendDataBoundItems="true"
     
    SelectedValue='<%# ((GridItem)Container).OwnerTableView.GetColumn("ContactTitle").CurrentFilterValue %>'
     
    runat="server"
     
    OnClientSelectedIndexChanged="TitleIndexChanged">
     
    <Items>
        <telerik:RadComboBoxItem Text="All" />
    </Items>
     
</telerik:RadComboBox>

Eyup
Telerik team
 answered on 29 Jan 2015
1 answer
449 views
I have a gridview with column name "Domain"

BY default it shows a single filter att one time but i want multiple filter in one time in single column

My RadGrid Structure is this

DOMAIN
@yahoo.com
@gmail.com
@india.com


I want to filter domain other than @yahoo.com and @gmail.com

How to do that in RadGrid Filter ??
 
 
Eyup
Telerik team
 answered on 29 Jan 2015
1 answer
57 views
Hi,

is it possible or a planned feature to mark certain days as holidays inside the calender for planning the different tasks?
Thank you.

Regards,
Felix
Bozhidar
Telerik team
 answered on 29 Jan 2015
1 answer
75 views
Hi,

is it possible to create a task inside the gantt-chart without a determination of the start time and end time? Because in some project plannings I want to create some tasks but do not know when they are going to start or end. Thanks.

Regards,
Felix
Bozhidar
Telerik team
 answered on 29 Jan 2015
1 answer
133 views
I want to bind the RadScheduler control from dataset, I have set all the required properties like DataStartField, DataEndField, DataSubjectField, DataKeyField etc, but couldn't able to show appointments on the Control. For your information I'm getting data in dataset from SQL Server Database and there is no chance that dataset is null. Please help with both RadScheduler design and aspx.cs part.
Boyan Dimitrov
Telerik team
 answered on 29 Jan 2015
8 answers
161 views
We're using the DiffEngine component to identify changes between saved versions of the Editor content.  These version changes must then be approved by a Content Approver (user). There are two problematic scenarios we have encountered.

Scenario 1:

version 1 html:  <a title="xxx" href="http://wwww.test.com/xxxxx.pdf">a link</a>
version 2 html:  <a title="yyyy" href="http://wwww.test.com/yyyyyyy.pdf">a link</a>

The DiffEngine reports no differences in these two HTML snippets. This is a major problem for us. The linked document (href) was changed and the "title" content was changed; we need for these changes to be identified so they can be approved by the Content Approver user.


Scenario 2:

version 1 html:  <img src="http://demos.telerik.com/aspnet-ajax/editor/images/editor.jpg" alt="telerik" />
version 2 html:  <img src="http://demos.telerik.com/aspnet-ajax/editor/images/editor.jpg" alt="telerik">

The DiffEngine reports a difference in these two html snippets, despite the fact that only the closing tag changed.

Here's the output of the DiffEngine:

<table class="diff_deleted"><tr><td><img src="http://demos.telerik.com/aspnet-ajax/editor/images/editor.jpg" alt="telerik" /></td></tr></table><table class="diff_new"><tr><td><img src="http://demos.telerik.com/aspnet-ajax/editor/images/editor.jpg" alt="telerik"></td></tr></table>


Scenario 2 is more of a nuisance, but it would be nice if the DiffEngine would ignore something as trivial as a closing tag change.

Scenario 1 is a show-stopper for us.  It is possible to have the DiffEngine identify the changed href and the changed title in this scenario?

Thanks,
Trevor.


Ianko
Telerik team
 answered on 29 Jan 2015
2 answers
217 views
Hi ,

I am using Inline template to insert data. There are two command button which is Insert and Update.  To insert appointment, I am trying to call  Insert Appointment method inside RadScheduler1_AppointmentCommand. My code is as below.

Appointment apptForInsert = e.Container.Appointment;
RadScheduler1.InsertAppointment(apptForInsert);
RadScheduler1.Rebind();

By right, it should go to RadScheduler1_AppointmentInsert() method. But it didn't and the inline template form also not closed after all the events fired. Please help me with this issue. 

And there is also another problem I would like to ask. Is there any way to call RadScheduler1_AppointmentCommand from the javascript? I know I can call insertAppointment using javascript. But I am looking for a way to call AppointmentCommand.



Thank you.

Best regards,
Ei Wai

Ei Wai
Top achievements
Rank 1
 answered on 29 Jan 2015
4 answers
870 views
I'm trying to make my RadTextBox labels appear over the input box instead of to the left. Is there any native way to do this? I tried giving the CSS label a display:block, but this didn't work. After looking at the code, I see the label is put in a table cell next to the input box. Is there any property I'm missing that handles this, or is the only way is not to use a label and put them in a table row manually?
Ashley
Top achievements
Rank 1
 answered on 29 Jan 2015
2 answers
674 views
Hi,

I am transitioning an application from Infragistics to Radgrid.  I have a pretty simple grid.  I need to make one of the columns into a hyperlink.  I can't quite figure it out.  For the UltraWebGrid I used this (using VB.net):

UltraWebGrid3.Columns(0).Type = ColumnType.HyperLink

What would the correct syntax be for RadGrid?  I thought it would be something like this:

RadGrid3.MasterTableView.GetColumn("Request ID").ColumnType = gridhyperlink

But that doesn't work.

Thanks in advance for your help.

Julie
Julie
Top achievements
Rank 1
 answered on 28 Jan 2015
1 answer
134 views
I'm looking for a way to change the width of each RadWizardStep button. In the attached screenshot, each button expands evenly based on the parents width. I want to be able to shrink some buttons and widen others. As of yet, I can't find any way to do this.

Thanks,
Jeremy
Boyan Dimitrov
Telerik team
 answered on 28 Jan 2015
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?