Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
168 views
Hi there,

I have gone through hundreds of pages trying to solve what seems like a simple problem.

status:
I have successfully put a treeview in a combobox, clicking of node populates combobox etc...

now for the problem.
I need to set the  text value of the combobox from a data source, I am successfully able to find the node in the treeview and select the node. hoping that would set my text value , unfortunately it didnt.

in the codebehind page I have even attempted to call a client function to set the text of the combo box.... still failed !!!


Does anyone know how to set the text value of the combobox when  the selected node of the embeded treeview  is changed at serverside?

many thanks

Mark


Simon
Telerik team
 answered on 09 Apr 2010
1 answer
129 views
I would like to have the RadProgressArea visible on page load.  The RadProgressArea should just be visible and defaulted.  Upon uploading a file, I would like to update the RadProgressArea.

Can someone please assist?

Thanks!
Genady Sergeev
Telerik team
 answered on 09 Apr 2010
2 answers
101 views
I'm trying to use a RadGrid control with a manual datasource.  Tthat is, I do not have a DataSource control on the page, instead I use the NeedDataSource event to wire it up to a DataTable that is retrieved through some custom code.  The DataTable is is stashed in ViewState the first time and then retrieved on this event as needed.

Now, it's pretty straightforward to add a column to the RadGrid that adds an Edit link that puts the row into edit mode and that action column now has Update/Cancel links.  I can also see how easy it ease to add a AddNewRecords attribute to the CommandItemsSettings element.

And of course, wire up actions to the ItemCommand event or the individual UpdateCommand, DeleteCommand, etc. events.  So far so good.  What took quite a bit of digging into example code to find was the way to retrieve a reference to the row that was inserted/edited/deleted.  There seems to be a variety of ways, but the one I see most in example code is:

GridEditableItem eeditItem = e.Item as GridEditableItem;  
string str = editItem.OwnerTableView.DataKeyValues[editItem.ItemIndex]["EntityID"].ToString(); 

I have to tell you... I would never have figured this out w/out digging into existing code samples!  This does not seem intuitive at all, and so far, I haven't really come across any narratives or field notes or just plain english description about this.  Specifically,  I'm not sure I understand the OwnerTableView bit of it.

From the example above, why can't I just use the editItem.ItemIndex value to tell me which row in my datasource I'm on?  Then get that just index into it using something like 

DataTable dt = GridSource;  
GridEditableItem eeditItem = e.Item as GridEditableItem;  
DataRow myRow = dt.Rows[editItem.ItemIndex]; 

 I've also seen some sample code that does something like:

 
GridDataItem item = (GridDataItem)e.Item;    
string str = item["CompanyName"].Text;   

To me, both of the above examples are fairly easy to understand.

Any guidance (with some explanation) on what the various methods are would be appreciated.  Any info on the object chain that requires this OwnerTableView reference would also be greatly appreciated.  I realize I can just copy/paste the code and go on, but I'd really like to *understand* what I'm doing here!

Thanks.

Iana Tsolova
Telerik team
 answered on 09 Apr 2010
4 answers
73 views
hi,

I have a question but first a statement of concern.

There are claims that all feature of the RadGrid are WCAG 1.0 A compliant.  However, the first thing I would like to raise as there have been forum posts that caveat this by saying you can't have Static headers and enableScrolling = true.  Now admittedly, the forum post that caveats this is quite old but I suspect this is still the case.  I am concerned that the claim that all features are compliant is entirely misleading.  Now on to my question:

WCAG 1.0 Checkpoint 6.3 states "Ensure that pages are usable when scripts, applets, or other programmatic objects are turned off or not supported. If this is not possible, provide equivalent information on an alternative accessible page.".  My question is how is this supported by the RadGrid if paging is on?  what also needs to be set to ensure that javascript postbacks are not required?

Thanks
Dimo
Telerik team
 answered on 09 Apr 2010
1 answer
194 views
Hi ,
 I have a RAD grid. The calender exted is attached to a textbox. It forks fine in the non-inline edit mode. However it's display is jaggered in the inline edit. Any suggestions?
