Telerik Forums
UI for ASP.NET AJAX Forum
9 answers
113 views
Hi,

The PivotGrid is a great component but I'm confused how I gain a little more control over the display.

We'd like to be able to have specific rows (and maybe columns) collapsed when the component first loads.
I've found ways to collapse everything but not by ID.

Is this possible?

Cheers

Gordon


Maria Ilieva
Telerik team
 answered on 28 Mar 2014
2 answers
309 views
I have an application that will exist on one iis server but I want it to display files from a shared drive on a separate server.  The other issue is I only want to display subfolder based on the user and what the users has selected to view. They will be read only for the directory

​string jobId = Request.QueryString["jobId"];
string path = @"\\servernamel\FileManager\" + jobId + @"\subfolder\";
string[] folder = { path };
RadFileExplorer1.Configuration.ViewPaths = folder;
RadFileExplorer1.Configuration.SearchPatterns = new[] { "*.*" };
RadFileExplorer1.Configuration.ContentProviderTypeName = typeof(CustomFileSystemProvider).AssemblyQualifiedName;

I have followed the link
http://www.telerik.com/support/kb/aspnet-ajax/fileexplorer/details/use-radfileexplorer-with-physical-and-shared-folder-s-paths

but I have had no success in displaying the files in the shared folder.

