Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
98 views
So so so f*cking frustrated. New to ASP.NET and I can't get my head around the simplest concepts.

I have basic 'required' validators on fields - but when is the validation summary/error messages produced?

For example check this link (which is extremely similar to what I'm doing): http://www.aspxcode.net/free-asp-net-validation-source-code.aspx?Topics=How%20to%20Use%20ValidationSummary

When the button is clicked is when the validation "happens." But how? The code behind the button doesn't handle this!? 

I know this is not yet telerik-specific but once this question is answered I have another question regarding telerik-control specific validation (which may be solved depending on your explanation and my grasp of it).

Thanks a lot, any help and basic understanding here will be very much appreciated,

Dan
Veronica
Telerik team
 answered on 10 Apr 2011
3 answers
206 views
1).  Animations are available if I integrate this with JQuery?  Is there a walkthrough for how to install/implement this feature?

2).  Are there any good in-depth articles on Resources/Resource Types, what they are conceptually, how/why they're used, what scenarios are they used for.

3).  I've read through some articles on what the Scheduler can do, but just haven't found where to look to find how to do everything, and why, maybe an article explaining the architecture of the control and how to work with it in general.

4).  How would I customize the input of a new appointment.  For instance, I would want the user to be able to select from a drop down list of attendees from my database, he would be able to choose an attendee from a list.  Also, would be able to choose from another drop down list the reason for the appointment.  There may be some other data points as well, such as additional notes & description, in addition to the title and all other datapoints that come default with an appointment.  How would I go about implementing this functionality?  Do I add combo boxes to the insertTemplate, or the AdvancedInsertTemplate?  Are there any walkthroughs or demos for customizing this part?

5).  For instance, I see that there's an Appointment business object that represents each entry on the grid.  But this BO is fixed and doesn't have things like an ID for the user attending and an ID for the appointment reason (or whatever custom data we want to track). When we create a custom appointment with our custom template and the user chooses from these two drop-downs and the RadScheduler_AppointmentCreated event is fired it delivers an AppointmentCreatedEventArgs e that has an e.Appointment object that wouldn't tell us anything about these extra datapoints.  How do we get around this?

Thank you to anyone who is able to steer me in the right direction for any of these questions.
Veronica
Telerik team
 answered on 10 Apr 2011
1 answer
109 views
Hi,

I was hoping to to change a GridBoundColumn row value to be a LinkButton when the Edit button is clicked.

Here's the column:
<rad:GridBoundColumn DataField="FileName"  UniqueName="NameColumn" />

Then I'm guessing the change needs to take place when the EditCommand event is raised
void ListGrid_EditCommand(object source, GridCommandEventArgs e)

So how would I find the "NameColumn" and change its value to a LinkButton on Edit?

Also, is it possible to get the Row DataItem on the EditCommand event? I wasn't able to find a way to do this. 
Jayesh Goyani
Top achievements
Rank 2
 answered on 09 Apr 2011
4 answers
129 views
Hi,

I'm evaluating the RadChart control and I have some questions about scale breaks:

