Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
410 views

Is there a way to populate a grid manually?

In my application I'm uploading a file with a list of sales orders and a few other columns that will have a server-side process. At the end of processing all the sales order list, I want to report back to the user in a nice grid all the sales orders and data that he uploaded with an additional column specifying the status of the operation.

So there is no database to bind the Grid. Is this doable with RadGrid?

Konstantin Dikov
Telerik team
 answered on 17 Jan 2017
1 answer
169 views

How could this demo:

 

http://demos.telerik.com/aspnet-ajax/media-player/examples/applicationscenarios/video-gallery/defaultvb.aspx

 

be extended so, that the video can be watched in Full screen mode and scaled back to original Lightbox size?

 

Marc

Viktor Tachev
Telerik team
 answered on 17 Jan 2017
5 answers
114 views

Hi,

I have a radpivotgrid on my asp.net page.

I need to save and reload state but I need to store the XML in the db and not the id such as

Dim fileId As String = Session("CustomPersistenceSettingsKey").ToString()
RadPersistenceManager1.StorageProviderKey = fileId ''need xml here

 

How can i  do that?

 

Thanks

newp
Top achievements
Rank 1
 answered on 17 Jan 2017
3 answers
321 views

Hi, i have a management problem,

i have a grid that have a query as datasource, grid is enabled to filter and paging, when i filter, it filter for all pages, 

so the result is:

Page1 - result

Page2 - result etc etc

i want the it filtering for all the pages and then refresh the number of pages;

Now post some code because mi english is bad:

thank you.

<telerik:RadScriptManager runat="server" ID="Scipr"></telerik:RadScriptManager>  
 
<telerik:RadGrid runat="server" ID="rgrProva" Skin="Hay"   
        AutoGenerateColumns="false" AllowFilteringByColumn="true"  
        onpageindexchanged="rgrProva_PageIndexChanged" EnableLinqExpressions="false"  
        onneeddatasource="rgrProva_NeedDataSource" >  
 
    <PagerStyle Mode="NumericPages" />  
    <ClientSettings>  
    <Selecting  AllowRowSelect="true"/>  
    </ClientSettings>  
        <MasterTableView>  
            <Columns>  
            <telerik:GridNumericColumn UniqueName="colAnno" DataField="RIC.reqann">  
            </telerik:GridNumericColumn>  
            <telerik:GridNumericColumn UniqueName="colNumero" DataField="RIC.reqnum" FilterControlWidth="40px"   
            AutoPostBackOnFilter="false" CurrentFilterFunction="Contains" FilterDelay="4000" ShowFilterIcon="false">  
            </telerik:GridNumericColumn>  
            <telerik:GridBoundColumn UniqueName="colCliente" DataField="RIC.reqcli">  
            </telerik:GridBoundColumn>  
            </Columns>  
        </MasterTableView>  
</telerik:RadGrid> 

   protected void Page_Load(object sender, EventArgs e)  
        {  
                  
        }  
 
        private void _Load(int PageNumber)  
        {  
            rgrProva.AllowPaging = true;  
            rgrProva.PageSize = 15;  
            rgrProva.PagerStyle.Mode = GridPagerMode.NumericPages;  
            rgrProva.AllowCustomPaging = true;  
 
            FinitenessEntities context = new FinitenessEntities();  
 
            var qReq = from n in context.RICHIESTE  
                       orderby n.reqann, n.reqnum  
                       select new {RIC = n };  
 
            rgrProva.VirtualItemCount = qReq.Count();  
            rgrProva.DataSource = qReq.Skip(rgrProva.PageSize * PageNumber).Take(rgrProva.PageSize);  
        }  
 
        protected void rgrProva_PageIndexChanged(object source, Telerik.Web.UI.GridPageChangedEventArgs e)  
        {  
            this._Load(e.NewPageIndex);  
        }  
 
        protected void rgrProva_NeedDataSource(object source, GridNeedDataSourceEventArgs e)  
        {  
            this._Load(0);  
        } 

Konstantin Dikov
Telerik team
 answered on 17 Jan 2017
1 answer
91 views

How can I modify the query string of the DialogHandler.aspx from the RadEditor when a command is executed ?

I want to be able get the query string from my CustomFileBrowserProvider HttpContext parameter.

I tried:

