Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
101 views
Hi

I am using RadComboBox as below


<telerik:RadComboBox ID="RadComboBox1" runat="server" Width="250px" ShowToggleImage="True"
                                            Style="vertical-align: middle;" OnClientDropDownOpened="OnClientDropDownOpenedHandler"
                                            EmptyMessage="Choose a destination" ExpandAnimation-Type="None" CollapseAnimation-Type="None">
                                            <ItemTemplate>
                                                <div id="div1">
                                                    <telerik:RadTreeView runat="server" ID="RadTreeView1" OnClientNodeClicking="nodeClicking"
                                                        Width="100%" Height="140px">
                                                        <Nodes>
                                                        </Nodes>
                                                    </telerik:RadTreeView>
                                                </div>
                                            </ItemTemplate>
                                            <Items>
                                                <telerik:RadComboBoxItem Text="" />
                                            </Items>
                                        </telerik:RadComboBox>

I am saving Full Path in DB like

string Path = "" ;
       foreach (RadComboBoxItem myItem in RadComboBoxIn.Items)
       {
           RadTreeView myTree = (RadTreeView)myItem.FindControl("RadTreeView1");
           Path = myTree.SelectedNode.FullPath;
       }

So now onload i want to set Combo and tree to that FullPath which i saved in DB.

thanks
Muhammad Imran
Top achievements
Rank 1
 asked on 08 Dec 2010
6 answers
676 views
I haven't tried to reproduce this in a simpler ASPX page but in my solution if I use an asp:Button button then when the postback occurs the RadEditor1.Text value is correct and shows the changes that was made.

However, if I use an asp:LinkButton when it's clicked the post back does NOT show the chnages that was just made but rather shows the original content that was put into the rad editor.

Any thoughts?

Is there something about a LinkButton that causes the editor trouble?  This is on .NET 4.0 using the 40 library from 2010 Q2.

Thanks,
Kevin
Kevin Warnke
Top achievements
Rank 1
 answered on 08 Dec 2010
3 answers
406 views
Hi,
Put this into the context of a construction company, I need to get a system running where there is a hierarchy list of current jobs which can be expanded to show a list of machines booked to that job, which can be further expanded to show a list of operators for that machine currently working on that job. This will also have two further tables containing machines and operators which can be dragged onto jobs and machined respectively, this will then update records in a MS SQL database.
I just need to know if this is possible and if so, some guidence on how to make this posssible, as this is the first time I have used Telerik.

Many Thanks in advance,
Dan
Veli
Telerik team
 answered on 08 Dec 2010
2 answers
101 views
Hi there. I think this is not telerik-specific but perhaps you might be able to help nontheless:

I have a radWindow with multiple Elements. One of them is a button, another is a "simple" radgrid
One of them is a Button that opens a new window. In that window an element can be changed in the database which is the datasource of the radgrid.

After closing that window I initiate a postback through the "OnClientClose"-Method.

Before opening that window the datasource of the radgrid had 5 Elements. After closing that window the datasource has 6 Elements (as wanted). I can see in the OnNeedsDataSource-Event that the datasource REALLY has that 6 elements. But in the frontend the new element is not shown.

I can close and reopen the window or reload it with response.redirect(response.url.toString()) but that of course kills all form entries made.

Any clue what causes that behaviour?

Ole
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="DetailInfos.aspx.cs" Inherits="waPMHI.dlg.DetailInfos" %>
  
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <telerik:RadCodeBlock ID="RadCodeBlockInfo" runat="server">
  
        <script type="text/javascript" language="javascript">
  
            function GetRadWindow() {
                var oWindow = null;
                if (window.radWindow) oWindow = window.radWindow;
                else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;
                return oWindow;
            }
  
            function CloseWindow() {
                var oWindow = GetRadWindow();
                oWindow.close();
            }
  
            function AddAttachment() {
                var oBrowserWnd = GetRadWindow().BrowserWindow;
                setTimeout(function() {
                    var oWnd = oBrowserWnd.radopen("../dlg/GeneralUploader.aspx", "Upload");
                    oWnd.SetUrl(oWnd.GetUrl());
                    oWnd.add_close(OnClientClose);
                }, 300);
            }
  
            function OnClientClose(oWnd) {
                // Nach dem Schliessen eines Fensters: AjaxRequest
                oWnd.remove_close(OnClientClose);
  
                $find("<%= infoManager.ClientID %>").ajaxRequest("AddAttachmentClose");
            }
  
          <!-- [...] more JS -->
                          
        </script>
  
    </telerik:RadCodeBlock>