<EditItemTemplate> 
<asp:TextBox MaxLength="30" skin="Vista" Text='<%# Bind("Dt1")%>' ID="txtDate1" runat="server"></asp:TextBox> 
<asp:Image ID="imgCalendarDt2" runat="server" ImageUrl="~/images/Calendar_scheduleHS.png" 
onmouseover="this.style.cursor='hand'" ToolTip="Click to show calendar" /> 
<ajax:CalendarExtender  
ID="CalendarExtender2" runat="server" TargetControlID="txtDate1" PopupButtonID="imgCalendarDt2" 
PopupPosition="TopLeft" CssClass="yui"/> 
<asp:Label ID="lblDtFormat2" runat="server" Font-Italic="true" Font-Names="verdana" 
Font-Size="7" Text="Format: mm/dd/yyyy" /> 
</EditItemTemplate> 
All i am changeig is adding / commenting this code on the pageload

grd.MasterTableView.EditMode =

GridEditMode.InPlace;

 

Bruno
Top achievements
Rank 2
 answered on 09 Apr 2010
1 answer
95 views
Hi

Usually we include the dlls in bin directory of our application.But other than that how can we include the dll??

This method is needed for me to upload my files to the remote system as they dont take into account the 'bin' directory.

Thanks in advance,
kavin
Sebastian
Telerik team
 answered on 09 Apr 2010
2 answers
460 views
Hello,

My company is considering using your Scheduler component in our application, but we have some reservations due some performance issues we've run into with large datasets. When loading lots of appointments (175 users over a 1-month period, about 250 appts.), the performance is not very good (10-second response time, ~1MB response to postback), and this is over an intranet. We're going to be deploying whichever scheduler we choose in an internet application, where it is critical that the performance be top-notch, so if we can't get it to perform quickly over our intranet, we won't be able to use it, unfortunately, as much as we like the looks and features of the Telerik scheduler. I've tried out a few other schedulers, and the response time for the same dataset is much faster, so I know it's not the size of the data itself causing the slowdown. As best I can I tell, the slowdown seems to be due to the rendering stage. Is there something we can do to reduce the size of the response returned to the postback and to speed up the rendering of the appointments? Also, it's making 20+ requests to WebResource.axd for scripts -- is there a way to tell it to combine, minify, and gzip these scripts into a single request so that it doesn't hamper performance?

Thanks,

Daniel
T. Tsonev
Telerik team
 answered on 09 Apr 2010
1 answer
100 views
How can i start the plot the graph with out leaving any space between axis and plot area.

Attaching a file for helping you understand

<

 

telerik:RadChart ID="RadChart1" runat="server" Skin="BabyBlue" DefaultType="Line">

 

 

<Series>

 

 

<telerik:ChartSeries Name="Test" Type="Line">

 

 

<Items>

 

 

<telerik:ChartSeriesItem XValue="1" YValue="2"></telerik:ChartSeriesItem>

 

 

<telerik:ChartSeriesItem XValue="3" YValue="4"></telerik:ChartSeriesItem>

 

 

<telerik:ChartSeriesItem XValue="4" YValue="6"></telerik:ChartSeriesItem>

 

 

<telerik:ChartSeriesItem XValue="7" YValue="7"></telerik:ChartSeriesItem>

 

 

</Items>

 

 

</telerik:ChartSeries>

 

 

 

</Series>

 

 

<PlotArea>

 

 

<XAxis IsZeroBased="false" AutoScale="true">

 

 

</XAxis>

 

 

<YAxis IsZeroBased="false" AutoScale="true">

 

 

</YAxis>

 

 

</PlotArea>

 

 

</telerik:RadChart>

Hope you guys can understand from attached image what i am trying to achive..

 

Giuseppe
Telerik team
 answered on 09 Apr 2010
9 answers
819 views
Hi there,