function OnClientCommandExecuting(editor, args) {
                var commandName = args.get_commandName();
                if (commandName == 'ImageManager') {
                    editor.get_dialogOpener().set_additionalQueryString("&cmd=img");
                }
                else if (executedCommand == 'DocumentManager') {
                    editor.get_dialogOpener().set_additionalQueryString("&cmd=doc");
               }
}

It only works the second time the file browser is opened.

Vessy
Telerik team
 answered on 16 Jan 2017
1 answer
253 views
Is there any way to override the App_Data/RadUploadTemp folder?  We have come across a space issue on the C: drive where the website is hosted and would like to move the temp directory to the D: drive, if possible?  Some customers are uploading files > 1 GB.  Thanks
Vessy
Telerik team
 answered on 16 Jan 2017
14 answers
183 views

Hello Telerik,

I have an .ASPX page with a RadGrid that has AllowFilteringByColumn="true". When I filter on multiple columns, I get the expected resulting records.

My problem is when I put the same RadGrid in a user control and embed this user control in another .ASPX page.

When I filter on one column, it works fine. But when I filter on another column, it always overrides the previous filter. Filtering on multiple columns does not work. I've used Session variables to store the FilterExpression and tried applying it at various points but have not been successful.

I've exhausted so many hours trying to make this work, but to no avail.

Would you please create a working sample project (VB preferred) that shows this is at all possible?

 

Many thanks as always.

Virgil

Virgil Rodriguez
Top achievements
Rank 1
 answered on 16 Jan 2017
1 answer
204 views
I am trying to figure out a way to scroll to a row when the user loads the page. When the user clicks an item in the grid, they are taken to an edit page. Upon coming back to the listing, I want to scroll the grid to the row containing the record they just edited.
Konstantin Dikov
Telerik team
 answered on 16 Jan 2017
14 answers
335 views
I am using various Rad ajax controls on a photo theme page.  I have 2 rotators in different tabs of a tabstrip each loading the same images from a DB but displaying them differently.  Initially when the images are loaded, they are ok, but after selecting a different set of images using a RadListBox in the second tab, sometimes the images in the rotator in the first tab disappear even though they are showing in the html.  I made sure the images in each of the rotators are the same size and the height and width attributes are set correctly.  I am attaching some code snippets.  I would appreciate any help you could give on this.

Thanks,

Rick Freiberg
Concinnity Marketing
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="LoadingPanel1">
       <AjaxSettings>
           <telerik:AjaxSetting AjaxControlID="thumbRotator">
               <UpdatedControls>
                   <telerik:AjaxUpdatedControl ControlID="imagePreview" LoadingPanelID="LoadingPanel1" />
                   <telerik:AjaxUpdatedControl ControlID="RadListView1"
                       LoadingPanelID="LoadingPanel1" />
               </UpdatedControls>
           </telerik:AjaxSetting>
           <telerik:AjaxSetting AjaxControlID="thumbRotator1">
               <UpdatedControls>
                   <telerik:AjaxUpdatedControl ControlID="imagePreview" LoadingPanelID="LoadingPanel1" />
                   <telerik:AjaxUpdatedControl ControlID="RadListView1"
                       LoadingPanelID="LoadingPanel1" />
               </UpdatedControls>
           </telerik:AjaxSetting>
           <telerik:AjaxSetting AjaxControlID="RadListBox1">
               <UpdatedControls>
                   <telerik:AjaxUpdatedControl ControlID="thumbRotator"
                       LoadingPanelID="LoadingPanel1" />
                     <telerik:AjaxUpdatedControl ControlID="SqlDataSource2"
                       LoadingPanelID="LoadingPanel1" />
                   <telerik:AjaxUpdatedControl ControlID="thumbRotator1"
                       LoadingPanelID="LoadingPanel1" />
               </UpdatedControls>
           </telerik:AjaxSetting>
       </AjaxSettings>
   </telerik:RadAjaxManager>
   <telerik:RadAjaxLoadingPanel ID="LoadingPanel1" runat="server" Transparency="30"
       EnableSkinTransparency="true" BackColor="#E0E0E0">
   </telerik:RadAjaxLoadingPanel>


