Hello,
I just started using your scheduler and cant get through this issue. I bound my scheduler with a custom webservice which send me an array of "tasks". Thing is, these "tasks" have many custom attributes that i'd like to be able to display/edit. So i modified the MyAppointmentInfo class with my own needs as follow :
class MyAppointmentInfo { private int _id; private string _scode; private string _subject; private DateTime _start; private DateTime _end; private string _recurrenceRule; private string _recurrenceParentId; private string _reminder; private int? _userID; private int? _ressourceid; private int _backcolor; private string _description; private double _dtlength; private int _itimeslotbegin; private int _itimeslotend; private int _ifrozen; private double _dtvaliditybegin; private double _dtvalidityend; private double _dtrealbegin; private double _dtrealend; private int _itype; private int _isubtype; private int _istatus; private int _iresid; private string _sresname; private int _igroid; private int _isiteid; private int _iurgency; private int _iresfixed; private int _ialarm; private int _icolor; private int _iprofilsending; private string _saddress; private string _saddress2; private string _szipcode; private string _scity; private string _scountry; private double _dlati; private double _dlongi; private int _iradius; private int _igeoquality; private double _dkmbefore; private double _dttimebefore; private string _sspecialities; private double _dquantity; private int _tag; private string _smotifdeletion; private int _iuseridcreation; private double _dtusercreation; private int _iuseridlastchange; private double _dtuseridlastchange;I then have a getter/setter for each of these properties. I do not display all of these properties on the advanced form only some of those but all these datas will be used later.
So i tried to create custom attributes for the properties i wanted to display/edit in the advanced form. I did this operation using :
CustomAttributeNames="sAddress,sAddress2,sZipCode,sCity,sCountry"Even if i set EnableCustomAttributeEditing to true, no control is created in my advanced form. So i created it using (one for each of the properties above) :
<telerik:RadTextBox runat="server" ID="sAddress2" TextMode="SingleLine" Columns="50" LabelCssClass="rfbLabel" Rows="5" Width="80%" Label="Adresse 2" Text='<%# Eval("sAddress2")%>' RenderMode="Lightweight" />This way, when i get appointments from my webservice, these are displayed correctly on my scheduler and when clicked, displays the datas i want (including the custom attributes) in the advanced form.
But when i create a new appointment, i cant find any of these attributes in my e.appointment object when AppointmentInsert is triggered. The attribute count is 0.
Here is my RadScheduler1_AppointmentInsert code :
protected void RadScheduler1_AppointmentInsert(object sender, SchedulerCancelEventArgs e) { // I create a "task" from the e.Appointment object // before sending it to my WebService WS_Task.TRMSTaskData newTask = GetTaskFromAppointment(e.Appointment); //Send newTask to my WebService } private WS_Task.TRMSTaskData GetTaskFromAppointment(Appointment a) { // create an object "task" from an "Appointment" WS_Task.IRMSTaskservice ws = new WS_Task.IRMSTaskservice(); WS_Task.TRMSSession se = new WS_Task.TRMSSession(); se.UserId = 71; se.SessionId = 1; WS_Task.TRMSTaskData newTask = ws.GetNewTask(se); newTask.sName = a.Subject; newTask.id = Convert.ToInt32(a.ID); newTask.sDescr = a.Description; newTask.dtBegin = (a.Start).ToOADate(); newTask.dtEnd = (a.End).ToOADate(); newTask.dtLength = newTask.dtEnd - newTask.dtBegin; newTask.sResName = a.Resources.GetResourceByType("Ressource").Text; newTask.iResId = Convert.ToInt32(a.Resources.GetResourceByType("Ressource").Key); newTask.iGroId = GetResourceFromID(newTask.iResId).iGroupId; newTask.iUrgency = 0; newTask.iResFixed = 0; newTask.iAlarm = 0; //Here i cant find a way to get the address field content //newTask.sAddress = ??? return newTask; }I followed the instructions from this example : http://docs.telerik.com/devtools/aspnet-ajax/controls/scheduler/design-time/custom-resources-and-attributes but cant get this to work...
Let me know if you need any more details and thank you for your time