I am assuming I have to change the MappingFile.mapping to
<?xml version="1.0" encoding="utf-8" ?>
<CustomFileBrowserProvider>
<Paths>
<genericHandlerPath>FileSystemHandler.ashx</genericHandlerPath>
</Paths>
<Mappings>
<Mapping>
<PhysicalPath>
<![CDATA[\\servername\FileManager\"]]>
</PhysicalPath>
<VirtualPath><![CDATA[MyCusomRootDir/]]></VirtualPath>
</Mapping>
</Mappings>
</CustomFileBrowserProvider>


Vessy
Telerik team
 answered on 28 Mar 2014
4 answers
73 views
Hello,

I am using a grid which includes two radDatePicker in the row. The grid displays 25 items per page. I am using a shared calendar but it seems that the script is taking too long in IE8.

Could you tell me what would be the best way to improve the performance of my grid?

Here it is:

<telerik:RadGrid ID="radGrid" runat="server"
    OnNeedDataSource="NeedDataSource" 
    OnItemDataBound="ItemDataBound" 
    OnUpdateCommand="UpdateCommand" 
    OnItemCreated="ItemCreated"
    OnItemCommand="ItemCommand" 
    AllowSorting="true" AllowPaging="true" AutoGenerateColumns="false" AllowMultiRowSelection="false" 
    PagerStyle-Mode="NumericPages" PagerStyle-AlwaysVisible="true" ShowFooter="true" PageSize="10"
    MasterTableView-NoMasterRecordsText="No Records found.">
    
    <ClientSettings EnableRowHoverStyle="true" AllowColumnsReorder="false">
        <Selecting AllowRowSelect="true" />
        <Resizing AllowColumnResize="false" EnableRealTimeResize="false" />
    </ClientSettings>
    
    <MasterTableView ShowHeadersWhenNoRecords="true" TableLayout="fixed" 
        EditMode="EditForms" Width="100%" CommandItemDisplay="Top">
        
        <EditFormSettings EditFormType="WebUserControl" UserControlName="/UserControl/Grid/Edit.ascx">
                <EditColumn UniqueName="EditCommandColumn1"></EditColumn>
        </EditFormSettings>
        
        <CommandItemTemplate>
            <table style="width:100%">
                <tr>
                    <td style="width:100%; text-align:right;">
                        <asp:LinkButton ID="lbRefresh" runat="server" CommandName="Refresh">
                            <img style="border:0px; padding-right:5px;" alt="" src="/RadControls/Skin/Grid/Refresh.gif" />Refresh
                        </asp:LinkButton>
                    </td>
                </tr>
            </table>
        </CommandItemTemplate>

        <Columns>
            <telerik:GridBoundColumn UniqueName="Col1" DataField="Col1" HeaderTooltip="Col1"
                ItemStyle-HorizontalAlign="Left" SortExpression="Col1" 
                HeaderText="Col1" HeaderStyle-Width="6%">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn UniqueName="Col2" DataField="Col2" AllowSorting="false" HeaderTooltip="Col2"
                HeaderText="Col2" HeaderStyle-Width="8%" ItemStyle-HorizontalAlign="Left">
            </telerik:GridBoundColumn>
            <telerik:GridEditCommandColumn UniqueName="Col3" HeaderTooltip="Col3"
                HeaderText="Col3" HeaderStyle-Width="10%" ItemStyle-HorizontalAlign="Left">
            </telerik:GridEditCommandColumn>
            <telerik:GridBoundColumn UniqueName="Col4" DataField="Col4" HeaderTooltip="Col4"
                ItemStyle-HorizontalAlign="Left" SortExpression="Col4" 
                HeaderText="Col4" HeaderStyle-Width="10%">
            </telerik:GridBoundColumn>
            <telerik:GridTemplateColumn UniqueName="Col5" DataField="Col5" HeaderTooltip="Col5"
                ItemStyle-HorizontalAlign="Left" SortExpression="Col5" 
                HeaderText="Col5" HeaderStyle-Width="4%">
                <ItemTemplate>
                     <a target="_blank" href='<%# myFunction(Eval("Col5").ToString())%>'></a>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridBoundColumn UniqueName="Col6" DataField="Col6" HeaderTooltip="Col6" 
                ItemStyle-HorizontalAlign="Left" SortExpression="Col6" 
                HeaderText="Col6" HeaderStyle-Width="15%">
            </telerik:GridBoundColumn>

            <telerik:GridTemplateColumn UniqueName="Col7" HeaderTooltip="Col7" DataField="Col7"
                ItemStyle-HorizontalAlign="Left" SortExpression="Col7" 
                HeaderText="Col7" HeaderStyle-Width="13%">
                <ItemTemplate>
                    <telerik:RadDatePicker id="rpd1" Runat="server"  OnSelectedDateChanged="dateChanged" ShowPopupOnFocus="false" SharedCalendarID="sharedCalendar"
                        Width="98px" AutoPostBack="true" ZIndex="0" Calendar-EnableMonthYearFastNavigation="false">
                        <DateInput ReadOnly="true" ToolTip="Click on the calendar to set up a new date" ></DateInput>
                    </telerik:RadDatePicker>
                    <asp:Label id="lb1" runat="server"></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>

            <telerik:GridTemplateColumn UniqueName="Col8" HeaderTooltip="Col8" DataField="Col8"
                ItemStyle-HorizontalAlign="Left" SortExpression="Col8" 
                HeaderText="Maturity Col8" HeaderStyle-Width="13%">
                <ItemTemplate>
                    <telerik:RadDatePicker id="rdp2" Runat="server"  OnSelectedDateChanged="dateChanged" ShowPopupOnFocus="false" SharedCalendarID="sharedCalendar"
                        Width="98px" AutoPostBack="true" ZIndex="0" Calendar-EnableMonthYearFastNavigation="false">
                        <DateInput ReadOnly="true" ToolTip="Click on the calendar to set up a new date" ></DateInput>
                    </telerik:RadDatePicker>
                    <asp:Label id="lb2" runat="server"></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
         
        </Columns>
        
       <PagerTemplate>
        </PagerTemplate>

    </MasterTableView>
    
</telerik:RadGrid>












Greg
Top achievements
Rank 1
 answered on 28 Mar 2014
3 answers
250 views
Hello,

I am using multiple RadNumericTextBoxes on a page would like to Validate that the user can only input in half increments.

For example: 0.5, 1.0, 1.5, 2.0, 2.5... ect.

I have tried using the <IncrementSettings Step="0.5" /> property on the RadNumericTextBox but have only achieved a Scroll/Arrow key Increment. This also did not stop the user from initially entering a foreign value (ex. 6.2).
Is there a property on RadNumericTextBox which will achieve this?

Best Regards,

Landon

Vasil
Telerik team
 answered on 28 Mar 2014
2 answers
235 views
Hello,

I've encountered some surprising behaviour with the RadAutoCompleteBox.Entries property during the implementation of a custom DataSourceSelect event.  Unless I also implement the EntryAdded and EntryRemoved events, the items added to or removed from the box by the user do not show up in the Entries collection of the control in the DataSourceSelect event handler.

I have an AutoCompleteBox defined as follows:
<telerik:RadAutoCompleteBox ID="titles" runat="server" InputType="Token" TokensSettings-AllowTokenEditing="false" DataTextField="Title" DataValueField="TitleID" OnDataSourceSelect="titles_DataSourceSelect" OnEntryAdded="titles_EntryAdded" Width="400px"></telerik:RadAutoCompleteBox>

I have a method that queries my back end database with the text entered by the user and sets the data source.  Before querying the database, I get the items that have already been added to the control and include their IDs in the database queries, so that they can be filtered out of the drop down of matches.  In other words, if a user has types in text, picked an item form the dropdown and added it to the control, I ensure that the same item does not appear again in the dropdown.

        protected void titles_DataSourceSelect(object sender, AutoCompleteBoxDataSourceSelectEventArgs e)<br>        {<br>            List<int> exclude = new List<int>();<br>            foreach (AutoCompleteBoxEntry entry in titles.Entries)<br>            {<br>                int id = -1;<br>                if (int.TryParse(entry.Value, out id))<br>                {<br>                    exclude.Add(id); <br>                }<br>            }<br><br>            titles.DataSource = Database.SearchDimension("Title", e.FilterString, exclude); // call DAL<br>        }<br>

I have put a RadAjaxManager on the page and given the AutoCompleteBox the ability to ajaxically update itself.
         <telerik:AjaxSetting AjaxControlID="titles">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="titles" UpdatePanelRenderMode="Inline" />
                </UpdatedControls>
             </telerik:AjaxSetting>

But the above doesn't work.  When my DataSourceSelect event handler fires, the Entries collection of the control is always empty.

If I implement empty event handlers for EntryAdded and EntryRemoved, it works as expected, and the Entries collection contains the items which have been previously selected by the user.

<telerik:RadAutoCompleteBox ID="titles" runat="server" InputType="Token" TokensSettings-AllowTokenEditing="false" DataTextField="Title" DataValueField="TitleID" OnDataSourceSelect="titles_DataSourceSelect" OnEntryAdded="titles_EntryAdded" OnEntryRemoved="titles_EntryRemoved" Width="400px"></telerik:RadAutoCompleteBox>

        protected void titles_EntryAdded(object sender, AutoCompleteEntryEventArgs e)<br>        {<br>        }<br><br>        protected void titles_EntryRemoved(object sender, AutoCompleteEntryEventArgs e)<br>        {<br>        }

If I eliminate either one of these two event handlers, the corresponding action is not taken into account in the Entries collection.  So if I remove EntryAdded, items I add to the control are not taken into account.  If I remove EntryRemoved, when I add and then remove an item, it still shows up in the Entries collection.

On a full page postback triggered by something else, the Entries collection always correctly lists items really entered in the web form.

I am running this in a SharePoint 2010 custom Application page.

This looks like a bug to me, but maybe I've misunderstood the API for this control and am not using it correctly.



Nencho
Telerik team
 answered on 28 Mar 2014
2 answers
404 views
Hi,

I've been reading through your help doc and also searched through the forum on how to pass parameter from one user control (UC1) to another user control (UC2), but still not quite getting it, hopefully you could help me understand it better.

I created a small project as below:

My aspx page contains UC1 (a grid) and UC2 (a textbox).  When UC1 gets clicked, it'll get the location id and I need to pass that value to UC2 to display it.
RadAjaxManager is on the aspx page and RadAjaxManagerProxy is set up in each user controls.

The closest I can find is this from your help doc :

http://www.telerik.com/help/aspnet-ajax/ajax-load-control-from-another-webusercontrol-in-different-masterpage-contentplaceholder.html

Is this the way I should follow to send data from one user control to another by using bubble event or is there another way you would recommend?

Thank you,

Helen
Helen
Top achievements
Rank 1
 answered on 28 Mar 2014
1 answer
184 views
Hi,

I have a radGrid.  The data populated is very expensive to gather, so I have opted to collect only the data shown on the current page of the grid and set the virtual count to a select COUNT(*) ...etc. which works fine when I have the radGrid on a webpage.  

In the NeedDatasounrce event, I simply get the radGrid.PageSize & radGrid.CurrentPageIndex and use these to figure out the set to return... this all works ok in a web page.

However, if I use the same grid in a server control (built in CreateChildControls()) the page size is always 10, even when I jump from 10 to 20 to 50, each time in (needdatasource event) code it is 10.  Viewstate is enabled for this grid, could it be that the viewstate has not loaded for this grid at this point?  If so , any reason why not for server control, but OK on the aspx webpage?...(differences in event orders??)  

Is there anything I can do to get this pagesize value at the radGrid_needdatasource event for my server control?

ps - This new page value is available by the time we get to the pre_render event... and the PageSize changed event fires after the needdatasource event, so these eventargs are too late to be used in the datasource.

Thanks in advance

Craig
Top achievements
Rank 1
 answered on 28 Mar 2014
1 answer
193 views
how to perform the Radbutton condition base radconfirm,radalert
And When i check the radgrid GroupHeader check box  checked  child items check box checked at list 1 child item checked after click radbutton  call the radconfirm,other wise call the radalert  sample code in javascript
Shinu
Top achievements
Rank 2
 answered on 28 Mar 2014
1 answer
278 views
I am building an application that will be used globally.  So, how or where do I specify inside the Telerik Control to use the correct Language.  For example, I use a RadTextBox control.  That control has a "Label" property and I set the value of that property to an English Text.  How will it get translated into German for example?
Viktor Tachev
Telerik team
 answered on 28 Mar 2014
2 answers
78 views
I am performing a test on the editor content in OnClientSubmit. I would like to prevent the submit if the test fails. Is it possible to do this?
Ianko
Telerik team
 answered on 28 Mar 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?