Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
136 views

I have the following code on a simple .aspx page:

<telerik:RadAjaxPanel id="rap1" runat="server">  
     <!-- This gives an error saying 'RadToolTipManager' is not a known element. --> 
     <telerik:RadToolTipManager runat="server" id="tipManager" /> 
</telerik:RadAjaxPanel> 

Is there a reason for this?  The RadToolTipManager does work within the application in this scenario.  I am just wondering why it says there is an error.
Rosen
Telerik team
 answered on 05 Mar 2008
3 answers
196 views
Currently scheduler allows to move appointment from one resource to another - but the client side event only has method get_newStartTime() - how do we find out what resource its moving to?

In ideal case, this is what I need:
- be able to find out what resource its moving to
- be able to find if there is any appointment at the target slot? and that appointment object.

Thanks,
Piyush

Dimitar Milushev
Telerik team
 answered on 05 Mar 2008
3 answers
202 views

Hi

I am using full featured MOSS Rad Editor in list items. It is perfect. I want to use MOSS Rad Editor to display the contents on home page.

I am using MOSS RadEditor in my web part.

Telerik.SharePoint.

MOSSRadEditor radEditor;


 protected override void CreateChildControls()

{

base.CreateChildControls();

radEditor =

new MOSSRadEditor();

radEditor.ID =

"contentDisplay";

radEditor.RadControlsDir =

"~/_layouts/RadControls";

this.Controls.Add(radEditor);

}

I can see the editor in the web part and contents also but I have two problems:

1. I want the editor should be view mode only. It should not allow user to modify contents. Right now when I click inside the editor, it turns into edit mode.

2. The editor does not show Flash files and media files.


Please look into this and let me know the solution asap.

Thanks in advance

Umesh

Lini
Telerik team
 answered on 05 Mar 2008
1 answer
139 views
I'll be using a lot of calendar controls in my application, so I thought the most efficient thing to do was to create a shared calendar on my Master Page that I can reference via Date Picker on all the other pages.

This works great, except that I get the calendar showing up where I have the place holder tag.

I attempted to modify the style of the calendar to display:none, but then the calendar doesn't show up when I click a Date Picker.

Is there a way to hide the shared calendar, but still have it show up when a Date Picker is clicked? Thanks
Robert Cathey
Top achievements
Rank 1
 answered on 05 Mar 2008
3 answers
211 views

I've got a Window as an Editor for a RadGrid and I'm converting it from the regular controls to the Prometheus versions.  Everything works ok except the grid doesn't refresh itself after the window closes.  I've got the following code:

Main Page:

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">  
        <script type="text/javascript">  
            function ShowEditForm(id, rowIndex)  
            {  
                var grid = $find("<%= ScheduleEditRadGrid.ClientID %>");  
                  
                var rowControl = grid.get_masterTableView().get_dataItems()[rowIndex].get_element();                  
                grid.get_masterTableView().selectItem(rowControl, true);  
                              
                window.radopen("assignments_edit.aspx?sid=" + id, "EditAssignmentsDialog");  
                return false;   
            }  
             
            function refreshGrid(arg)  
            {  
                if(!arg)  
                {  
                  $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("Rebind");  
                }  
                else  
                {  
                  $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("RebindAndNavigate");  
                }  
            }  
        </script> 
    </telerik:RadCodeBlock> 

and in the Window Page:
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">  
        <script type="text/javascript">  
                function CloseAndRebind()  
                {  
                    GetRadWindow().close();  
                    GetRadWindow().BrowserWindow.refreshGrid(null);  
                }  
                  
                function GetRadWindow()  
                {  
                    var oWindow = null;  
                    if (window.radWindow) oWindow = window.radWindow; //Will work in Moz in all cases, including clasic dialog  
                    else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;//IE (and Moz as well)  
                          
                    return oWindow;  
                }  
 
                function CancelEdit()  
                {  
                    GetRadWindow().close();       
                }  
        </script> 
    </telerik:RadCodeBlock> 

Can you tell me what I haven't changed yet?

