Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
109 views
I want to identify images users upload to each individual user.

fr'instance if UserA and UserB uploads images in the ImageManager, I want it so UserA and UserB when using the ImageManager only see's and can edit their own images and not everyone else's. The problem with allowing everyone to upload to a single folder, is everyone can edit/delete/overwrite other users images, and it becomes a management nightmare, fr'instance if I delete a article I also want to know the associated images to that article so I code that they get deleted too.

I've got situations where there will be about 2000-3000 images for particular types of submissions , such as article submissions/ event submissions, ...etc. to create a single folder for each user and submission type may end up with 10 of thousands of folders, I just want a single folder for images for each submission type, eg. a single folder for all article submission images, a single folder for all events images and so on...

What's supprising is the ImageManager SearchPatterns Property seems to work for ViewPaths and DeletePaths but doesn't work for UpLoadPaths, fr'instance:

SearchPatterns="100_*."  - where the 100 is say my userId. In this case when I view the ImageManager it shows only those images
that begin with "100_" (Which is really cool and exactly what I want)

What I've had to do - fr'instance for article submissions is in my form I've added a simple FileUpLoad control that is first hidden, and disabled the ImageManager in RadEditor. The user enter's stuff in the editor and submits (postback), I stored the article data in the database which returns the new articleId, then I set the SearchPatterns property of the ImageManager to equal (articleId+ "_*.*) the user is shown the form again, now with the FileUpLoad control shown and the ImageManager enabled in the RadEditor along with a message on the form " you can now add images to this article" - of course the form will be in edit mode now, so the Submission from this point will be an update not an insert. Now the user can add images via the FileUpLoad where the code will rename the image to "articleId_TheImageFileName" and upload it to the Articles folder, once it does this the user will only see the images added for this article in the ImageManager and can now add them into the RadEditor's text area.

Is there any way to prefix a image name for UploadPaths in the ImageManager?
Dobromir
Telerik team
 answered on 20 Jun 2012
0 answers
112 views
I have a RadGrid which when editing a record opens a Pop-Up edit window. Within the edit window is another RadGrid. What I would like to do is validate that any changes to that embedded grid have been saved prior to allowing the record to be updated. In my ItemCommand "Update" code I can tell if the embedded grid is still in edit mode or not, but I'm not sure how to prevent the Pop-Up edit window from closing. Attached is a picture of my scenario, perhaps that will be easier to understand.

Thanks.
William
Top achievements
Rank 1
 asked on 20 Jun 2012
2 answers
451 views
What I have been trying to accomplish is having a RadGrid calculate its height to fill the rest of a RadPageView of a RadTabStrip/RadMultiPage control. The RadMultiPage should fill what is left of its RadPane, below all other elements that might be above the RadTabStrip. The first time the page is loaded, everything seems to be rendered and sized correctly, however, when resizing the window it seems that only the Grid that is currently visible gets resized, and all the others do not get rendered correctly even though they should all be repainted according to the scripts.

<telerik:RadSplitter ID="InquiryDetailSplitter" runat="server" Orientation="Vertical" OnClientResized="SetElementDimensions"
 OnClientLoaded="SetElementDimensions">
    <telerik:RadPane ID="InquiryDetailFieldsPane" runat="server" Width="300px">
        ...
    </telerik:RadPane>
    <telerik:RadPane ID="InquiryDetailGridsPane" runat="server">
        <asp:Label ID="InquiryDetailPacketGridLabel" runat="server" CssClass="GridLabel" Font-Bold="true" Font-Size="80%"></asp:Label>
        <telerik:RadGrid ID="InquiryDetailPacketGrid" runat="server" ShowFooter="true" AutoGenerateColumns="false" CssClass="AccountGrid"
         OnItemCommand="InquiryDetailPacketGrid_ItemCommand" OnItemDataBound="InquiryDetailPacketGrid_ItemCommand">
            <MasterTableView ClientDataKeyNames="Id" DataKeyNames="Id">
                <Columns>
                    <telerik:GridTemplateColumn HeaderText="View" UniqueName="View" DataField="Id" Aggregate="Count" FooterAggregateFormatString="{0} Accounts" HeaderStyle-Width="85px">
                        <ItemTemplate>
                            <asp:LinkButton ID="ShowDetailLink" runat="server" CommandName="ShowDetail" CommandArgument='<%# Eval("ID") %>' Text="View" />
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                </Columns>
            </MasterTableView>
            <ClientSettings>
                <Scrolling AllowScroll="true" UseStaticHeaders="true" />
            </ClientSettings>
            <FooterStyle HorizontalAlign="Right" />
        </telerik:RadGrid>
 
        <asp:Label ID="InquiryDetailNotesLabel" runat="server" CssClass="GridLabel" Font-Bold="true" Font-Size="80%">Additional information</asp:Label>
 
        <telerik:RadTabStrip ID="InquiryDetailNotesTabStrip" runat="server" MultiPageID="InquiryDetailNotesMultiPage" ShowBaseLine="false" AutoPostBack="false"
         >
            <Tabs>
                <telerik:RadTab Text="Combined" Value="Combined" Visible="false" />
                <telerik:RadTab Text="Transactions" Value="Transactions" Visible="false" />
                <telerik:RadTab Text="Correspondence" Value="Correspondence" Visible="false" />
                <telerik:RadTab Text="Comments" Value="Comments" Visible="false" />
                <telerik:RadTab Text="Miscellaneous" Value="Misc" Visible="false" />
                <telerik:RadTab Text="Online Activity" Value="OnlineActivity" />
                <telerik:RadTab Text="Attachments" />
            </Tabs>
        </telerik:RadTabStrip>
 
        <telerik:RadMultiPage ID="InquiryDetailNotesMultiPage" runat="server" SelectedIndex="0">
            <telerik:RadPageView ID="CombinedPageView" runat="server" Visible="false" Height="100%">
                <telerik:RadGrid ID="InquiryDetailCombinedGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%" >
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="NoteDateTime" DataFormatString="{0:g}" UniqueName="NoteDateTime" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridBoundColumn HeaderText="Text" DataField="Text" UniqueName="Text" AllowSorting="false" />
                            <telerik:GridBoundColumn HeaderText="Collector" DataField="Collector" UniqueName="Collector" HeaderStyle-Width="100px" Visible="false" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="TransactionsPageView" runat="server" Visible="false" Height="100%">
                <telerik:RadGrid ID="InquiryDetailTransactionsGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="NoteDateTime" DataFormatString="{0:g}" UniqueName="NoteDateTime" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridBoundColumn HeaderText="Text" DataField="Text" UniqueName="Text" AllowSorting="false" />
                            <telerik:GridBoundColumn HeaderText="Collector" DataField="Collector" UniqueName="Collector" HeaderStyle-Width="100px" Visible="false" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="CorrespondencePageView" runat="server" Visible="false" Height="100%">
                <telerik:RadGrid ID="InquiryDetailCorrespondenceGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn  HeaderText="Date/Time" DataField="NoteDateTime" DataFormatString="{0:g}" UniqueName="NoteDateTime" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridBoundColumn HeaderText="Text" DataField="Text" UniqueName="Text" AllowSorting="false" />
                            <telerik:GridBoundColumn HeaderText="Collector" DataField="Collector" UniqueName="Collector" HeaderStyle-Width="100px" Visible="false" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="CommentsPageView" runat="server" Visible="false" Height="100%">
                <telerik:RadGrid ID="InquiryDetailCommentsGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="NoteDateTime" DataFormatString="{0:g}" UniqueName="NoteDateTime" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridBoundColumn HeaderText="Text" DataField="Text" UniqueName="Text" AllowSorting="false" />
                            <telerik:GridBoundColumn HeaderText="Collector" DataField="Collector" UniqueName="Collector" HeaderStyle-Width="100px" Visible="false" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="MiscellaneousPageView" runat="server" Visible="false" Height="100%">
                <telerik:RadGrid ID="InquiryDetailMiscellaneousGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="NoteDateTime" DataFormatString="{0:g}" UniqueName="NoteDateTime" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridBoundColumn HeaderText="Text" DataField="Text" UniqueName="Text" AllowSorting="false" />
                            <telerik:GridBoundColumn HeaderText="Collector" DataField="Collector" UniqueName="Collector" HeaderStyle-Width="100px" Visible="false" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="OnlineActivityPageView" runat="server" Height="100%">
                <telerik:RadGrid ID="InquiryDetailOnlineActivityGrid" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="Date" DataFormatString="{0:g}" UniqueName="OnlineActivityDate" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridTemplateColumn HeaderText="Activity" UniqueName="Activity">
                                <ItemTemplate>
                                    <%# AccountActionType((IAccountAction)Container.DataItem)%>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn HeaderText="User" DataField="UserFullName" UniqueName="UserFullName" />
                            <telerik:GridBoundColumn HeaderText="Details" DataField="Details" UniqueName="Details" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
            <telerik:RadPageView ID="AttachmentsPageView" runat="server" Height="100%">
                <telerik:RadGrid ID="InquiryDetailAttachments" runat="server" AutoGenerateColumns="false" Height="100%">
                    <MasterTableView Height="100%">
                        <Columns>
                            <telerik:GridBoundColumn HeaderText="Date/Time" DataField="UploadDate" DataFormatString="{0:g}" UniqueName="UploadDate" DataType="DateTime" HeaderStyle-Width="130px" />
                            <telerik:GridTemplateColumn HeaderText="Name" UniqueName="Name">
                                <ItemTemplate>
                                    <%# AttachmentLink((CawFile)Container.DataItem) %>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn HeaderText="File Size" DataField="FormattedFileSize" UniqueName="FormattedFileSize" />
                        </Columns>
                    </MasterTableView>
                    <ClientSettings>
                        <Scrolling AllowScroll="true" UseStaticHeaders="true"/>
                    </ClientSettings>
                </telerik:RadGrid>
            </telerik:RadPageView>
        </telerik:RadMultiPage>
    </telerik:RadPane>
</telerik:RadSplitter>
 
<telerik:RadScriptBlock ID="GridDimensionScriptBlock" runat="server">
    <script type="text/javascript">
 
        // this function will set the MultiPage dimensions and then for every PageView in the MultiPage,
        // the nested RadGrid within the PageView will be redrawn to fulfill the new CSS rules.
        function SetElementDimensions(sender, args) {
 
            // set the dimensions according to the new window size
            var setHeight = SetMultiPageDimensions();
 
            // get the multi page control to interate through the page views
            var telerikMultiPage = $find("<%= InquiryDetailNotesMultiPage.ClientID %>");
            var pageCollection = telerikMultiPage.get_pageViews();
 
            // iterate the page views
            for (var i = 0; i != pageCollection._data.length; ++i) {
                var pageIteration = pageCollection._data[i];
                // check the size on the Page View element to make sure that it is sized at 100
                var pageElement = $("#" + pageIteration._element.id);
                pageElement.height(setHeight);
 
                // if the page has children, use them to select the grid by its id and set rgDataDiv height
                if (pageIteration._element.children.length > 0) {
                    var nestedGridId = pageIteration._element.children[0].id;
                    var nestedGrid = $find(nestedGridId);
                    $("#" + nestedGridId).height(setHeight);
                    nestedGrid.repaint();
                }
            }
 
        }
 
        // Calculates and sets the height of the MultiPage element. This is accomplished by getting the top offset of the tabStrip and the
        // height of the tabStrip. These dimensions are then added together and subtracted from the height of the splitter itself for
        // the needed difference.
        function SetMultiPageDimensions(sender, args) {
            // get overall height available
            var splitterDivHeight = $("#" + "<%= InquiryDetailSplitter.ClientID %>").height();
            var tabStripDiv = $("#" + "<%= InquiryDetailNotesTabStrip.ClientID %>");
 
            // figure out the offset of the tab strip, and the height of the tabStrip to use in calculating available space
            // additional two: one for border and one for extra space
            var topOffset = tabStripDiv.offset().top + tabStripDiv.height() + 2;
 
            var additionalInfoMultiPageDiv = $("#" + "<%= InquiryDetailNotesMultiPage.ClientID %>");
 
            var heightToSet = splitterDivHeight - topOffset;
 
            additionalInfoMultiPageDiv.height(heightToSet);
 
            return heightToSet;
        }
    </script>
</telerik:RadScriptBlock>
Pavlina
Telerik team
 answered on 20 Jun 2012
8 answers
831 views
Hi,

I need to change the position of the RadDatePicker popup to be slightly above where it opens up as default.

I've found the example for ShowPopupAbove which works OnKeyPress but I can't for the life of me get it to work when the DatePopupButton is clicked.

Could someone please point out what event I need to use? I tried this (and 100 other combinations) with no success:

                        <telerik:RadDatePicker ID="RadDatePicker1" Width="110" runat="server">                             
                            <DatePopupButton OnClick="ShowPopupAbove" />                             
                        </telerik:RadDatePicker> 

Maria Ilieva
Telerik team
 answered on 20 Jun 2012
11 answers
171 views
Can anyone tell me how to change the RAD Editor so the content is displayed from right to left?

Many thanks
Rumen
Telerik team
 answered on 20 Jun 2012
3 answers
163 views
Anyone has a list of languages supported by RadEditor?
Rumen
Telerik team
 answered on 20 Jun 2012
5 answers
97 views
I need to inspect the html returned from the ImageProperties dialog. I am attempting to use the OnClientPasteHtml function to handle this but it is not getting fired when I use the dialog. The html is beign updated but the event doesn't get fired. It is getting fired properly form the ImageManager,Hyperlink dialog,etc. but not the ImageProperties dialog.

function OnClientPasteHtml(editor, args)  
{  
    alert(args.get_commandName());  
}  
 
   <telerik:RadEditor ID="HtmlContent" runat="server" Width="100%" Height="350px" EditModes="Design, Html" OnClientPasteHtml="OnClientPasteHtml" 
        ToolsFile="/Portal/config/ToolsFile.xml" ContentFilters="IndentHTMLContent" AutoResizeHeight="false" 
        StripAbsoluteImagesPaths="true" Skin="WebBlue">  
        <ImageManager EnableImageEditor="false" /> 
         
    </telerik:RadEditor> 
Rumen
Telerik team
 answered on 20 Jun 2012
0 answers
57 views
I'm try to use the plugin flippy and i have a problem. For this plugin work fine on ie, i have to load the excanvas.js script file. The problem is that i have already loaded the plugin on the page but when the plugin is call by telerik, he can't regonigze the  G_vmlCanvasManager. I follow the intructions  here but uncessfull. Can anyone help me please?

Thanks!
Artur
Top achievements
Rank 1
 asked on 20 Jun 2012
1 answer
145 views

Parser Error

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. 

Parser Error Message: Could not load file or assembly 'DotNetNuke.HtmlEditor.TelerikEditorProvider' or one of its dependencies. The system cannot find the file specified.

Source Error: 

Line 4:  <%@ Register Assembly="Telerik.Web.UI, Version=2011.03.1115.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI.Dialogs" TagPrefix="dialogs" %>
Line 5:  <%@ Register Assembly="Telerik.Web.UI, Version=2011.03.1115.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
Line 6:  <%@ Register Assembly="DotNetNuke.HtmlEditor.TelerikEditorProvider" Namespace="DotNetNuke.HtmlEditor.TelerikEditorProvider" TagPrefix="provider" %>
Line 7:  
Line 8:  <% if(this.Request.IsSecureConnection) { %>

Source File: /Telerik.Web.UI.DialogHandler.axd    Line: 

Assembly Load Trace: The following information can be helpful to determine why the assembly 'DotNetNuke.HtmlEditor.TelerikEditorProvider' could not be loaded.

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.272
 

Hi,

I am new to telerik controls and having hard time fixing the Link Manager on Rad Editor .
I have below configurations:
 <telerik:RadEditor ID="txtStory" runat="server" Width="99%" Height="670" AllowScripts="True" TabIndex="3"
                        ToolbarMode="Default" DialogHandlerUrl="~/Telerik.Web.UI.DialogHandler.axd"
                        OnClientLoad="OnClientLoad" EnableEmbeddedSkins="false" Skin="PrestoRadSkin"
                        NewLineMode="P" ContentFilters="ConvertToXhtml" OnClientModeChange="OnClientModeChange" ExternalDialogsPath="~/DesktopModules/UDMW/ContentDashboard/Telerik/Dialogs/" >
                        
<Tools>
<telerik:EditorToolGroup Tag="SubToolbar">                              
                                <telerik:EditorTool Name="LinkManager" ShortCut="CTRL+K" />
                                <telerik:EditorTool Name="Unlink" ShortCut="CTRL+SHIFT+K" />
</telerik:EditorToolGroup>
</Tools>

and my web.config:
<httpHandlers> 
<add path="Telerik.Web.UI.DialogHandler.axd" verb="*" type="Telerik.Web.UI.DialogHandler, Telerik.Web.UI" validate="false"/>
    </httpHandlers>

<handlers>    
      <add name="Telerik_Web_UI_DialogHandler_aspx" path="Telerik.Web.UI.DialogHandler.axd" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode" />
    </handlers>

I googled a lot for resolving this.

Any help is appreciated.

Thanks,
Rad
Rumen
Telerik team
 answered on 20 Jun 2012
1 answer
96 views
Hi,

I have two comboboxes. I need to expand the second only if I select a particular value in the first.

Thanks
Shinu
Top achievements
Rank 2
 answered on 20 Jun 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?