Telerik Forums
UI for ASP.NET AJAX Forum
10 answers
204 views
Hi,

Just tried to put a simple RadScheduler with webservice binding in an usercontrol, but get a javascript error when loading the page. the error says "The server method 'GetAppointments' failed." the "OnClientRequestFailed" is fired as well. If I put the same radscheduler control directly in a aspx page, it works fine. Is there any specific settings for such scenario?  Thanks in advance.

ascx code:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Scheduler.ascx.cs" Inherits="Usercontrols_Scheduler" %>
 
<telerik:RadScheduler ID="RadScheduler1" runat="server"AppointmentStyleMode="Default"
    SelectedView="WeekView" Width="100%" Height="100%" Culture="en-AU" WeekView-HeaderDateFormat="d/MM/yyyy"
    TimelineView-HeaderDateFormat="d/MM/yyyy" TimelineView-ColumnHeaderDateFormat="ddd d/MM"
    AdvancedForm-ZIndex="7002">
    <AdvancedForm Modal="true" />
    <TimelineView NumberOfSlots="7" />
    <WebServiceSettings Path="../SchedulerWebService.asmx" ResourcePopulationMode="ServerSide" />
</telerik:RadScheduler>

aspx page (parent page):
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="test.aspx.cs" Inherits="Forms_MasterData_test" %>
 
<%@ Register Src="../../Usercontrols/Scheduler.ascx" TagName="Scheduler" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1">
    </telerik:RadScriptManager>
    <div>
        <uc1:Scheduler ID="Scheduler1" runat="server" />
    </div>
    </form>
</body>
</html>


Jason Li
Top achievements
Rank 1
 answered on 09 Jul 2012
2 answers
196 views
Hi,

I have this code:
 

<telerik:RadComboBox ID="rcbPageSize"

runat="Server"

skin="Gray"

AllowCustomText="true"

Style="float:right; margin-left: 5px;"

Width="60px"

OnClientTextChange = "PageSizeChanged"
OnClientSelectedIndexChange =  "PageSizeChanged">

<Items>

    <telerik:RadComboBoxItem runat="Server" Text="10" Value="10" />

    <telerik:RadComboBoxItem runat="Server" Text="20" Value="20" Selected="true" />

    <telerik:RadComboBoxItem runat="Server" Text="50" Value="50" />

    <telerik:RadComboBoxItem runat="Server" Text="150" Value="150" />

    <telerik:RadComboBoxItem runat="Server" Text="250" Value="250" />

</Items>

</telerik:RadComboBox>

 

<telerik:RadCodeBlock ID="rcb" runat="server">

 <script type="text/javascript">

 

 

function PageSizeChanged(sender, eventArgs) {

alert("You typed " + sender.get_text());

}

 

 

 

</script>

</telerik:RadCodeBlock>

 

 

 

 

When I change the selection, the function "PageSizeChanged" is called, but when I change the text by typing inside the combobox, the function is never called.

Do you have any idea why?

Thanks for the help.

 

 

 

 

Covertix
Top achievements
Rank 1
 answered on 08 Jul 2012
1 answer
79 views
Has anybody decided to create a UI sample for a forum control?  Maybe a silly question but I know you have a pretty complex dashboard demo, just wondering if you had a forum demo.
Jayesh Goyani
Top achievements
Rank 2
 answered on 08 Jul 2012
0 answers
93 views
Hi
I'M Use RadComboBox in radTreeList In Bellow Code

<telerik:TreeListTemplateColumn DataField="User_ID" UniqueName="User_ID"
                    HeaderText="شناسه کاربر" DataType=System.Int32 HeaderStyle-CssClass="RadGrid" 
                    HeaderStyle-HorizontalAlign=Right ItemStyle-HorizontalAlign=Right>
                      <ItemStyle HorizontalAlign="Right" Width="110px" CssClass=RadGrid />
                      <HeaderStyle HorizontalAlign="Right" Width="110px" CssClass=RadGrid />
                    <ItemTemplate>
                      <asp:Label ID="Label3" runat="server" Text='<%# Eval("User")%>' CssClass=RadGrid Width="100%" />
                    </ItemTemplate>
                    <EditItemTemplate>
                        <telerik:RadComboBox ID="E_cmbUser_ID" runat="server" DataSourceID="SQLDSUser_ID" Width="100px"
                            DataTextField="Name" DataValueField="ID" CssClass=RadGrid />
                    </EditItemTemplate>
                    <InsertItemTemplate>
                        <telerik:RadComboBox ID="I_cmbUser_ID" runat="server" DataSourceID="SQLDSUser_ID" Width="100px"
                            DataTextField="Name" DataValueField="ID" CssClass=RadGrid />
                    </InsertItemTemplate>
                </telerik:TreeListTemplateColumn>