- Is it possible to set the height of the different segments? For example: I'm using four segments. When I display the four segments the area for each segment is the same (height for each segment is about total height/4), but when I display three or two segments the height of one segment is bigger than the rest. I would like the height segments to be the same in all the cases.
(I've attached some screenshots for this example).

- Is it possible to set the Y-Axis labels for each segment with a different appearance (for example text color)?

- Is it possible to set a different background color for each segment?

Thanks in advance.
John.
john
Top achievements
Rank 1
 answered on 09 Apr 2011
4 answers
139 views
Hello, I'm using a gridtemplatecolumn to find the differnce betwean two date columns. I then want to take the average of that column which I do through code. It works fine until a filter is applied on any column. I've have the code shown below. Any suggestions?

<

 

 

telerik:GridDateTimeColumn UniqueName="DatePlaced" DataField="DatePlaced" HeaderText="Date Placed"

 

 

 

 

HeaderStyle-Width="160px" DataFormatString="{0:d}">

 

 

 

</telerik:GridDateTimeColumn>

 

 

 

<telerik:GridDateTimeColumn UniqueName="DateShipped" DataField="DateShipped" HeaderText="Date Shipped"

 

 

 

 

HeaderStyle-Width="160px" DataFormatString="{0:d}">

 

 

 

</telerik:GridDateTimeColumn>

 

 

 

<telerik:GridTemplateColumn DataField="DaysToShip" HeaderText="Days To Ship" >

 

 

 

<ItemTemplate>

 

 

 

<asp:Label ID="lblDaysToShip" runat="server"></asp:Label>

 

 

 

</ItemTemplate>

 

 

 

<FooterTemplate>

 

 

 

<asp:Label ID="lblDaysToShipFooter" runat="server"></asp:Label>

 

 

 

</FooterTemplate>

 

 

 

</telerik:GridTemplateColumn>


C# code

 

 

double

 

 

totalRows, countRows;

 

 

protected

 

 

 

void TrackingGrid_ItemDataBound(object source, GridItemEventArgs e)

 

 

{

 

 

 

 

if (e.Item is GridDataItem)

 

 

{

 

 

 

 

GridDataItem item = (GridDataItem)e.Item;

 

 

(item.FindControl(

 

 

"lblDaysToShip") as Label).Text = DateTime.Parse(item["DateShipped"].Text).Subtract(DateTime.Parse(item["DatePlaced"].Text)).Days.ToString();

 

 

totalRows +=

 

 

Double.Parse((item.FindControl("lblDaysToShip") as Label).Text);

 

 

countRows += 1;

 

}

 

 

 

 

if (e.Item is GridFooterItem)

 

 

{

 

 

 

 

GridFooterItem footerItem = e.Item as GridFooterItem;

 

 

(footerItem.FindControl(

 

 

"lblDaysToShipFooter") as Label).Text = "Average days: " + (totalRows / countRows).ToString("N2");

 

 

}

 

}


Thanks for your help
Greg

Greg
Top achievements
Rank 1
 answered on 08 Apr 2011
3 answers
438 views
I have seen plenty of forum thread but none of them, even the current ones, supply a resolution to exporting to Excel 2007 using the "XLSX" extension. 

I am using the Ajax Q1 release for 2011 and ASP.Net 4.0 assemblies.  What do I need to change here to export a grid to an xlsx file??

RadGrid1.MasterTableView.ExportToExcel()

I have tried added the following to the RadGrid export settings before call the export method but get a file format or extension is invalid exception:

RadGrid1.ExportSettings.Excel.FileExtension = "xlsx"

Daniel
Telerik team
 answered on 08 Apr 2011
6 answers
161 views
Hi,

I'am trying now to focus a particular textbox when the user click the edit button.

I found this very helpful thread on your support base, but it doesn't work (javascript approach) if my grid is ajaxified.

What is the solution ?

Thanks in advance.
Sean
Top achievements
Rank 1
 answered on 08 Apr 2011
1 answer
35 views
Hi

We are currently using ASP.NET ImageMap to display dynamically generated images, that have hotspots, in our web app, which also uses Telerik ASP.NET AJAX controls extensively.

ASP.NET ImageMap control requires that the image file be a physical file sitting in our web app folders and you specify the URL to that file.  This requires that we need to create temp files and manage them - deleting etc.

To avoid creating those 'physical files' and use in-memroy images, I realize we can cache the image and write a HTTP handler that can stream the image from that cache. 

Before I sit down and write my own handler...

I was wondering if we can pile onto the Telerik.Web.UI.WebResource that does similar work for Telerik's resources.  Does it expose any functionality where we can tell it say - here is the image stream, that is in this cache, serve this image when the request is made in certain fashion for the image resource?

Any pointers appreciated.

Regards
Athadu
Athadu
Top achievements
Rank 1
 answered on 08 Apr 2011
2 answers
87 views
Hi all,

I have a radgrid with two template columns i use to show the data instead of database ids, but when i run it ,it only shows the headers of the template columns not the data. What could be the reason?

Regards,
Hamda
HL
Top achievements
Rank 1
 answered on 08 Apr 2011
2 answers
199 views
Hi,

I have a Radgrid and using a telerik:GridBinaryImageColumn.
I've hooked up the Radgrid to a SqlDataSource allowing Automatic INSERTS/UPDATES/DELETES.
My table has a column "Logo" which is of "image" type and allows nulls.

If I create a record and upload an image everything is fine. But when I click update and update a different field for example "name", then the image gets deleted because I never selected one! So every time I update I have to select an image, and I'm sure you can see that that is a problem.

Any help would be great thanks.
Darren
Can
Top achievements
Rank 1
 answered on 08 Apr 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?