Populating RadScheduler using Sql backend

6 posts, 0 answers
  1. RJ
    RJ avatar
    386 posts
    Member since:
    Oct 2006

    Posted 07 Sep 2009 Link to this post

    Hi, Its my first time to use radscheduler so I've been checking out sample but seems like I cant find any that uses sql database as its datasource. I already have a schedule creator using other pages, this is like subject or course scheduling. Data is already existing on the database which has data range, time range, subject, teacher, # of students, etc. . What I wanted is to make radscheduler as view only. but if you click on a schedule it will popup the details. Also I want to disable/hide the delete when you rollover the schedule.

    If there are samples or documentation that would help start up my project it would be highly appreciated.

    Im using ASP.NET AJAX Q1 2009

    Thanks in advance,

    Rj
  2. Axe
    Axe avatar
    88 posts
    Member since:
    Feb 2007

    Posted 07 Sep 2009 Link to this post

    Have a look at this page: http://www.telerik.com/help/aspnet-ajax/schedule_databindingusingthedatasourceproperty.html for databinding using the DataSource property. Scroll down to point 6 for the Page_Load event handler.
    Once in the help section of RadScheduler have a look for the other things you wanted. I can't remember what the property for making read-only is. You can attach client event to appointment click I think which you caould use a RadWindow or something to show details. There is probably other ways. Someone else will probably give suggestions.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. RJ
    RJ avatar
    386 posts
    Member since:
    Oct 2006

    Posted 09 Sep 2009 Link to this post

    Are all classes should really be created and needed when using Sql database as datasource? I did try some template but they dont  have that class used and its not that complicated. but then again they just using Session datasource. Is there any other easier way on accomplishing my task? Anyways will try to use this code and will give you feedback. Thanks.
  5. Axe
    Axe avatar
    88 posts
    Member since:
    Feb 2007

    Posted 10 Sep 2009 Link to this post

    Although I haven't tried it, I think you can pass it any datasource - objects, datatable, dataset etc.
    Will try when I get home and let you know. That page I linked to explained one way to do it.
    Just pass any datasource to it and then if the database fields are named different than the defaults you can map the names to your datasource.
  6. chris
    chris avatar
    11 posts
    Member since:
    Sep 2007

    Posted 11 Sep 2009 Link to this post

    Should be a sinch really -

    all you need is a sql table with a minimum of the follow fields
    *  id  ( an int field set as primary key indexed for incrementing values)
    *  Sched_Start (as datetime)
    *  Sched_End (as datetime)
    *  Title (I use as varchar(100 - this is used as text for appointments)
    *  RecurringInfo (I use as varchar(1000)
    *  Parent_Id (again an integer)

    Drop the RadScheduler onto your page in design mode
    Choose your datasource - if not set up then create a new one and lnk to your table above
            (note when creating your data source from scratch you need to choose the advance options to 
                generate the Update.Insert and Delete queries)

        set data field as a key = id
        set data field as start = Sched_Start
        set data field as end = Sched_End
        set data field as subject = Title
        set data field as recurrence storage = RecurringInfo
        set data field as recurrance parent key = ParentId 

    I currently use three tables to control my diary
     1st a table of EventTypes detailing event type id and type and description
     2nd a table listing each event with details including event type id, various location/adress lines, description,contact personnel etc
    and 3rdly  a table called Diary wihch pulls into the radscheduler which allows the scheduling of the events with fields set out as above

    EventsType table has foregein key to Events table
    Events table has a foreign key to Diary table

    couple of triggers update from the events table to and from the diary - this allows inserts and update in both

    noting to it from there on - just tidying up presentation and including resources should you wish



  7. RJ
    RJ avatar
    386 posts
    Member since:
    Oct 2006

    Posted 11 Sep 2009 Link to this post

    Thanks for the detailed feedback I was able to get started. But then again how can I disable or hide the delete button when I rollover a schedule? how can I also disable the dates not to open window to enter schedule. Only those with schedule can be viewed. lastly how can I remove save cancel when they view created schedule... Thanks again.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017