Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
92 views
Hi all,

Is it at all possible to use the FileManager/ImageManager independent of the Editor control?

In some areas of my site, i am using the editor and so the user will be used to the FileManager/ImageManager. In some other areas i have textboxes which the user will need to select a path to an image...so this is where i would like to have a button which opens the FileManager directly, and then populates the textbox with the path???!!! Is this possible????

Many thanks for any help received

Steve
Rumen
Telerik team
 answered on 28 Apr 2008
0 answers
226 views

PLEASE DISREGARD THIS POST...  PROBLEM RESOLVED ITSELF...

  • ASP.NET version :  3.5
  • OS : Vista
  • exact browser version :  IE 7
  • exact version of the Telerik product : latest one
  • preferred programming language (VB.NET or C#)  : C#

    On my .aspx page I declare my datepicker control as follows:

    <asp:ScriptManager ID="ScriptManager1" runat="server" />
    <t
    elerik:RadDatePicker ID="calender" AutoPostBack="true" runat="server" onselecteddatechanged="calender_SelectedDateChanged"> </telerik:RadDatePicker>

    Then on my code behind page I have the following event declared:

    protected void calender_SelectedDateChanged(object sender, Telerik.Web.UI.Calendar.SelectedDateChangedEventArgs e)
    {
         int x = 0;
    }

    Now when I select a new date on the datepicker control the page does a post back however...  this event on the code behind page does NOT fire. 

    Any Ideas?
    ~N

  • Nick
    Top achievements
    Rank 1
     asked on 28 Apr 2008
    1 answer
    120 views

    Hi.
    I have trouble with my masterpage after changing to Q1 2008 of the  RadControls for asp.net Ajax

    In my masterpage I have a calender and a grid working together. When I click the calendar the grid updates with som data. in the grid i have 2 imagebuttons in each row, theese two takes me to a "register" page. During itemdatabound each button is given a spesific postbackurl according to the dataId of that row.

    So far so good. But when I click one of the buttons the new page is loaded just fine, but if I click either of the buttons a second time(in case I wanted the other item) then a Javascript or a server error occurs. in both the server error and the javascript error the same thing is presented. EnableEventValidation=true. set the event validation false. I dont want to do that, can you help me? I've pasted the stacktrase from the serverside error:

    System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String argument) +2132728
       System.Web.UI.Control.ValidateEvent(String uniqueID, String eventArgument) +108
       System.Web.UI.WebControls.ImageButton.RaisePostBackEvent(String eventArgument) +32
       System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7
       System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11
       System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)


    ThomasJ
    Top achievements
    Rank 2
     answered on 28 Apr 2008
    2 answers
    95 views
    I'm converting my radgrid/ajax to prometheus and in doing so my client - side access is breaking with the 'mastertableview.rows is null blah blah blah'

    function ShowEditTree(rowIndex)

    {

    var grid = window["<%= RadGrid1.ClientID %>"];

    var rowControl = grid.MasterTableView.Rows[rowIndex].Control;

    grid.MasterTableView.SelectRow(rowControl,

    true);

    var tf = grid.MasterTableView.GetCellByColumnUniqueName(grid.MasterTableView.Rows[rowIndex], "CourseID");

    var CourseID = tf.innerHTML ;

    }
    I've changed the client setting required by prometheus to enable AllowRowSelect(which was a change from the previous version).

    <

    ClientSettings EnableRowHoverStyle="True" >

    <

    Selecting AllowRowSelect="True" />

    <

    ClientEvents OnRowClick="Dummy"></ClientEvents>

    </

    ClientSettings>

    What am I missing?

    david
    Top achievements
    Rank 1
     answered on 28 Apr 2008
    1 answer
    156 views
    Hi,

    I have a RadGrid with several checkboxes and I need people to be able to group by them.  For example I have a field called LIVE which they will want to group by to see the live actions separate from completed (non-live) actions.

    When I group now - it works, but I get groups of True/False as it is a checkbox field.  Is it possible to specify text such as "Yes" or "No" instead, or even "Live Issues", "Completed Issues" as the header of each group instead of true/false.

    Thanks in advance
    Stephen
    Top achievements
    Rank 1
     answered on 28 Apr 2008
    2 answers
    165 views
    Hi,

    I'm trying to create a custom dialog for the AJAX version of the Editor control.

    When I click my toolbar button, the dialog opens - unfortunately it opens wildly out of control. Typically it is much wider than desired, extending off screen. When I mouse over it, usually (although not always) it will shrink down to the size I want:

    http://img122.imageshack.us/img122/747/telerik1jg6.jpg
    http://img386.imageshack.us/img386/7857/telerik2mh5.jpg

    Here's the gist of the relevant code:

    <telerik:RadEditor ID="RadEditor1" Runat="server"
            DialogHandlerUrl="Telerik.Web.UI.DialogHandler.aspx"
            EditModes="All"
            Width="680px"
            Height="400px"
            Language="en-US"
            Skin="Default2006"
            StripFormattingOnPaste="None"
            StripFormattingOptions="None"
            ToolbarMode="Default" >       
            <Content>
            </Content>
            <SpellCheckSettings SpellCheckProvider="PhoneticProvider" WordIgnoreOptions="None"></SpellCheckSettings>
            <Tools>
                <telerik:EditorToolGroup>
                    <telerik:EditorTool Name="UploadDocument" />
                    <telerik:EditorTool Name="UploadImage" />
                    <telerik:EditorTool Name="ImanageLink" />
                    <telerik:EditorTool Name="Bold" />
                </telerik:EditorToolGroup>
            </Tools>       
        </telerik:RadEditor>
       
        <script type="text/javascript">
            Telerik.Web.UI.Editor.CommandList["UploadDocument"] = function(commandName, editor, args)
            {
                var zoneID = '<%= Request["zoneID"] %>';
           
                var UploadDocument_Callback = function(sender, args)
                {
                    if(args.href != "" || args.text != "")
                        editor.pasteHtml(String.format("<a href={0}>{1}</a>", args.href, args.text));               
                }
               
                editor.showDialog("UploadDocument", zoneID, UploadDocument_Callback);
            };
    </script>




     DialogDefinition uploadDocument_DialogDefinition = new DialogDefinition("./Controls/UploadDocument.ascx", new DialogParameters());
                uploadDocument_DialogDefinition.Modal = true;
                uploadDocument_DialogDefinition.VisibleTitlebar = true;
                uploadDocument_DialogDefinition.VisibleStatusbar = true;           
                uploadDocument_DialogDefinition.Width = Unit.Pixel(428);
                uploadDocument_DialogDefinition.Height = Unit.Pixel(440);
    RadEditor1.AddDialogDefinition("UploadDocument", uploadDocument_DialogDefinition);




    ASCX Code:

    <script type="text/javascript">
        function getRadWindow() //mandatory for the RadWindow dialogs functionality
        {
            if (window.radWindow)
            {
                return window.radWindow;
            }
            if (window.frameElement && window.frameElement.radWindow)
            {
                return window.frameElement.radWindow;
            }
            return null;
        }

        function initDialog() //called when the dialog is initialized
        {
            var clientParameters = getRadWindow().ClientParameters; //return the arguments supplied from the parent page
        }
       
        if (window.attachEvent)
        {
            window.attachEvent("onload", initDialog);
        }
        else if (window.addEventListener)
        {
            window.addEventListener("load", initDialog, false);
        }

        function insertLink() //fires when the Insert Link button is clicked
        {
            //create an object and set some custom properties to it
            var closeArgument = {};
            var linkContainer = document.getElementById("linkContainer");
            closeArgument.href = linkContainer.options[linkContainer.selectedIndex].value;
            closeArgument.text = linkContainer.options[linkContainer.selectedIndex].text;

            getRadWindow().close(closeArgument); //use the close function of the getRadWindow to close the dialog and pass the arguments from the dialog to the callback function on the main page.
        }
    </script>


    <div style="width: 390px; height: 405px; background-color: #EEEEEE; font-family: Verdana, Arial; font-size: 8px;">
        <table style="width: 100%; height: 100%;">
            <tr>
                <td style="text-align: center; vertical-align: top; height: 100%;">
                    <fieldset style="width: 375px; height: 200px; text-align: left;">
                        <legend style="font-weight: bold;">Choose Attachment</legend>
                        <br />
                        &nbsp;<asp:ListBox runat="server" ID="lbAttachments" Width="350px" Rows="7"></asp:ListBox>
                        <div style="width: 355px; text-align: right;">
                            <asp:Button runat="server" ID="btnAttach" Text="Attach" BackColor="#D1D1D1"
                                ForeColor="#3333AA" onclick="btnAttach_Click" />
                            <asp:Button runat="server" ID="btnDelete" Text="Delete" BackColor="#D1D1D1"
                                ForeColor="#3333AA" OnClientClick="if(confirm('Delete this File?') == false) { return false; }" onclick="btnDelete_Click" />
                            <asp:Button runat="server" ID="btnCancel" Text="Cancel" BackColor="#D1D1D1"
                                ForeColor="#3333AA" onclick="btnCancel_Click" />
                        </div>
                    </fieldset>
                    <br />
                    <h4>
                        - OR -</h4>
                    <fieldset style="width: 355px; height: 120px; text-align: left; padding-left: 10px;">
                        <legend style="font-weight: bold;">Upload New Attachment</legend>
                        <br />
                        <span style="width: 50px; position: relative; top: -4px;">Title:</span>
                        <asp:TextBox runat="server" ID="txtTitle" Width="289px"></asp:TextBox>
                        <br />
                        <br />
                        <span style="width: 50px; position: relative; top: -4px;">File:</span>
                        <asp:FileUpload runat="server" ID="fileUpload1" Width="216px" /> &nbsp;
                        <asp:Button runat="server" ID="btnUpload" Text="Upload" BackColor="#D1D1D1"
                            ForeColor="#3333AA" Height="22px" onclick="btnUpload_Click" />
                    </fieldset>
                </td>
            </tr>
        </table>
    </div>
    Jordan
    Top achievements
    Rank 1
     answered on 28 Apr 2008
    4 answers
    160 views
    I'm attempting to follow along with the Self-Paced tutorial and the first lab has me stumped.

    I'm getting a page postback when a calendar button is pressed.  Not sure what I'm missing.  Here's the markup:
    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" Height="200px"
                    Width="300px" HorizontalAlign="NotSet">
                    <asp:Calendar id="Calendar1" runat="server" OnSelectionChanged="Calendar1_SelectionChanged"></asp:Calendar>
                    <br />
                    <asp:Label id="lblDateSelected" runat="server" Width="258px"></asp:Label>
                </telerik:RadAjaxPanel>
    Todd Anglin
    Top achievements
    Rank 2
     answered on 28 Apr 2008
    1 answer
    252 views
    If I can control the toolbar button's visibility on the clientside ? I have search in the documents, but I can only find the method to set its state.
    Todd Anglin
    Top achievements
    Rank 2
     answered on 28 Apr 2008
    1 answer
    110 views
    Hi everybody, I need to know how can I make the Ajax request that the Docks fire be cancelled given a certain condition, like the return value (true/false) of a javascript function for example.
    Thanks in advance.
    Jaime
    Top achievements
    Rank 1
     answered on 28 Apr 2008
    2 answers
    164 views
    Hi,

    I have a folder/file application.  I have a treeview inside one panel and a rad grid in another.  the user selects a folder and all files within that folder are displayed.  This works fine, but it seems when i ajaxify the page, i mean i ajaxify the click of the tree to the generation of the grid the execution of the page is very very slow, even locally.  once i take out the ajax management stuff the loads are pretty instance albiet with a postback, am i missing something?? i thought these partial postback were supposed to be better?  Thing is i cant take this stuff out as the treeview is ajaxified for a reason so i can force a rebuild of the tree on certain page events.  I really need to urgently address these speed issues, any ideas?

    Rob
    Todd Anglin
    Top achievements
    Rank 2
     answered on 28 Apr 2008
    Narrow your results
    Selected tags
    Tags
    +? more
    Top users last month
    Jake
    Top achievements
    Rank 1
    RBarnes
    Top achievements
    Rank 1
    Iron
    Iron
    Rami
    Top achievements
    Rank 1
    Iron
    Veteran
    Nathan
    Top achievements
    Rank 1
    Kumeri
    Top achievements
    Rank 1
    Iron
    Veteran
    Iron
    Want to show your ninja superpower to fellow developers?
    Top users last month
    Jake
    Top achievements
    Rank 1
    RBarnes
    Top achievements
    Rank 1
    Iron
    Iron
    Rami
    Top achievements
    Rank 1
    Iron
    Veteran
    Nathan
    Top achievements
    Rank 1
    Kumeri
    Top achievements
    Rank 1
    Iron
    Veteran
    Iron
    Want to show your ninja superpower to fellow developers?
    Want to show your ninja superpower to fellow developers?