Problem When Insert Or Edit Aoutomatic Insert Button In RadTreeList .
Return Null Value From Sql In RadComboBox

and Not Access To RadComboBox 

Tanx

mehdi
Top achievements
Rank 1
 asked on 08 Jul 2012
1 answer
67 views
I have the grid like this:
    <telerik:RadGrid ID="ReportsListGrid" ShowStatusBar="true" runat="server" AllowPaging="True"
        AllowSorting="true" AllowMultiRowSelection="True" PageSize="20" OnNeedDataSource="ReportsListGrid_NeedDataSource">
        <MasterTableView TableLayout="Fixed" DataKeyNames="ReportId" AutoGenerateColumns="True">
            <Columns>
                <telerik:GridBoundColumn DataField="ReportId" HeaderText="ReportId" AllowFiltering="false"
                    SortExpression="ReportId" />
                <telerik:GridBoundColumn DataField="Name" HeaderText="Name" SortExpression="Name" />
                <telerik:GridBoundColumn DataField="Description" HeaderText="Description" SortExpression="Description" />
                <telerik:GridBoundColumn DataField="ReportLocation" HeaderText="ReportLocation" SortExpression="ReportLocation" />
                <telerik:GridBoundColumn DataField="Active" HeaderText="Active" SortExpression="Active" />
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>

And Following is how i am binding it:

        Dim reports = ReportFactory.CreateReportController().GetReports()
'reports is IList  collection
        ReportsListGrid.DataSource = reports
        ReportsListGrid.DataBind()

On the pageload grid loads correctly, but when i click on any column header for sorting it says: 

"System.IndexOutOfRangeException: Cannot find column ReportLocation."

Please help!!!!!!!!!!!

Thanks J
Jayesh Goyani
Top achievements
Rank 2
 answered on 07 Jul 2012
1 answer
65 views
I am having Copy icon and edit icon in a row, when I click on copy I would like to do the same behavior for edit click, means I would like to open the edit template is it possible to do.
Jayesh Goyani
Top achievements
Rank 2
 answered on 07 Jul 2012
9 answers
280 views
Hi all,

I have a tree list and 2 radio button under this tree list... when i try to find the radio button on my tree list its state has been always checked false.. i have assigned the auto postback .. but its not working it seems..

Source is 
<td>
  <asp:RadioButton ID="rbDepPer" runat="server" GroupName="dep" />
  <telerik:RadNumericTextBox ID="txtBoxDepPer" Text='<%# Bind("DepPer") %>' runat="server">
  </telerik:RadNumericTextBox>
 </td>
  <td>
  Depreciation Year:
 </td>
 <td>
<asp:RadioButton ID="rbDepYear" runat="server" GroupName="dep" />
 <telerik:RadNumericTextBox ID="txtBoxDepYear" Text='<%# Bind("DepYear") %>' runat="server"
 Width="300px" >
 </telerik:RadNumericTextBox>
   </td>
Code Behind
Protected Sub RadTreeList1_ItemCreated(ByVal sender As Object, ByVal e As Telerik.Web.UI.TreeListItemCreatedEventArgs) Handles RadTreeList1.ItemCreated
       If TypeOf e.Item Is TreeListEditFormItem AndAlso DirectCast(e.Item, TreeListEditFormItem).IsInEditMode Then
           Dim item As TreeListEditableItem = TryCast(e.Item, TreeListEditableItem)
           Dim rad1 As RadioButton = DirectCast(item.FindControl("rbDepPer"), RadioButton)
           Dim rad2 As RadioButton = DirectCast(item.FindControl("rbDepYear"), RadioButton)
           Dim textBox = TryCast(item.FindControl("txtBoxDepPer"), RadNumericTextBox)
           Dim textBox2 = TryCast(item.FindControl("txtBoxDepYear"), RadNumericTextBox)
           rad1.AutoPostBack = True
           rad2.AutoPostBack = True
           If rad1.Checked = True Then
               textBox.Enabled = True
               textBox2.Enabled = False
           ElseIf rad2.Checked = True Then
               textBox2.Enabled = True
               textBox.Enabled = False
           End If
       End If
   End Sub