Also on a side note your example for this - http://www.telerik.com/DEMOS/ASPNET/Prometheus/Controls/Examples/Integration/GridAndWindow/DefaultCS.aspx doesn't post the window page code for some reason.  It also references the KB for the regular controls in the Description for Edit/Update and on that same line tells you to set EnableAJAX to True on the grid, except we know that property was removed.  The part of the Description for Insert gets it correct. You guys might want to update that so folks trying it for the first time don't get confused.

Thanks,

Jimmy
Stuart Dahlenburg
Top achievements
Rank 1
 answered on 05 Mar 2008
4 answers
305 views

Hello!

I need to update several RadAjaxPanels from javascript. I tried to use somethink like this:

function Update()
{
    <%= RadAjaxPanel1.GetAjaxEventReference("") %>;
    <%= RadAjaxPanel2.GetAjaxEventReference("") %>;
}

But in this case, second one panel will be updated only.

The same situation i have when try to update RadAjaxPanel and do RadComboBox requestItems method.

I think all of this linked with limit of simultaneous HTTP requests.

Can anybody help me?

BlackStar
Top achievements
Rank 1
 answered on 05 Mar 2008
0 answers
79 views
After an AJAX refresh of the RadTreeView in an UpdatePanel in which the currently selected node is removed from the tree, the get_selectedNode() property returns a valid node even though the node no longer exists in the control's node hierarchy. Ideally, it should return null.
 
Edited: nevermind, my mistake: the refresh wasn't complete before the check for the selected node was done. Does anyone know of a way to do a blocking AJAX call?
rcbarth
Top achievements
Rank 1
 asked on 04 Mar 2008
1 answer
144 views
I'm trying to create a dropdown within a GridTemplateColumn. I don't want to use the GridDropDownColumn because I want the dropdown to be available always, not just during the edit call.

Simply put, I can't seem to target the dropdown to set it's selected index / selected value to the one that I desire.

Code snippets to follow.

snippet
Page file.
<rad:RadGrid ID="rgOrder" runat="server" AllowPaging="False" AllowSorting="True" width="400" AllowAutomaticUpdates="true" OnItemCreated="rgItemCreated" OnItemDataBound="rgItemDataBound" OnNeedDataSource="rgNeedDataSource" AllowMultiEdit="True" 
                ShowFooter="false" CssClass="radGrid" EnableEmbeddedSkins="false" ShowHeader="true" AutoGenerateColumns="false" AllowMultiRowEdit="true"> 
                <MasterTableView  EditMode="InPlace" DataKeyNames="ID"> 
                <ItemStyle CssClass="rgRow" /> 
                <FooterStyle CssClass="rgFooter"></FooterStyle> 
                <Columns> 
                 
                    <rad:GridBoundColumn DataField="ID" Display="false" /> 
                    <rad:GridTemplateColumn HeaderText="Image"  HeaderStyle-HorizontalAlign="left" HeaderStyle-Width="30" ItemStyle-Width="30" AllowFiltering="false"> 
                        <ItemTemplate>  
                             
                            <img src="/images/demo_image_for_oc.jpg" alt="demo image"> 
                     
                        </ItemTemplate>  
                    </rad:GridTemplateColumn> 
                    <rad:GridBoundColumn readonly="true" DataField="Description" HeaderText="Description" HeaderStyle-Width="50" ItemStyle-Width="50" SortExpression="Description" HeaderStyle-HorizontalAlign="Left" AllowSorting="true" /> 
                    <rad:GridTemplateColumn UniqueName="Quantity" HeaderText="Quantity" HeaderStyle-HorizontalAlign="left" HeaderStyle-Width="60" ItemStyle-Width="60" AllowFiltering="false"> 
                        <ItemTemplate> 
                          
                            <asp:DropDownList runat="server" ID="ddlQuantity" DataTextField="Quantity" DataValueField="Quantity" DataSourceID="dataQuantity"> 
                            </asp:DropDownList>  
                             
                            <asp:ObjectDataSource TypeName="Oser.Order" ID="dataQuantity" runat="server" SelectMethod="GetAllQuantities"> 
                            </asp:ObjectDataSource> 
                             
                        </ItemTemplate> 
 
                    </rad:GridTemplateColumn> 
                    <rad:GridBoundColumn readonly="true" DataField="Price" HeaderText="Price" HeaderStyle-HorizontalAlign="left" HeaderStyle-Width="35" ItemStyle-Width="35" SortExpression="Price" AllowSorting="true" /> 
                    <rad:GridBoundColumn readonly="true" DataField="QuantityPerUnit" HeaderStyle-HorizontalAlign="left" HeaderText="PerUnit" HeaderStyle-Width="40" ItemStyle-Width="40" SortExpression="PerUnit" AllowSorting="true" /> 
                    <rad:GridEditCommandColumn ButtonType="ImageButton" ItemStyle-CssClass="btnEdit" EditImageUrl="~/images/btn_edit.jpg" HeaderStyle-Width="35" ItemStyle-Width="35" /> 
                    <rad:GridTemplateColumn HeaderText="" HeaderStyle-Width="35" ItemStyle-Width="35" AllowFiltering="false"> 
                        <ItemTemplate>  
             
                            <asp:ImageButton ID="btnDelete" CssClass="btnDelete" OnClientClick="return confirm('Are you sure you want to delete this item?');" OnCommand="DeleteItem" CommandArgument='<%# Eval("ID") %>' ImageUrl="/images/btn_delete.jpg" runat="server" /> 
                         
                        </ItemTemplate> 
                    </rad:GridTemplateColumn> 
                     
                </Columns>                      
                </MasterTableView> 
            </rad:RadGrid> 

