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

Hi!

I wanted to modify style of RadCombo on server side, something like this:

01.protected void SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
02.    {
03.        var radCombo = sender as RadComboBox;
04.        var parent = radCombo.Parent;
05. 
06.       // cuted...
07. 
08.        int constLeft = 130;
09.        int avgTokenWidth = 73;
10.        int computed = constLeft + (avgTokenWidth * autocomplete.Entries.Count);
11.        radCombo.Style["Left"] = computed.ToString() + " px ! important";
12.    }

 

But it doesn't do anything. How to push these change to the client?

 

Eyup
Telerik team
 answered on 11 Apr 2016
1 answer
94 views

I am trying to get inline popup working but for some resson its displaying nothing no editable fields for the user the insert and cancel are showing fine. I have made sure to have ajax manager and a ajax loader as per demo

 

01.<telerik:RadAjaxManager ID="RadAjaxManager2" runat="server">
02.       <AjaxSettings>
03.           <telerik:AjaxSetting AjaxControlID="rpNotes">
04.               <UpdatedControls>
05.                   <telerik:AjaxUpdatedControl ControlID="rpNotes" LoadingPanelID="RadAjaxLoadingPanel1" />
06.               </UpdatedControls>
07.           </telerik:AjaxSetting>
08.       </AjaxSettings>
09.   </telerik:RadAjaxManager>
10.                           <telerik:RadAjaxPanel ID="rpNotes" runat="server">
11.                                 <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" />
12.                               <telerik:RadGrid ID="rgNotes" runat="server" GroupPanelPosition="Top" Skin="Bootstrap">
13.                                   <GroupingSettings CollapseAllTooltip="Collapse all groups"></GroupingSettings>
14.                                   <MasterTableView NoDetailRecordsText="No notes for this Appointment" AutoGenerateColumns="False" CommandItemDisplay="Top" CommandItemSettings-AddNewRecordText="Add Notes" AllowAutomaticInserts="true" EditMode="InPlace">
15.                                       <Columns>
16.                                             <telerik:GridEditCommandColumn UniqueName="EditCommandColumn">
17.                   </telerik:GridEditCommandColumn>
18.                                           <telerik:GridBoundColumn DataField="Subject" FilterControlAltText="Filter Subject column" HeaderText="subject" ReadOnly="True" SortExpression="Subject" UniqueName="Subject">
19.                                           </telerik:GridBoundColumn>
20.                                       </Columns>
21.                                   </MasterTableView>
22.                               </telerik:RadGrid>
23.                           </telerik:RadAjaxPanel>
24.                           <div></div>
25.                       </div>
26.                       <br />

I am filling my rad grid using dal access which is the following routine.

 

01./// <summary>
02./// Gets the allnotes by appointment.
03./// </summary>
04./// <param name="id">The identifier.</param>
05./// <returns></returns>
06.public List<tblApertureNetNote> getNotesByAppointment(int id)
07.{
08.    try
09.    {
10.        var _notes = apertureNetEntities.tblApertureNetNotes.Where(f => f.isDeleted == false && f.appointment_id == id).OrderByDescending(o => o.authCreatedDate).ToList();
11.        return _notes.AsQueryable().ToList();
12.    }
13.    catch (Exception ex)
14. 
15.    {
16.        string inner = string.Empty;
17.        if (ex.InnerException != null)
18.        {
19.            inner = ex.InnerException.ToString();
20.        }
21.        logger.Error("Error in IQueryable function getNotesByAppointment " + ex.ToString() + " " + inner);
22.        return null;
23.    }
24.}

Eyup
Telerik team
 answered on 11 Apr 2016
1 answer
96 views

Hi,

I am trying to use the Rad Searchbox as in example: http://demos.telerik.com/aspnet-ajax/searchbox/examples/overview/defaultcs.aspx

I have added the similar code, but the rad search box is throwing error as "Unknown element".

How to use the Rad Searchbox?

Thanks

Veselin Tsvetanov
Telerik team
 answered on 11 Apr 2016
5 answers
326 views

Hi,

I am using the scheduler control for a project, and I am quite new to it, your guidance on below 3 problems would be very helpful.

I have a list of free time, and time booked for appointment etc. Now based on this the remaining timeslots should be disabled. 
i.e. for example if for today I have my time available from say 9:00 AM to 10:00AM then an appointment from 10:00AM to 12:AM and then a available time from 12:PM to 3:00PM . except for these time the remaining timeslots should be disabled. How can I achieve this.