<telerik:RadTabStrip ID="RadTabStrip1" runat="server" SelectedIndex="0"
                    MultiPageID="RadMultiPage1" CssClass="tabstyle" SelectedCssClass="SelectedTab"
                    Align="Right" ForeColor="White" Skin="Sitefinity">
                    <Tabs>
                        <telerik:RadTab Text="CURRENT THEME" >
                        </telerik:RadTab>
                        <telerik:RadTab Text="GALLERY" >
                        </telerik:RadTab>
                        <telerik:RadTab Text="UPLOAD PHOTOS">
                        </telerik:RadTab>
                    </Tabs>
                </telerik:RadTabStrip>
                <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0">
                    <telerik:RadPageView ID="RadPageView1" runat="server" CssClass="photowrap_cm">
                        <div id="picsarchivevertical_cm">
                            <table width="88" >
                                <tr>
                                    <td >
                                        <img src="Images/arrow_up2.png" id="img_up" height="20" width="40" alt="" style="cursor: pointer" />
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        <telerik:RadRotator ID="thumbRotator" runat="server" RotatorType="Buttons" Width="72px"
                                            Height="240px" ItemHeight="60px" ItemWidth="73px" FrameDuration="1" ScrollDirection="Up,Down"
                                            OnItemClick="ShowImage" BorderStyle="None">
                                            <ItemTemplate>
                                                <div>
                                                    <img src='<%# DataBinder.Eval(Container.DataItem, "Image") %>' alt='gallery image'
                                                        class="RotatorImage" /><br />
                                                </div>
                                            </ItemTemplate>
                                            <ControlButtons UpButtonID="img_up" DownButtonID="img_down" />
                                        </telerik:RadRotator>
                                        <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:CMCONSUMER_IMPERIAL_WEB_QAConnectionString2 %>"
                                            SelectCommand="SELECT a.THUMBPATHFILENAME as [NAME] FROM ASSET a INNER JOIN PHOTO_OF_THE_DAY AS p ON p.ASSET_ID = a.ASSET_ID where Photo_Category = @ThemeID">
                                        <SelectParameters>
                                            <asp:ControlParameter ControlID="RadListBox1" DefaultValue="2" Name="ThemeID"
                                                PropertyName="SelectedValue" />
                                        </SelectParameters>
                                        </asp:SqlDataSource>
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        <img src="Images/arrow_down2.png" id="img_down" height="20" width="40" alt="" style="cursor: pointer" />
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <div id="picsinglephoto_cm">
                            <asp:Image ID="imagePreview" runat="server" ImageUrl="Images/spacer.gif" Height="226px"
                                Width="328px" AlternateText="preview" BorderWidth="0"></asp:Image><div id="picsauthor_cm">
                                  <asp:Label ID="lblUserName" runat="server" Text="Name"></asp:Label>
                                  <br />
                                    <asp:Label ID="lblPhotoDate" runat="server" Text="Date"></asp:Label></div>
                            <div id="picslikeit_cm">
                                <asp:Label ID="lblLikes" runat="server" Text="Likes"></asp:Label> <asp:LinkButton
                                    ID="ImagelikeButton" runat="server" Text="Like" Style="text-decoration: none" />
                                <br />
                            </div>
                        </div>
                        <div id="form_photoOfTheDayComment" class="tm10 clear">
                            </div>
                        <div id="picscomments_cm">
                        <asp:Image ID="comment_headshot" runat="server" Height="50" Width="50" CssClass="floatLeft rm10" />
                            <asp:TextBox ID="txtComment" runat="server"
                                CssClass="form_comments fnt11 italic white" Text="Leave a comment..."
                                TextMode="MultiLine"></asp:TextBox>
                            <br /><p class="white fnt10 podCommentCopy">
                                    By submitting this post, you grant USA Gold the permission to publish the comment
                                    on joinusagold.com</p>
                            <asp:LinkButton ID="lnkCommentSubmit" runat="server" CssClass="fnt10 white strong rightArrow podCommentSubmit"
                                CommandName="ContentId" OnCommand="lnkCommentSubmit_OnCommand">SUBMIT</asp:LinkButton>
                            <telerik:RadListView ID="RadListView1" runat="server" DataSourceID="SqlDataSource1"
                                AllowPaging="True" DataKeyNames="COMMENT_ID"
                                ItemPlaceholderID="CommentContainer" Height="170" Skin="Sunset"
                                onitemcommand="RadListView1_ItemCommand">
                                 
                                <ItemTemplate>
                                     <fieldset style="float: left; width: 280px;" >
                                        <legend><%# Eval("NAME") %></legend>
                                        <div>
                                            <div style="text-align: center; float: left">
                                                <telerik:RadBinaryImage ID="RadBinaryImage2" runat="server" AlternateText="Avatar"
                                                    ToolTip="Avatar" Width="50px" Height="50px" ResizeMode="Fit" ImageUrl='<%# Eval("AVATARPATH") %>' /></div>
                                            <div>
                                                <div>
                                                 
                                                <%# Eval("DATE") %>
                                                </div>
                                                <div>
                                                    <div>
                                                <%# Eval("COMMENT") %>
                                                    </div>
                                                    <div>
                                                        <%# GetLikeText(Eval("LIKES").ToString()) %> it.  
                                                        <asp:LinkButton ID="likeButton" runat="server" Text="Like" CommandName="AddLike"
                                                            CommandArgument='<%# Eval("Comment_ID") %>' Style="text-decoration: none" /><br />
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </fieldset>
                                </ItemTemplate>
                                <LayoutTemplate>
                                    <fieldset>
                                        <asp:PlaceHolder ID="CommentContainer" runat="server"   />
                                         <telerik:RadDataPager ID="RadDataPager1" runat="server" PageSize="2" Skin="Black">
                                    <Fields>
                                        <telerik:RadDataPagerButtonField FieldType="Numeric" />
                                    </Fields>
                                </telerik:RadDataPager>
                                    </fieldset>
                                </LayoutTemplate>
                            
                            </telerik:RadListView>
                        </div>
                    </telerik:RadPageView>
                    <telerik:RadPageView runat="server" ID="RadPageView2">
                        <div style="width: 700px">
                            <div style="float: left" class="picsarchivevertical_cm">
                             
                            <table width="477" >
                                <tr>
                                    <td colspan="3"  align="center">
                                        <img src="Images/arrow_up2.png" id="img_up2" height="20" width="40" alt="" style="cursor: pointer" />
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                <telerik:RadRotator ID="thumbRotator1" runat="server" RotatorType="Buttons" Width="480px"
                                            Height="214px" ItemHeight="107px" ItemWidth="160px"  FrameDuration="1" ScrollDirection="Up,Down"
                                    OnItemClick="ShowImage" BorderStyle="None" >
                                    <ItemTemplate>
                                        <div>
                                            <img src='<%# DataBinder.Eval(Container.DataItem, "Image") %>' alt='gallery image'
                                                class="BigRotatorImage" />
                                        </div>
                                    </ItemTemplate>
                                    <ControlButtons UpButtonID="img_up2" DownButtonID="img_down2" />
                                </telerik:RadRotator>
                                </td>
                                  
                                </tr>
                                                                <tr>
                                    <td colspan="3" align="center">
                                        <img src="Images/arrow_down2.png" id="img_down2" height="20" width="40" alt="" style="cursor: pointer" />
                                    </td>
                                </tr>
 
                                </table>
                            </div>
                            <div style="float: right">
                                <telerik:RadListBox ID="RadListBox1" runat="server" DataValueField="ID"
                                    DataTextField="Theme" AutoPostBack="true" Height="233" Skin="Black" Width="210"
                                    onselectedindexchanged="RadListBox1_SelectedIndexChanged1">
                                </telerik:RadListBox>
                            </div>
                        </div>
                    </telerik:RadPageView>
                    <telerik:RadPageView runat="server" ID="RadPageView3">
                       <div id="picsuploadphoto_cm">
 
 
 
<p>
 
 
<input type="file" class="picsbrowseBtn" name="datafile" size="40" />
</p>
<div>
<input type="button" class="picsbubmitBtn" value="" />
 
</div>
</div>
                    </telerik:RadPageView>
                </telerik:RadMultiPage>
Marin Bratanov
Telerik team
 answered on 16 Jan 2017
1 answer
81 views

I have a very annoying problem. When I apply a filter on design this filter does not work propertly:

<telerik:PivotGridReportFilterField DataField="PolReemNumID" Caption="Nº Interno (Reemp. por)" FilterType="DoesNotInclude" FilterValues="0"></telerik:PivotGridReportFilterField>

 

In running the app the filter is applied and filtering but when I open the filter window and I change this filter it does not change the results.

I have seen that when I change the filter options running the app the filter collection (RadPivotGrid1.Filters) still has the previous filter.

 

For example:

I set the filter to DoesNotInclude and filter value 0 then running the app I set the filter to Include and filter value 0, the rows doesn't change and the filter collection shows as you can see in the QuickWatch result attached file the previous filter is not deleted so the new filter does not work.

 

Is there any way to solve this? Is there a method fired when the filter change to delete the previous filter?

 

Konstantin Dikov
Telerik team
 answered on 16 Jan 2017
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?