Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
83 views

Are the asp.net ajax controls compatible with the mobi controls (see below link), or do they have built in features where mobi wouldn't be needed?

http://51degrees.mobi/Products/Framework/Designers/InputMethods.aspx

Genady Sergeev
Telerik team
 answered on 15 Aug 2013
1 answer
118 views
I use LinqDataSource:

<asp:LinqDataSource ID="linqDS" OnSelecting="linqDS_Selecting" runat="server" />
<telerik:RadGrid ID="gridProducts" runat="server" AllowFilteringByColumn="True" AllowPaging="True"
                  AllowSorting="True" AutoGenerateColumns="False"  AllowMultiRowSelection="false"
                  CssClass="roundBorders fixedRBPadding" PageSize="10" GridLines="None"
                 DataSourceID="linqDS" EnableAJAX="True" EnableAJAXLoadingTemplate="True">
protected void linqDS_Selecting(object sender, LinqDataSourceSelectEventArgs e)
       {
                 ...creating context...
 
                  e.Result = from productRecord in db.Products
                                 where
                                  ...
 
            
       }


I want to implement caching in grids because grids usually show only the first page and no need to make query each time.
I can easily implement caching in linqDS_Selecting method.

The problem is that i dont think about pagination in linqDS_Selecting method, grid implements it instead of me.
so i can put all data in cache (i need to save in cache only the firsts pages which can be really navigated)

I tried to figure out how to hook the event when the grid passes data about its filtering and paging to linq, but i couldnt.

Does anybody know the ways how to do it?
   
Vasil
Telerik team
 answered on 15 Aug 2013
3 answers
105 views
I have added RadStyleSheetManager to my page to combine all of the embedded CSS emitted for various Telerik controls (menu, grid, combobox, etc.) into a single request.

Here's what the control looks like in the master page:

<telerik:radstylesheetmanager runat="server" EnableStyleSheetCombine="true"></telerik:radstylesheetmanager>

In my Web.config I have these:

<system.web
    <handlers>
        <add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="false"/>
    </handlers>
</system.web>

and 

<system.webServer
    <handlers>
        <add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource"/>
    </handlers>
</system.webServer>

Unfortunately when I look at HTTP requests in Fiddle or Dev Tools I still see a bunch of individual requests for Telerik control CSS, e.g.:


/WebResource.axd?d=s5NYJBI3nRAFreTQ7udQlKpAm2DSy9JAG88FYDPYUxF9i8rYngTROVT04Kc6cQFbg0elZBZAi-9MOFyZZXrIQPY8qxU7BLpExH2B449zx7DVia8sEcNgsjtoO2898ZLA7Ieljg2&t=635017187260000000

What am I doing wrong?
Ivan Zhekov
Telerik team
 answered on 15 Aug 2013
1 answer
138 views
Hi, I have a rad grid with some custom filters (multi-select drop down boxes).  I also have some custom filters which are boolean drop down types.  When I use the regular filters and then the custom filter, it will filter by the regular filters, and then filter by the custom filter.  But if I use the custom filter first and then any of the other filters, it wipes out all of the filters.  I could fix this by not using a filter type of "Custom", but if I use the regular string filtering offered by the rad grid, it does the comparison:

     ["Column"] Like '%value%' 

when what I actually want (since it is a multi-select dropdown, whose filter expression evaluates to String1, String2, String3) is

     Value Like '%[Column]%' 

Any help is much appreciated:

Here is how I do the custom filtering:

       
protected void MarkPickListResultGrid_ItemCommand(object source, GridCommandEventArgs e)
     {
         if (e.CommandName == RadGrid.FilterCommandName)
         {
             ListResultGrid.MasterTableView.CurrentPageIndex = 0;
             string columnUniqueName = (e.CommandArgument as Pair).Second.ToString();
              
             GridFilterColumn column = ListResultGrid.MasterTableView.Columns.FindByUniqueNameSafe("Type") as GridFilterColumn;
 
             if ((e.CommandArgument as Pair).First.ToString() == "Custom")
             {
                 List<string> filters = column.CurrentFilterValue.Split(',').ToList();
                 var predicate = PredicateBuilder.False<PickListMark>();
                 foreach (string filter in filters)
                 {
                     predicate = predicate.Or(r => filter.Contains(r.MarkType.MarkTypeName));
                 }
                 ListResultGrid.MasterTableView.DataSource = PickListMark.Where(predicate.Compile()).ToList();
                 ListResultGrid.MasterTableView.Rebind();
                 return;
             }
             
              
         }
     }


