Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
374 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
85 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
78 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
48 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
399 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
69 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
103 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
522 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
2 answers
140 views

I have a RadGrid that has a DataList inside of each row. 
The DataList has checkboxes in them. 

Example:
Let's say the grid has four rows, and the datalist inside each row has three rows itself. 

When a user checks one of the checkboxes in the datalist, I need the same checkbox in the the other three rows with the same value to get checked.  Would it be easier for me to do it client side or server side?  Also, any help to achieve this would be great.
Here a sample of the code:

<telerik:GridTemplateColumn HeaderText="Optional Languages" HeaderStyle-Width="100%" ItemStyle-HorizontalAlign="Left" Groupable="false">
   <ItemTemplate>
   <asp:DataList ID="DataListl" OnItemDataBound="DataList1_ItemDataBound" RepeatLayout="Table" Width="100%" ItemStyle-BorderStyle="None" runat="server">
    <ItemTemplate>
            <asp:CheckBox ID="CheckboxOptional1" runat="server" />                                   
            <asp:Literal ID="LiteralOptional1" Visible="false" runat="server" />
         </ItemTemplate>
      </asp:DataList>
   </ItemTemplate>
</telerik:GridTemplateColumn>
Mike
Top achievements
Rank 1
 answered on 08 Dec 2010
2 answers
427 views
I'm trying to create a single icon button to launch a lookup window. I want the button to match the calendar popup button (Default skin) that can be viewed on this demo: http://demos.telerik.com/aspnet-ajax/calendar/examples/datepicker/custompopup/defaultcs.aspx.

I tried creating a RadButton with an icon element (and no text property) but it still has a space to the right of the button (and has the button background whereas the calendar background is transparent until rollover). Any suggections?  
<telerik:RadButton ID="RadButton1" runat="server" >
    <Icon PrimaryIconUrl="images/icons/find.png" />
</telerik:RadButton>
 

 

 

 

 

 

 

 

Richard
Top achievements
Rank 1
 answered on 08 Dec 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?