I am loading the appointment from the server side, hence using the TimeSlotCreated event I was not able to change the timeslots.

Also if you can help me on how to add a tooltip to the available timeslots(in the above example 9:00AM to 10:00AM, I have to show a tool tip as say "available from 9:00AM - 10:00AM".

 

Third how can I clear a scheduler, say today I have data in scheduler horizontally 3 users in header and each having some appointment, when I move to next day if there are no users and no appointment, I want to clear the scheduler so that the old data is removed. I Tried to clear using below code, but still the see that the header and appointment persist.

DiarySchedule.ResourceTypes.Clear();
Appointments.Clear();
DiarySchedule.DataKeyField = "ID";
DiarySchedule.DataStartField = "Start";
DiarySchedule.DataEndField = "End";
DiarySchedule.DataSubjectField = "Subject";
DiarySchedule.DataDescriptionField = "Description";
DiarySchedule.DataRecurrenceField = "RecurrenceRule";
DiarySchedule.DataRecurrenceParentKeyField = "RecurrenceParentID";
DiarySchedule.DataSource = Appointments;


Thank you

Arvind

 

Ibrahim
Top achievements
Rank 1
 answered on 11 Apr 2016
3 answers
137 views
I have the following telerik grid and need to pass the data value from the nested table into the ItemCommand so when
the user clicks the grid button the code is executed I am stuck on where to go with this

<telerik:RadGrid ID="grdRegions" runat="server" Skin="Metro" AllowCustomSorting="True"
                ShowHeader="True" PageSize="10" ShowGroupPanel="False"     OnItemCommand="grdRegions_ItemCommand"
                ShowStatusBar="True" AutoGenerateColumns="False"
                AllowSorting="True" AllowPaging="True" DataSourceID="RegionDS" Width="500px">
                <PagerStyle Mode="Slider" />
                <MasterTableView DataSourceID="RegionDS" DataKeyNames="RegionCode" AllowMultiColumnSorting="True" Width="100%">

                    <DetailTables>
                        <telerik:GridTableView runat="server" DataKeyNames="RegionCode,DealerId" DataSourceID="DealerDS" AllowFilteringByColumn="True" >
                            <ParentTableRelation>
                                <telerik:GridRelationFields DetailKeyField="RegionCode" MasterKeyField="RegionCode"  />
                            </ParentTableRelation>
                            <Columns>
                                <telerik:GridBoundColumn SortExpression="DealerId" HeaderText="Dealer" HeaderButtonType="TextButton"
                                    DataField="Dealer" UniqueName="DealerId">
                                </telerik:GridBoundColumn>

                                <telerik:GridBoundColumn SortExpression="RegionCode" HeaderText="FDAF Region Code" HeaderButtonType="TextButton"
                                    DataField="RegionCode" UniqueName="RegionCode" AllowFiltering="False">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn SortExpression="DealerId" HeaderText="DealerId" HeaderButtonType="TextButton"
                                    DataField="DealerId" UniqueName="Dealer">
                                </telerik:GridBoundColumn>
                               <telerik:GridTemplateColumn ItemStyle-Width="22px" AllowFiltering="false">
                                <ItemTemplate>
                                    <asp:ImageButton ID="EditDealer" runat="server" AlternateText="Edit Dealer" ToolTip="Edit Dealer"
                                        ImageUrl="Images/edit.png" CommandArgument='<%# DataBinder.Eval(Container,"DataItem.DealerId")%>'
                                        CommandName="EditDealer" CausesValidation="false" />
                                </ItemTemplate>
                                <ItemStyle Width="22px"></ItemStyle>
                            </telerik:GridTemplateColumn>
                            </Columns>
                        </telerik:GridTableView>
                    </DetailTables>
                    <Columns>
                        <telerik:GridBoundColumn SortExpression="RegionName" HeaderText="FDAF Region" HeaderButtonType="TextButton"
                            DataField="RegionName" UniqueName="RegionName" AllowFiltering="False">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn SortExpression="RegionCode" HeaderText="FDAF Region Code" HeaderButtonType="TextButton"
                            DataField="RegionCode" UniqueName="RegionCode">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn SortExpression="RegionDealerCount" HeaderText="Dealers In Region" HeaderButtonType="TextButton"
                            DataField="RegionDealerCount" UniqueName="RegionDealerCount" AllowFiltering="False">
                        </telerik:GridBoundColumn>
                    </Columns>
                </MasterTableView>
            </telerik:RadGrid>






                     protected void grdRegions_ItemCommand(object sender, GridCommandEventArgs e)
                        {
                            objDealerDL.DealerId = Convert.ToInt32((e.Item as GridDataItem).OwnerTableView.DataKeyValues[e.Item.ItemIndex]["DealerId"].ToString());
                            GridDataItem item = (GridDataItem)e.Item;                       
                            if (e.CommandName == "EditDealer")
                            {
                                try
                                {
                                  do work
                                }
                                catch (Exception ex)
                                {

                                }
                            }
                        }
Eyup
Telerik team
 answered on 11 Apr 2016
5 answers
303 views
When you click and open a radgrid date picker, you need to click on the date at top to get another window to open so that you can pick the button with todays date.

1.  How do you seet that button with todays date.  I went into the properties but can never find the right syntax for it to take.
2. Is there a way to put it on the datepicker at the bottom such as the Microsoft one that has it at the bottom so there is no need to pick agian to get to todays date button.
Eyup
Telerik team
 answered on 11 Apr 2016
3 answers
114 views

Hi

I am new to Telerik I am looking for working independent sample  project or web site of Scheduler - Resource Grouping (http://demos.telerik.com/aspnet-ajax/scheduler/examples/resourcegrouping/defaultcs.aspx?skin=Silk).  Where can I download such a sample?

Thanks

abahrami

Nencho
Telerik team
 answered on 11 Apr 2016
2 answers
218 views

Hi,

We are using Telerik Web UI for AJAX (version 2015.2.729.45). In grid we have data with double quotes (") and filter control is TextBox. Searching text with double quotes fails the search.

please see the attachment.

Code being used - Using the aspx standard script.

 <telerik:GridBoundColumn DataField="Name" HeaderText="Header" UniqueName="Name" FilterControlWidth="260px" AllowFiltering="true" ShowFilterIcon="false" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" />

Kindly let us know for the solution.

Thanks.

Neelesh

Eyup
Telerik team
 answered on 11 Apr 2016
1 answer
115 views
Good morning, we are refining their controls and we have a problem with RadSearchBox, this control does not support the ('Ñ') character , and when to return a result with the same shows nothing.

there is a way I can use that character?

For in Spain and Latin America it is all used
Veselin Tsvetanov
Telerik team
 answered on 11 Apr 2016
1 answer
224 views

Hello,

we have updated one of our solutions from .NET 3.5 to 4.0 with a new Telerik version. Right now we are having an critical issue we are not able to solve.

We are opening an selection form in an modal dialog. All available items are displayed in an GridView where the user can select a single item. On post back the form is handing the user selection back to the previous form. From the theory quite easy going. Right now we have recognized an ciritical issue with our post back.

On postback we are loosing the ViewState and the ControlState of the GridView. Due to this case, it will reload the data source, without the selected sort, filter and page options and returns the wrong user selection.

For example:

If we select the 3rd item on page 2, while all items are sorted alphabetically ascending, it will return the 3rd item from the datasource, without any filtering, paging, or sorting. So on postback the selected page is always 0, the sort order null... filtering null.

This strange behaviour only occurs in modal dialogs. If we do use the same kind of grid (cause it's based on a adapter pattern will complete same implementation) it will work correctly.

Grid implementation:

<telerik:RadAjaxManagerProxy  ID="AjaxManagerProxy" runat="server" >
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="PanelButtonBar">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="PanelButtonBar" LoadingPanelID="RadAjaxLoadingPanel1"/>
                <telerik:AjaxUpdatedControl ControlID="pnlMessage"/>
                <telerik:AjaxUpdatedControl ControlID="RadWindowManagerInGrid" LoadingPanelID="RadAjaxLoadingPanel1" />
            </UpdatedControls>
        </telerik:AjaxSetting>
        <telerik:AjaxSetting AjaxControlID="Grid">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="Grid" LoadingPanelID="RadAjaxLoadingPanel1"/>
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManagerProxy>

If you already know this kind of issue and fixed it, please let me know. I realy do require an idea :)

Best Regards,

Jan

 

Konstantin Dikov
Telerik team
 answered on 11 Apr 2016
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?