</head>
<body class="dlgInfos" onkeypress="Escape(event);">
    <form id="form1" runat="server">
    <telerik:RadWindow ID="DetailInfo" runat="server" SkinID="SingletonSkin" />
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
    <telerik:RadFormDecorator ID="RadFormDecorator" runat="server" DecoratedControls="Buttons" />
    <telerik:RadAjaxManager ID="infoManager" runat="server" OnAjaxRequest="InfoManager_AjaxRequest" />
    <table width="100%" cellpadding="0px" cellspacing="0px">
        <tr>
            <td>
                <asp:UpdatePanel ID="FormPanel" runat="server" UpdateMode="Conditional">
                    <ContentTemplate>
<!-- More Elements [...] -->
                         
                                        <asp:Button ID="btnAddAttachment" Enabled="false" runat="server" Text="<%$Resources:TextResources, ID_MAIL_ADDATTACHMENT%>"
                                            OnClick="btnAddAttachment_Click" />
                                    
<!-- More elements [...] -->
                    </ContentTemplate>
                </asp:UpdatePanel>
                <br />
                  
                                    <telerik:RadGrid runat="server"  Width="100%" ID="attGrid" ShowHeader="false" AutoGenerateColumns="true" OnNeedDataSource="infoGrid_NeedDataSource">    
                                    </telerik:RadGrid>
                                    
             
    </form>
</body>
</html>

P.S:
Perhaps it might help to know that the NeedsDataSource-Event does not fire automaticly after closing the popup. I have to rebind manually for it to fire.
Ole Albers
Top achievements
Rank 2
 answered on 08 Dec 2010
1 answer
137 views
Hi,

I'm trying to export the content of the radeditor to PDF. I can load the radeditor without a problem ie RadEditor.Content = MyText()
I used the below on a button click event:

PrintEditor.ExportToPdf();

When I do I can the attached error. The thing is, when I copy the html code from the editor and hard code it in to the <Content></Content> tags it works fine.

Any clues?

Thanks in advance.

Dobromir
Telerik team
 answered on 08 Dec 2010
1 answer
64 views
Hi,

Could you please tell me how to call a web UserControl in FilterTemplate section of RadGrid.
My requirement is that in a webuser control for DateTime column in filter section I have to create a filter which sould have following controls and options-

1- From and To date in filter template(when user enter these two  dates and press enter show the records between these two dates)
2- The same column should have a filter Icon in filtertemplae section with GreateThan, Lessthan,Equals,NotEquals filters option, on seletion of any of these options I have to filter based on From Date value(means if i enter a date in From date field the then select Gretaerthan option from filter than it should return the records which are greater tha the values provided in from date field.) 

Please suggest me regarding that how to achive similar kind of setup for filter using telerik controls .

Regards,
Mamta
Iana Tsolova
Telerik team
 answered on 08 Dec 2010
2 answers
435 views
Hi,

I have Radwindow Manager in page, Radwindow1 is opened  if a condition is met on server side . User closes this window by clicking  "Save"  /  "Cancel"  Button .  If  "Save" button is clicked, information is processed on the server and Radwindow1 is closed.

Logic is:
If(condition1)
{
    Create a new Radwindow and add it to Radwindow Manager
    Open RadWindow1
}


SaveButton_Click( ....)
{
   .......................
   close RadWindow.....
}

Any idea?

Thanks
Prava
Prava kafle
Top achievements
Rank 1
 answered on 08 Dec 2010
2 answers
122 views
Hello,

          I need Recurrence control  on Button click without scheduler. Which will pop up on button click.   Is there any way to do this. If yes then let me know with sample code.



Thanks
Regards
Rahul
Rahul
Top achievements
Rank 1
 answered on 08 Dec 2010
2 answers
123 views
protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
{
if (e.Item is GridDataItem)
{
GridDataItem dataItem = (GridDataItem)e.Item;
rev1Sum += CorrectlyParseString((dataItem["Rev1"].FindControl("Rev1Label") as Label).Text.ToString());
}
else if (e.Item is GridFooterItem)
GridFooterItem footer = (GridFooterItem)e.Item;
(footer["Rev1"].FindControl("Rev1Total") as RadNumericTextBox).Value = Double.Parse(rev1Sum.ToString());
}
}
when I'm exporting to Excel, it gives me Object reference not set to an instance of an object
Rev1 is GridTemplateColumn
Ramy Mahrous
Top achievements
Rank 1
 answered on 08 Dec 2010
18 answers
560 views
t looks like the only content that is to be displayed in RadWindow is the content of a page that is specified in NavigateURL. That is a problem for me because what I want to display is the dynamic content that I show on the same page on which the rad window is defined.

Is it possible to display the content on the same page defined in the rad window detailsvew?
Neerav
Top achievements
Rank 1
 answered on 08 Dec 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?