This is a migrated thread and some comments may be shown as answers.

Line Break in appointment description Textarea

1 Answer 331 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Edward
Top achievements
Rank 1
Edward asked on 03 Aug 2011, 11:47 PM
I'm trying to concatenate strings (table fields) via SQL SELECT statement and use the values in the

DataDescriptionField

 

of RadSchduler (TEXTAREA).  However, I want to create line breaks between the field values.

SELECT 'Field 1: ' + field1 + ' \r\n ' + 'Field 2: ' +  field2 AS ConcatString
FROM Table1

I want the appointment description (textarea) to display...

Field 1:  Field1 Value
Field 2:  Field2 Value

What do I use to create this?  The "\r\n" didn't work.  It displays as (literal) string.  

I am trying to populate the Description textarea on an appointment using Telerik's RadScheduler.

<telerik:RadScheduler runat="server" ID="RadScheduler1" Width="1000px" Height="750px" SelectedDate="2011-08-01"
DayStartTime="00:00:00" DayEndTime="23:59:59" TimeZoneOffset="00:00:00" DataSourceID="SurgeryDataSource2"
DataKeyField="surID" DataDescriptionField="ConcatString" DataSubjectField="specialtyType" DataStartField="start_date" DataEndField="end_date">

Thanks.

Edward

 

1 Answer, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 04 Aug 2011, 12:49 PM
Hello Edward,

You can delimit your field values for example with '-'. Then you can try the following:
protected void RadScheduler1_AppointmentDataBound(object sender, SchedulerEventArgs e)
   {
       e.Appointment.Description = e.Appointment.Description.Replace("-", "\r\n");
   }

This worked as expected at my end, but please let me know if you still experience problems.

Regards,
Peter
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Scheduler
Asked by
Edward
Top achievements
Rank 1
Answers by
Peter
Telerik team
Share this question
or