snippet
.cs file
protected void rgItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e) 
    { 
        Dictionary<int, int> orderItems = (Dictionary<int, int>)Session["orderItems"]; 
        if (orderItems != null && orderItems.Count > 0) 
        { 
            foreach (KeyValuePair<int, int> kvp in orderItems) 
            { 
                GridDataItem dataItem = e.Item as GridDataItem; 
                (DropDownList)dataItem["Quantity"].Controls[0]).SelectedValue = kvp.Value.ToString(); 
 
            } 
        } 
    } 


The current form returns a standard, "System.NullReferenceException: Object reference not set to an instance of an object." exception, pointing at the line:

(DropDownList)dataItem["Quantity"].Controls[0]).SelectedValue = kvp.Value.ToString();

Am I accessing the cell incorrectly? I've tried setting the same code under the OnItemCreated method as well, but with the same results.

Thank you for any help you can provide.
-Josh
Josh
Top achievements
Rank 1
 answered on 04 Mar 2008
4 answers
189 views
I am trying to hide the dateinput of the radcalendar control but when I do I get a javascript error (Invalid Operation) telling me that the dateinput does not exist. Have someone experienced this ? Is there a workaround? All I do is setting the datinput-visible to false. Thanks.
John Brownell
Top achievements
Rank 1
 answered on 04 Mar 2008
7 answers
241 views

I cannot get the ResolveUpdateControls to fire for the ajax manager.  This exact procedure works in latest asp.net release, am I missing something with the new version?

<asp:ScriptManager ID="ScriptManager1" runat="server" /> 
<telerik:RadAjaxManager ID="AdminAjaxManager" runat="server" 
OnAjaxRequest="AdminAjaxManager_AjaxRequest" 
OnResolveUpdatedControls="AdminAjaxManager_ResolveUpdatedControls">  
                <AjaxSettings> 
                    <telerik:AjaxSetting AjaxControlID="Button1"/>  
                </AjaxSettings> 
            </telerik:RadAjaxManager> 
            <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" />      
                    <radT:RadTreeView ID="AdminTreeView" runat="server">  
                    </radT:RadTreeView> 
                

protected void AdminAjaxManager_AjaxRequest(object sender, AjaxRequestEventArgs e)  
{  
 
}  
protected void AdminAjaxManager_ResolveUpdatedControls(object sender, AjaxUpdatedControlsEventArgs e)  
{  
 
}  
protected void Button1_Click(object sender, EventArgs e)  
{  
 
} 

Richard
Top achievements
Rank 1
 answered on 04 Mar 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?