[CLOSED] Help with ext:Calendar

Page 2 of 6 FirstFirst 1234 ... LastLast
  1. #11
    Hi Pablo,
    CompanyX.dayClick
    is defined in common.js file.

    You can see
    <script type="text/javascript" src="../Shared/resources/js/common.js"></script>
    within the page's <head>.

    To get common.js please download the example's source (the button is on the right at the bottom of Source window).
  2. #12
    Ok, i found the external js file in the svn.
    Just a suggestion: put an example with the code this way Vladimir told me, it's much easier to understand.
  3. #13

    more help needed...

    In the code below, why only event with ID 1002 is shown in the calendar month view (1001 only shows in day view)? Also, how to translate everything (some things get translated automatically, but others, like "Day, Week, Month" at the top don't).
    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
            CalendarPanel1.EventStore.Events.AddRange(Data.Events);
    
        }
    
        public class Data
        {
            public static EventCollection Events
            {
                get
                {
                    var now = DateTime.Now.Date;
    
                    return new EventCollection {                     
                        new Event
                        {
                            EventId = 1001,
                            CalendarId = 1,
                            Title = "Meu evento 1",
                            StartDate = now.AddDays(-2).AddHours(11).AddMinutes(30),
                            EndDate = now.AddDays(-1).AddHours(13),
                            IsAllDay = false,
                            Location = "Endereço do meu evento",
                            Notes = "Teste"
                        },
                        new Event
                        {
                            EventId = 1002,
                            CalendarId = 2,
                            Title = "Meu evento 2",
                            StartDate = now.AddDays(-10).AddHours(10),
                            EndDate = now.AddDays(-5).AddHours(15),
                            IsAllDay = false,
                            Location = "Endereço do meu outro evento",
                            Notes = "Teste"
                        }
                    };
                }
            }
        }
    </script>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head id="Head1" runat="server">
        <title>Ext.Net Example</title>
    </head>
    <body>
        <form id="Form1" runat="server">
        <ext:ResourceManager ID="ResourceManager1" runat="server" />
        <ext:Viewport ID="Viewport1" runat="server" Layout="fit">
            <Items>
    <ext:Panel ID="pnAgenda" runat="server" Layout="Border" Title="Agenda" Icon="Calendar">
                                            <TopBar>
                                                <ext:Toolbar ID="Toolbar7" Flat="true" runat="server">
                                                    <Items>
                                                        <ext:Image ID="Image5" Height="55" Width="116" runat="server" ImageUrl="../App_themes/Imagens/top_logo.gif">
                                                        </ext:Image>
                                                        <ext:ToolbarFill />
                                                        <ext:Button ID="Button9" runat="server" Icon="Disk" Text="Salvar alterações">
                                                        </ext:Button>
                                                    </Items>
                                                </ext:Toolbar>
                                            </TopBar>
                                            <Items>
                                                <ext:Panel ID="Panel2" runat="server" Title="..." Layout="Border" Region="Center">
                                                    <Items>
                                                        <ext:Panel ID="Panel4" runat="server" Width="180" Region="West" Border="false">
                                                            <Items>
                                                                <ext:DatePicker StyleSpec="border-style: none;" ID="DatePicker1" runat="server">
                                                                </ext:DatePicker>
                                                            </Items>
                                                        </ext:Panel>
                                                        <ext:CalendarPanel ID="CalendarPanel1" runat="server" Region="Center" ActiveIndex="2"
                                                            Border="false">
                                                            <GroupStore ID="GroupStore1" runat="server">
                                                                <Groups>
                                                                    <ext:Group CalendarId="1" Title="Home" />
                                                                    <ext:Group CalendarId="2" Title="Work" />
                                                                    <ext:Group CalendarId="3" Title="School" />
                                                                </Groups>
                                                            </GroupStore>
                                                            <Listeners>
                                                                <DayClick Handler="#{EventEditWindow1}.show({StartDate: dt,IsAllDay: allDay}, el);" />
                                                            </Listeners>
                                                            <EventStore runat="server" ID="calendarStore">
                   
                                                            </EventStore>
                                                            <MonthView ID="MonthView1" runat="server" ShowHeader="true" ShowWeekLinks="true"
                                                                ShowWeekNumbers="true" />
                                                        </ext:CalendarPanel>
                                                    </Items>
                                                </ext:Panel>
                                            </Items>
                                        </ext:Panel>
                                        
     </Items></ext:Viewport>
         <ext:EventEditWindow ID="EventEditWindow1"  runat="server" Hidden="true" GroupStoreID="GroupStore1">
        
            <%--      <Listeners>
                    <EventAdd    Fn="CompanyX.record.add" Scope="CompanyX" />
                    <EventUpdate Fn="CompanyX.record.update" Scope="CompanyX" />
                    <EditDetails Fn="CompanyX.record.edit" Scope="CompanyX" />
                    <EventDelete Fn="CompanyX.record.remove" Scope="CompanyX" />
                </Listeners>--%>
        </ext:EventEditWindow>
     
        </form>
    </body>
    </html>
  4. #14
    Hi,

    For me both events are visible in the Month view. Can you provide screenshot?

    Also, how to translate everything (some things get translated automatically, but others, like "Day, Week, Month" at the top don't).
    You can use DayText, WeekText and MonthText properties of CalendarPanel
  5. #15
    Screenshot:
    Click image for larger version. 

Name:	Calendar.jpg 
Views:	188 
Size:	83.9 KB 
ID:	1771
  6. #16
    Hi,

    I guess that you use some custom css rules because i don't see that today is marked and some date numbers in the cells has different alignment
    For me your sample looks correct
    Attached Thumbnails Click image for larger version. 

Name:	screen1.png 
Views:	116 
Size:	26.8 KB 
ID:	1772  
  7. #17
    Really strange... I would ask about this numbers problem too. I'm trying the example just the way i sent you, no extra css... And it's not anything browser related either, because i tried firefox and ie8. Couldn't i be missing some css that you're using?
  8. #18
    I started a new website from scratch and tried the same example. Same results, only one event, no today, unaligned numbers, etc. It really must be something missing...
  9. #19
    Hi,

    Please ensure that you use latest version. If after update from SVN you have the same result then please create test project, include all assemblies and send to support email
  10. #20
    Ok vlad. I've updated this morning, i'll update once more and if problem persists i'll send the project.
Page 2 of 6 FirstFirst 1234 ... LastLast

Similar Threads

  1. [CLOSED] Calendar
    By HOWARDJ in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Feb 20, 2012, 8:52 AM
  2. Replies: 0
    Last Post: Jan 13, 2012, 2:33 PM
  3. Replies: 9
    Last Post: Apr 12, 2011, 3:13 PM
  4. [CLOSED] [1.0] How to: Calendar
    By FVNoel in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Mar 22, 2011, 3:22 PM
  5. [CLOSED] [1.0] Calendar bug
    By x1000 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Oct 19, 2010, 12:17 PM

Posting Permissions