I need to set visibility of that text box control while clicking the radio button..
Please help..


Regards,

Prassin
Prassin
Top achievements
Rank 1
 answered on 07 Jul 2012
1 answer
41 views
I am trying to create a very very basic form template, that looks like below

Employee Details

Officer Information                      Department Information                  Status
Label   Txt Box                            Label   Txt Box                                Label     Chx Box
Label   Txt Box                            Label   Txt Box                                Label     Text Box
Label   Txt Box                            Label   Txt Box 
Label   Txt Box                            Label   Txt Box 
Label   Txt Box                            Label   Txt Box 
Label   Txt Box                            Label   Txt Box 


Update    Cancel

below is the code I got and it is all screwed up, I tried to use the edit template designer, but it didn't seem very fluid.

any help would be greatly appreciated. I tried a bunch of stuff in here so alot of the junk can go away. I just want it to look neat and professional and not have any alignment issues.


<EditFormSettings EditFormType="Template">
<EditColumn FilterControlAltText="Filter EditCommandColumn column"
        UniqueName="EditCommandColumn1"></EditColumn>
    <FormTemplate>
    <table id="Table2" cellspacing="2" cellpadding="1" width="100%" border="0" rules="none"
                        style="border-collapse: collapse; background: white;">
                        <tr class="EditFormHeader">
                            <td style="font-size: small">
                                <b>Employee Details</b>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <b>Officer Info:</b>
                            </td>
                        </tr>
                        
 
   <tr>
        <asp:Label ID="Label1" runat="server" Text="First Name:"></asp:Label>
        <asp:TextBox ID="TextBox1" runat="server" CssClass="txtbox" Text='<%# Bind("emp_Fname") %>'></asp:TextBox>
        <asp:Label ID="Label6" runat="server" Text="ID Num:"></asp:Label>
        <asp:TextBox ID="TextBox5" runat="server" CssClass="txtbox" Text='<%# Bind("emp_IdNum") %>'></asp:TextBox>
   </tr>
   <tr>    
        <asp:Label ID="Label3" runat="server" Text="Last Name:"></asp:Label>
        <asp:TextBox ID="TextBox2" runat="server" CssClass="txtbox" Text='<%# Bind("emp_Lname") %>'></asp:TextBox>
        <asp:Label ID="Label8" runat="server" Text="Classification"></asp:Label>
        <asp:TextBox ID="TextBox7" runat="server" CssClass="txtbox" Text='<%# Bind("emp_class") %>'></asp:TextBox>
   </tr>
       </table>
      <tr>
      <td>
        <asp:Label ID="Label4" runat="server" Text="Race:"></asp:Label>
        <asp:TextBox ID="TextBox3" runat="server" Height="21px"
            style="margin-left: 51px" Text='<%# Bind("emp_Race") %>'></asp:TextBox>
        </td>
      </tr>
      <tr>
      <td>
        <asp:Label ID="Label5" runat="server" Text="Sex"></asp:Label>
          :<asp:TextBox ID="TextBox4" runat="server" Height="21px"
            style="margin-left: 62px" Text='<%# Bind("emp_Sex") %>'></asp:TextBox>
</td>
      </tr>
      <tr>
      <td>
          <asp:Label ID="Label7" runat="server" Text="DOB:"></asp:Label>
          <asp:TextBox ID="TextBox6" runat="server" Height="21px"
              style="margin-left: 56px" Text='<%# Bind("emp_DOB") %>'></asp:TextBox>
