Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
158 views
This is my code for rad Editor ,

<telerik:RadEditor ID="RadEditor1Content" runat="server" AutoResizeHeight="True"
Width="500px" ToolbarMode="Floating">
<Content>
</Content>
<ImageManager EnableAsyncUpload="True" ViewPaths="~/images" UploadPaths="~/images" MaxUploadFileSize="900000000"/>
<MediaManager EnableAsyncUpload="true" ViewPaths="~/media" UploadPaths="~/media"  MaxUploadFileSize="900000000"/>
<TrackChangesSettings CanAcceptTrackChanges="False"></TrackChangesSettings>

When I insert video or song file using "MediaManager" , html view of rad Editor shows likes

<object height="150" width="150" type="application/x-oleobject"
classid="clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6">
<param name="URL" value="/media/MySongFile.mp3"><embed src="/media/MySongFile.mp3"
 type="application/x-mplayer2"
pluginspage="http://www.microsoft.com/Windows/MediaPlayer" width="150" height="150">

It shows my uploaded file(mp3) with MediaPlayer which can be play . I don't want to show likes this . I just want to show Download Link to download my uploaded file . How can I do that ?
Ivaylo
Telerik team
 answered on 20 Jun 2013
1 answer
83 views
Hi All, 

I've a very strange problem. While I'm trying upload a picture in chrome, firefox and ie 9,  I can upload it successfully.
But When I use IE8 to upload exactly the samefile with same code, I get "LOG: Server response: Error trying to get server response: Error: Permission denied"  error. Is there any one who can tell me what is the broblem? Many thanks in advance..

Sincerely,
alper


Alper
Top achievements
Rank 1
 answered on 20 Jun 2013
2 answers
107 views
Hi,

Using CTRL+SHIFT+V in Chrome is supposed to paste without formatting.
Prior to the latest release, this worked.

With this latest release, if I copy, for example, a grid row that has an alternating color and then CTRL+SHIFT+V into RadEditor, it carries the color over into the RadEditor.

Was this an intentional change?
Ivaylo
Telerik team
 answered on 20 Jun 2013
1 answer
330 views
Hi,

I have a scenario where I need to set the visibility of a radgrid on page load however I am not able to get the radgrid client side object. Please look at the code below:

$(function () {          
      var grid = $find("<%=RgTabularView.ClientID%>");     
      alert(grid);
      if (grid != null) {           
      }
   });

It always returns null.
Shinu
Top achievements
Rank 2
 answered on 20 Jun 2013
2 answers
132 views
i decided to create a brand new Web Application to test the RadTileList out.
Here is my HTML code:

  <form id="form1" runat="server"><br>   <br>         <div><br>        <asp:ScriptManager runat="server" ></asp:ScriptManager><br>             <%--TODO: what does the radFormDecorator do?--%><br>        <telerik:RadFormDecorator runat="server" DecoratedControls="All" EnableRoundedCorners="true" /><br><br>        <telerik:RadTileList runat="server" ID="Tiley" SelectionMode="Single" EnableDragAndDrop="true"><br>            <Groups><br>                <telerik:TileGroup><br>                    <br>                    <telerik:RadImageTile runat="server" Title-Text="Title-Text_Fruit" ImageUrl="http://t0.gstatic.com/images?q=tbn:ANd9GcSICYQ_b6umFy_RAnxSmzoHVqTY3J9l1bWw8bCIJIOiR83x993tqw"><br>                        <Title Text="Title_Fruit"></Title><br>                        <PeekTemplateSettings  Animation="Slide" ShowPeekTemplateOnMouseOver="true" HidePeekTemplateOnMouseOut="true"  /> <br>                        <%-- ShowInterval="1000" CloseDelay="700" AnimationDuration="600"  --%> <%--use these to peek automatically--%><br>                        <PeekTemplate><br>                            <asp:Label runat="server" Text="Have Some Fruit"></asp:Label>                        <br>                            <asp:Image runat="server" ID="Fruit_Ninja" AlternateText="FruityNinja" ImageUrl="http://t0.gstatic.com/images?q=tbn:ANd9GcS7CGpWMAzces6nrxzNfhfYYJFI9xROuIn794iJKPNBWtIoyUDm" /><br>                        </PeekTemplate><br>                    </telerik:RadImageTile><br>                   <br>                    <telerik:RadImageTile runat="server" Title-Text="Title-Text_Meat" ImageUrl="http://www.glenvillepacking.com/files/Raw-Meat-1.jpg" Shape="Wide"><br>                        <Title Text="Title_Meat"></Title><br>                        <PeekTemplateSettings Animation="Fade" ShowPeekTemplateOnMouseOver="true" HidePeekTemplateOnMouseOut="true" /><br>                        <PeekTemplate><br>                            <asp:Label runat="server" Text="Meeat"></asp:Label><br>                            <asp:Image Width="100%" runat="server" ID="Meat_Boy" AlternateText="MeatBoy" ImageUrl="http://www.onlinegames.cat/wp-content/uploads/2011/11/super-meat-boy-main.jpg" /><br>                        </PeekTemplate><br>                    </telerik:RadImageTile><br>                   <br>                </telerik:TileGroup><br>                <telerik:TileGroup ><br>                    <telerik:RadIconTile runat="server" ImageUrl="~/Images/cloud.png" Shape="Wide" ><br>                        <Title Text="Lightbulb"></Title><br>                        <br>                    </telerik:RadIconTile><br>                </telerik:TileGroup><br>            </Groups><br>            <br>        </telerik:RadTileList><br>    </div><br>    </form>