Can you please help me on how to disable the add new record button in grid when there is at least one record displayed?
The add new record should appear only in the event of the datasource not returning any records.
Moreover if the button is clicked i want some fields to be auto completed (linked) based on fields appearing in a formview in the same page.
 
Thanxs!


Sebastian
Telerik team
 answered on 09 Apr 2010
3 answers
201 views
Hi,

I ran into a few issues while doing web service binding (custom provider) and using a custom advanced form.  I figured ways around it/fixes and wanted to know if I'm going about this correctly or is there better ways (the documentation for the scheduler client side stuff is not that great):


1)  I have a recurring appointment in the scheduler.  When I click the "master appointment" and select "edit series" it loads up fine BUT if I click an "Occurrence" of the series and select "edit series" the time slots are populated with the dates/times of the current occurrence (not master) and the recurrence panel does not load up correctly (this can get very annoying because I'm building an employee timesheet where an occurrence can repeat for 1+ years).

The issue here is that the "schedulerFormCreated" client side function tries to load the data for the current occurrence which does not have the recurrence rules - I am selecting "edit series" not "current appointment" so it should be loading the master.

The way I solved this:

                 
                    if (!scheduler.get_webServiceSettings().get_isEmpty()) { 
                        // Populate the form with the appointment data 
                        var apt = eventArgs.get_appointment(); 
 
                        var isInsert = mode == Telerik.Web.UI.SchedulerFormMode.AdvancedInsert; 
                        var editSeries = eventArgs.get_editingRecurringSeries(); 
 
                        if (editSeries && apt.get_recurrenceState() == 2) { 
                            var ParentID = apt.get_recurrenceParentID(); 
                            apt = scheduler.get_appointments().findByID(ParentID); 
                        } 
 
                        advancedTemplate.populate(apt, isInsert, editSeries); 
                    } 

I added the if statement to check if it the appointment is an Occurrence; if so get its parent and load the data for the parent in the form. 

Also the recurrence panel loads if you select the master appointment and select "edit current appointment" (not series) - it should stay closed since we're only editing the current appointment.  A line or two in the populate method in AdvancedForm.js fixed this.

2)  Cannot delete a single occurrence of a recurring appointment (building a employee timesheet system - for example have to delete a single instance if somebody is out sick a certain day).

   My web service method (this is from the tutorial):

        [WebMethod(EnableSession = true)] 
        public IEnumerable<AppointmentData> DeleteAppointment(SchedulerInfo schedulerInfo, AppointmentData appointmentData, bool deleteSeries) { 
                return Controller.DeleteAppointment(schedulerInfo, appointmentData, deleteSeries); 
        } 
 

Custom Provider:

        public override void Delete(RadScheduler owner, Appointment appointmentToDelete) 
        { 
            if (!PersistChanges) 
            { 
                return
            } 
                Connectors.TimeLog MyLog = db.TimeLogs.Where(p => p.TimeTableID == (int)appointmentToDelete.ID).First(); 
                db.TimeLogs.DeleteOnSubmit(MyLog); 
                db.SubmitChanges(); 
        } 




The issue that happened to me here is that the web service calls the Delete method of the custom provider even if  the appointment is an occurrence and the linq statement fails because there is no database entry for an occurrence of an appointment (only for the masters and exceptions there are db entries) - to "delete" an occurrence you have to add an exception to the RecurrenceRule of the master appointment.

What I did here is modify the DeleteAppointment method:

- if delete series or master or exception do return Controller.DeleteAppointment(schedulerInfo, appointmentData, deleteSeries);

- if delete single appointment check if appointment is master if master get the RecurrenceRule (from db) if an Occurrence get the master appointment then get its RecurrenceRule (from db).  Then I used the RecurrenceRuleConverter to convert from recurrence string then add an exception for the "Start" property of the passed "appointmentData" then convert back to string, save to database, and reload  appointments.

Am I going about this the right way?  Maybe there's an easier method but I've searched the documentation/forums with no luck...
T. Tsonev
Telerik team
 answered on 09 Apr 2010
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?