</td>
      </tr>
      <tr>
      <td>
           </td>
      </tr>
      <tr>
      <td>
        <asp:Label ID="Label9" runat="server" Text="Email Address"></asp:Label>
        <asp:TextBox ID="TextBox8" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_Email") %>'></asp:TextBox>
        <asp:Label ID="Label10" runat="server" Text="Street Address"></asp:Label>
        <asp:TextBox ID="TextBox9" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_StreetAdd") %>'></asp:TextBox>
        <asp:Label ID="Label11" runat="server" Text="City"></asp:Label>
        <asp:TextBox ID="TextBox10" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_City") %>'></asp:TextBox>
        <asp:Label ID="Label12" runat="server" Text="Zip"></asp:Label>
        <asp:TextBox ID="TextBox11" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_Zip") %>'></asp:TextBox>
        <asp:Label ID="Label13" runat="server" Text="Hire Date"></asp:Label>
        <asp:TextBox ID="TextBox12" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_HireDate") %>'></asp:TextBox>
        <asp:Label ID="Label14" runat="server" Text="Class Date"></asp:Label>
        <asp:TextBox ID="TextBox13" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_classDate") %>'></asp:TextBox>
        <asp:Label ID="Label15" runat="server" Text="Grant Position"></asp:Label>
        <asp:TextBox ID="TextBox14" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_GrantPost") %>'></asp:TextBox>
         <asp:Label ID="Label17" runat="server" Text="Inactive"></asp:Label>   
         <asp:CheckBox ID="CheckBox1" runat="server"
                        Checked='<%# Bind("emp_Inactive") %>' />
        <asp:Label ID="Label16" runat="server" Text="Reason Inactive"></asp:Label>
        <asp:TextBox ID="TextBox15" runat="server" Height="21px"
            style="margin-left: 18px" Text='<%# Bind("emp_ReasonInactive") %>'></asp:TextBox>
         
            <tr>
                            <td align="right">
                                <asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>'
                                    runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'>
                                </asp:Button
<asp:Button ID="btnCancel" Text="Cancel" runat="server" CausesValidation="False"
CommandName="Cancel"></asp:Button>
                            </td>
                        </tr>
         
        
         
    </FormTemplate>
</EditFormSettings>



Dave
Top achievements
Rank 1
 answered on 06 Jul 2012
1 answer
64 views
I have a page, lets say Page1 that does a response.redirect to another page, Page2. 

Page2 has a RadGrid in it and it takes about 30 seconds to load.  The problem is the Response.rediirect stays on Page1 until Page2 is done loading the RadGrid. 

How can I load Page2 to load, then load the RadGrid so users are stuck on Page1 for 30 seconds?
Sayle
Top achievements
Rank 1
 answered on 06 Jul 2012
1 answer
106 views
First off, let me say that I am quite excited to learn more about RadControls.  I'm still mostly a beginner .net developer (I've been developing with ASP classic for years but only touched .net here and there) but even after just a few days of working with the trial I can see that these controls are going to help me move forward immensely.

Anyway, one of the tasks that I need to perform is pretty simple, I think.  I need to be able to use a tab control to load content from multiple sources - other servers on our network.  The content will be called via url and I'd like it to maintain "state" if I can use that term in this context.  In other words, click tab 1, load content, click link in content, content changes.  Click tab 2, load content.  Click tab 1 again and return to content as it was when I last viewed it.

I'm currently trying to accomplish this using the Tabstrip/MulitPage/Pageview combination that is shown in the demos on this site.  I have no problem getting everything to load (contentURL="xxxxx" is simple enough) but the state is lost when you click another tab.

I also attempted to do this using RadWindow and I believe the "state" was maintained the way I wanted it to be but when I tried to combine that with the Tab/Pageview method I found that the windows need to be told when to show/hide so it seemed to defeat the purpose of using tabs.

Lastly, I'll just add that I thought the first method (tab/multipage/pageview) was working the way I wanted it but I'm not sure if that was ever the case. I've done too much fiddling and I can't remember what worked and what didn't.  I do know that it doesn't work now though and I'm hoping I changed something along to way to make that so.  I may just start a new page and try again from scratch.

At any rate, my question is, simply, is what I'm trying to do the best way to do it and, if so, would someone be kind enough to offer some advice as to how to go about it?  I'll post some code if need be but I have yet to write anything in the codebehind so there's not much to see.

Thanks.
dino
Top achievements
Rank 1
 answered on 06 Jul 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?