Edit:  Would it be a better idea to treat them all as custom and loop through all the columns in the above function and apply all the columns to the predicate and then filter the results?  
Eyup
Telerik team
 answered on 15 Aug 2013
3 answers
130 views
Hi
I am using a RadListView to display items of three similar object types (Member, Position, Substitute), and use code-behind to show/hide fields within the templates depending on the type of the object. So far, I have view and edit working fine, using a UserControl that detects the object type,and updates the display accordingly. My problem occurs when I try to add.

I have three buttons on the form, one for adding each object type, firing different commands for each type - AddMember, AddPosition, AddSubstitute. When the command is fired, I create an empty object of the required type, and use the RadListView's ShowInsertItem method with the object parameter overload.

My question is, how can I access this object from my asp.net markup, so I can pass it through to the UserControl that defines the fields to use?

In the EditTemplate, I can simply use something like:

<scid:EditControl runat="server" ID="EditObject" Member="<%# (BaseMemberCommon)Container.DataItem %>"/>

However, in the InsertTemplate, the Container object doesn't have a DataItem property.

Can anyone help?
Thanks




Angel Petrov
Telerik team
 answered on 15 Aug 2013
3 answers
99 views
Greetings,
I am trying to implement a work schedule using rad scheduler tool.
Everything went good so far until I tried to implement drag and drop on engineer schedule.
I use onAppointmentDataBound to color daily shifts, nothing else.
and to get the information of "start and end times" as well as task id..etc, I am using onAppointmentUpdate at code behind, however I am experiencing a problem such as change in the text of appointment and change the time and color of existing tasks and tooltips of the engineer.
Notice in the screenshots, i am trying to move a task to 17:00 for the same engineer, but scheduler places the task into 15:30 while changing the daily shift (blue task) to something else
In the demos, I couldn't find any examples to specifically handle the drag and drop to avoid such problems.
Any help would be appreciated
Kind regards
Emrah
Plamen
Telerik team
 answered on 15 Aug 2013
1 answer
142 views
Greetings,
I have a problem with assigning data to schedule at code behind.
in html, i have already created a resourcetype for the schedule.

<ResourceTypes>
         <telerik:ResourceType ForeignKeyField="UserID" KeyField="UserID" TextField="fullname" Name="myResource" />
</ResourceTypes>
at the code behind, I can find the resourcetype and attach a dataset to it. however, although the grouping is done, the appointments are not shown, so I have to concatenate 2 datasets and assign them to scheduler as datasource (and this creates problems). How can I bind data to scheduler without using scheduler.datasource = dataset and scheduler.databind() mehtods ? because i want to add the second dataset as another resouce and
here is what i am using at the moment

public void BindSchedule()
       {
           DataSet ds2 = myObj.GetScheduleData(ddlGroup.SelectedValue);
 
           DataSet ds1 = myObj.EngineerDailyAssignmentGet(ddlGroup.SelectedValue);
 
           ds2.Merge(ds1);
           ResourceType t = radZeitPlan.ResourceTypes.FindByName("myResource") as ResourceType;
           t.DataSource = ds2;
            
           radScheduler.DataSource = ds1;
           radZeitPlan.DataBind();
            
           radZeitPlan.GroupBy = "myResource";
       }
Plamen
Telerik team
 answered on 15 Aug 2013
4 answers
111 views
Hi,

Looking back through the forum there was talk back in 2011 of implementing a date header template so additional data could be added into the day header area. This has been on my wish list for ages, and I'm wondering did anything ever get implemented?

David Penny
Adam
Top achievements
Rank 1
 answered on 14 Aug 2013
1 answer
203 views
how to get class name without TypeOf because this method return "Objet" ?
Carlos Javier
Top achievements
Rank 1
 answered on 14 Aug 2013
1 answer
109 views
Hi,
I am having an installation of ASP.N ET AJAX on my Visual Studio 2010, but for some reason the menu toolbox of telerik shows only other products.
I have tried uninstalling and reinstalling but it doesn't fix the problem.

help will be appreciated.

Thank you.
Rumen
Telerik team
 answered on 14 Aug 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?