How to use recurring events in custom form?

Hi guys,

I neet to know how can I use my custom recurring event block in my custom form.

Thanks!!

You can place any custom sections in the scheduler’s lightbox, there is no limitiation.
If you want to use custom recurring section with built-in recurring functionality of the scheduler - it is possible as well, but a bit tricky, as your custom form section will need to modify not only rec_type, but event_length and end_date of event as well.

Basically you can provide any GUI and in getValue method of form section modify above mentioned fields in necessary way.

rec_type - type of recurrency
event_length - length of event in seconds
end_date - end of last event occurence

Hi Stanislav,

Thanks by you replay, but I need to know the method to write a recurring event in DB. I mean, I want to put in the custom form my own section for recurring:

Monday, Tuesday … recurring number, etc and with this data I want to call a method to save in db. Is that possible?

Thanks again!!!

If you want to have a single record in DB which will be shown in scheduler as a set of events - you need to use above mentioned fields, and they will be automatically saved by scheduler

Monday, Tuesday … recurring number
You can have such ui and convert it to valid rec_type, end_date, event_length values, which will be saved in db

If you want to save just some custom data - you can assign custom property to the event object

scheduler.getEvent(id).some = value;

all such properties will be sent to the server side, where they can be saved or processed in some other way.

Stanislav,

Take a look at:
http://scheduler-net.com/docs/recurring_events.html
at the bottom of the page is the format for how the scheduler stores recurring events.

So if I understand what you are trying to accomplish correctly what you need to do is server side extract the values from your custom control(s) and form a rec_type string that is understandable by the scheduler. I guess you could do it client-side as well and just pass a rec_type value back but that seems kinda a messy.

Keep in mind you will also have to decode the string and set the values when you want to edit the event

It is something I was looking at doing myself but ultimately I found that just using the lightbox I could achieve what I needed.