the ImageURL points to an image that i have in my Web Application, but when running the program it doesn't show the image. It just shows a blank square with a black X in the middle.
i've tried png and ico images but no luck. is there something simple that i'm missing?

thanks for your help
David
Top achievements
Rank 1
 answered on 20 Jun 2013
2 answers
294 views
Hi

I have and issue regarding the scrollbar position. As you can see in the code below i have the radtreeview inside the radlistbox and il would like that when i click on the node, the scrollbar scrolls to the selected node position.

<asp:Panel ID="Panel2" runat="server">
    <telerik:RadListBox ID="RadListBox1" runat="server" Height="200" Width="250"
                        AllowTransfer="true" ButtonSettings-Position="Right"
                        ButtonSettings-TransferButtons="All" TransferMode="Copy"
                        SelectionMode="Multiple" TransferToID="rlbDealers"
                        AutoPostBackOnTransfer="true" CausesValidation="false"
                        OnTransferred="rlbListAvailable_Transferred">
        <ItemTemplate>
            <div>
                <telerik:RadTreeView ID="rtvDealersAvailable" runat="server"
                                     OnLoad="rtvDealersAvailable_Load"
                                     MultipleSelect="true"
                                     OnClientNodeClicked="selectFatherAndChildNodes">
                </telerik:RadTreeView>
            </div>
        </ItemTemplate>
        <Items>
            <telerik:RadListBoxItem />
        </Items>
    </telerik:RadListBox>
    <telerik:RadListBox ID="RadListBox2" runat="server" SelectionMode="Multiple"
                        Height="200" Width="250">
    </telerik:RadListBox>
</asp:Panel>

Shinu
Top achievements
Rank 2
 answered on 20 Jun 2013
1 answer
36 views
When process data in DropdownTree, need add method get ParentofNodeValue,ChildOfNodeValue.
Kate
Telerik team
 answered on 20 Jun 2013
2 answers
336 views
Hello,

I'm having an issue with a radgrid that populates data from a linq query.  The grid uses an OnItemDataBound and OnItemCommand method.

Looking at the page source after being compiled, the viewstate looks absolutely massive, as if the grid is trying to stick the binary file in the viewstate somehow.

I tried increasing the size of the maxJsonLength through web.config to no avail.

The specific error is:

Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property.

I'm uploading a file, and then clicking back to a page that rebinds the radgrid containing an attachment column which triggers the onitemcommand method. 

Thanks ahead of time.


ASPX:

<telerik:RadGrid ID="procGrid" runat="server" AutoGenerateColumns="False" 
                    CellSpacing="0" GridLines="None" onneeddatasource="procGrid_NeedDataSource" OnItemDataBound="grdProcedures_ItemDataBound2" OnItemCommand="grdFiles_ItemCommand">
<MasterTableView>
<CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
  
<RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
  
<ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
  
    <Columns>
        <telerik:GridBoundColumn FilterControlAltText="Filter column column" 
            UniqueName="column" DataField="name" HeaderText="Name">
            <ItemStyle Width="400px" />
        </telerik:GridBoundColumn>
        <telerik:GridBoundColumn DataField="Id" 
            FilterControlAltText="Filter column1 column" UniqueName="column1">
        </telerik:GridBoundColumn>
        <telerik:GridHyperLinkColumn AllowSorting="False" 
            FilterControlAltText="Filter column2 column" UniqueName="column2" 
            HeaderText="Review">
            <ItemStyle Width="100px" />
        </telerik:GridHyperLinkColumn>
                    <telerik:GridAttachmentColumn FileName="attachment" 
                        FilterControlAltText="Filter procedure_document column" HeaderText="Procedures" 
                        UniqueName="procedure_document"
                        AttachmentDataField="procedure_document" 
                        AttachmentKeyFields="procedure_document" 
                        Text="View Procedure" >
                         
                    </telerik:GridAttachmentColumn>
    </Columns>
  
<EditFormSettings>
<EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
</EditFormSettings>
</MasterTableView>
  
<FilterMenu EnableImageSprites="False"></FilterMenu>
  
<ClientSettings EnablePostBackOnRowClick="true">
  
  
</ClientSettings>
                </telerik:RadGrid>


CS:


protected void grdProcedures_ItemDataBound2(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
    if (e.Item is GridDataItem)
    {
        GridDataItem item = (GridDataItem)e.Item;
        string ProcId = item["column1"].Text;
        HyperLink link = (HyperLink)item["column2"].Controls[0];
        link.Text = "Edit Procedure";
        string url = "~/procedure.aspx?AuditType=" + AuditType + "&AuditID=" + AuditID + "&StandardID=" + StandardID + "&ProcedureID=" + ProcId;
        link.NavigateUrl = url;
    }
}
protected void grdFiles_ItemCommand(object source, GridCommandEventArgs e)
{
    if (e.CommandName == RadGrid.DownloadAttachmentCommandName)
    {
        using (var db = new isoAuditModelContainer())
        {
            RadAjaxManager Manager = new RadAjaxManager();
            Manager.EnableAJAX = false;
            GridDownloadAttachmentCommandEventArgs args = e as GridDownloadAttachmentCommandEventArgs;
            GridDataItem item = (GridDataItem)e.Item;
            string fileName = args.FileName;
            string ProcId = item["column1"].Text;
            int ProcId2 = Convert.ToInt16(ProcId);
            //int attachmentId = (int)args.AttachmentKeyValues["procedure_document"];
            var query = (from x in db.procedures where x.Id == ProcId2 select x).First();
            string extension = query.file_extension;
            byte[] binaryData = (byte[])query.procedure_document;
            Response.Clear();
            //Response.ContentType = query.fileExtension;
            Response.AddHeader("content-disposition", "attachment; filename=" + fileName + extension);
            Response.BinaryWrite(binaryData);
            Response.OutputStream.Write(binaryData, 0, binaryData.Length);
            Response.Flush();
            Response.Close();
            Response.End();
        }
    }
}






Kostadin
Telerik team
 answered on 20 Jun 2013
4 answers
890 views
I have a complex RadGrid with many columns and filters on all the columns. As the use can end up with a complex set of filter I want to add a 'clear all filters' button. As it is a parent/detail grid I figured I would use the space next to the filters created by the expand/collapse column. So I managed to 'successfully' put a new image button in that space with the following code which I have in my Grid ItemDataBound method..

// Creating filtering row clear all filters button
if ((e.Item.ItemType == GridItemType.FilteringItem))
{
    var clearFilterButton = new RadButton
    {
        ButtonType = RadButtonType.StandardButton,
        Height = 22,
        Width = 22
    };
 
    clearFilterButton.Image.EnableImageButton = true;
    clearFilterButton.Image.ImageUrl = string.Format("../App_Themes/{0}/Images/ClearFilter.png", Page.Theme);
    clearFilterButton.ToolTip = "Clear current filter(s)";
    clearFilterButton.Click += ClearButton_Click;
 
    var expandCollapseColumn = (GridTableCell) e.Item.Controls[0];
    expandCollapseColumn.Controls.Add(clearFilterButton);
}

I'm assuming I have this all wrong as I have two problems.
1) Clicking the button makes it disappear
2) Clicking the button never fires the clearbutton event.

Can anyone help and maybe this should be a feature in the RadGrid control in the future?

Thanks

Colin
ColinBlakey
Top achievements
Rank 2
 answered on 20 Jun 2013
1 answer
207 views
I have an old project built with ASP.NET 2.0. It is a Website project and the upgrade wizard menu is not available.
When using "Convert to Telerik site" it is not possible to select the current project to be upgraded, there is no entry and manually browsing to the project's root directory is not accepted.

I tried this tutorial: http://www.telerik.com/support/kb/aspnet-ajax/general/updating-radcontrols-for-asp-net-to-another-version-or-license.aspx
However in step 5 ("From the newly downloaded and unzipped files, copy the new DLL ...") it becomes confusing. In my project's bin folder are many files like RadEditorNet2.dll and so on, but in the downloaded hotfix in the folder bin45 I can just find 3 files (Telerik.Web.UI etc.), that are not present in the old project's folder, so I can't replace anything.

Furthermore I copied these 3 files in my project's bin folder and I added them as reference. After setting the target framework to 4.5 it compiled successfully. Now I think, that I have to change all old tags like <prefix:RadEditor2Net ...> to <prefix:RadEditor>.

Is this the right way or do you know any other solution?
Biliana Ficheva
Telerik team
 answered on 20 Jun 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?