Telerik Forums
UI for ASP.NET AJAX Forum
5 answers
147 views
Hi,

I have radtabstrip with 2 tabs .Also included radmultipage with 2 pageviews havind grid on each page.

I have set rendering on selected page =true in multipage.

Also i used Enableajaxskinrendering to True

Whne i click the tab each  grid  loads but the grid border and column widths are not rendered properly.

Also i use the below script to avoid postbacks

 

function onTabSelecting(sender, args)

 

{

 

if (args.get_tab().get_pageViewID())

 

{

args.get_tab().set_postBack(

false);

 

}

}


Help me out its urgent.

Thanks

Sathya
Vessy
Telerik team
 answered on 15 Apr 2019
1 answer
210 views

Hi,

I think I have quite a specific task. I have a page, where I need to generate multiple grids, for different types of entities.

And the thing is that on grid generation step I do not know types of entities that I will have, in other words I have a set of 'Type' entities each describing some class, so I can not declare grids in 'aspx' page, but I need to generate them in code behind.

I am trying to generate grid in the code behind using this code:

var grid = new RadGrid();
grid.AutoGenerateColumns = true;
grid.MasterTableView.EditMode = GridEditMode.InPlace;
grid.DataSource = input.GetDataForEngineQueryPosition(job, metricKey); //just collection of entities
grid.Visible = true;
grid.DataBind();

Quite simple, and the code is working, I do see the grid with appropriate columns, but I cant edit the values in the cells.

I also tried to generate columns manually depending on properties provided by 'type' entity, like this:

 

var grid = new RadGrid();
grid.AutoGenerateColumns = false;
var propertiesBindingFlags = System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Instance;
var customizableFields = input.CustomizableProperties;
bool showAll = false;
                
foreach(var property in inputType.GetProperties(propertiesBindingFlags))
{
  var field = new Telerik.Web.UI.GridBoundColumn();
  field.DataField = property.Name;
  field.HeaderText = property.Name;
  field.ReadOnly = false;
  field.Visible = true;
  grid.Columns.Add(field);
}
grid.MasterTableView.EditMode = GridEditMode.InPlace;
grid.DataSource = input.GetDataForEngineQueryPosition(job, metricKey);
grid.Visible = true;
grid.DataBind();

Values are displayed correctly in this case, but unlike for the autogeneration I don't see proper controls for every column (like checkbox) and I understand why.

But I still can't edit the values in the cells.

 

Also, after updating the values I need to submit them back to the server, what is the best way to do this. 

Thanks.

Kind regards,

Erik Martirosyan

Attila Antal
Telerik team
 answered on 15 Apr 2019
4 answers
250 views
Good afternoon,

I was wondering if it is possible to add a hyperlink (server side, not JS please) to individual images contained in a RadImageGallery?

I have tried adding hyperlinks in the Title & Description fields of the ImageGalleryItems, but the html doesn't get processed and is displayed as text.

e.g. <telerik:ImageGalleryItem Title="<a href='http://www.google.com'>Item1</a>" ImageUrl="images/image1.jpg" description="<a href='http://www.google.com'>Description text will go here</a>"/>

The above is purely an example, but ultimately we will be binding the RadImageGallery server side to a dataset containing the Title, Description & ImageURL, hence why Javascript is not an ideal option.

Many thanks
Rumen
Telerik team
 answered on 12 Apr 2019
13 answers
776 views
Hi there

i'm trying to execute a javascript code when i check or uncheck a the GridCheckBoxColumn in a grid.

I have 2 checkboxes and when i check the first one i want to make the other check bot read only attribute = false

thanks in advance
Attila Antal
Telerik team
 answered on 12 Apr 2019
1 answer
373 views

This is the error...

Uncaught Sys.WebForms.PageRequestManagerParserErrorException: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.
Details: Error parsing near ':"text/javascript"}

I have read some other older threads about this but I am not sure what the actual issue is.  We just recently upgraded our telerik after a couple years and now this error is popping up everywhere.  Never had this issue before.  We use RadAjax Manager, RadAjax Panels, and RadAjax loading panels in a lot of places and that seems to be were the issue always pops up.  Need some guidance on how to remedy this issue without having to downgrade the telerik version because we upgraded to fix other issues with radeditors and jquery.  Please help when you can and let me know if you need more info.

Code example below...

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolderMain" runat="server">
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" EnableEmbeddedSkins="false" CssClass="rwLoading" Height="100%" Width="100%">
    </telerik:RadAjaxLoadingPanel>
    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" LoadingPanelID="RadAjaxLoadingPanel1">
        <asp:HiddenField ID="HiddenFieldLookupType" runat="server" Value="" />
        <asp:HiddenField ID="HiddenFieldControlsToSet" runat="server" Value="" />
        <table width="100%" border="0" cellspacing="2" cellpadding="0">
            <tr>
                <td align="center" valign="top">
                    <telerik:RadGrid ID="RadGridLookup" runat="server" AllowMultiRowSelection="False"
                        AllowPaging="True" PageSize="75" AllowFilteringByColumn="true" AllowSorting="False"
                        ShowStatusBar="false" ShowFooter="false" ShowHeader="True" AutoGenerateColumns="False"
                        GridLines="None" EnableEmbeddedSkins="True" GroupingSettings-CaseSensitive="false"
                        Width="580">
                        <PagerStyle Mode="NumericPages" Visible="False" AlwaysVisible="true" Position="Bottom"
                            Height="0px"></PagerStyle>
                        <StatusBarSettings LoadingText="Loading Data" ReadyText="Data Loaded." />
                        <ClientSettings EnablePostBackOnRowClick="False">
                            <Scrolling AllowScroll="true" EnableVirtualScrollPaging="True" ScrollHeight="250"
                                SaveScrollPosition="True" />
                            <Selecting AllowRowSelect="True" EnableDragToSelectRows="True" />
                            <ClientEvents OnRowDblClick="RadGridLookupRowDoubleClick" OnGridCreated="RadGridLookupGridCreated" />
                        </ClientSettings>
                        <MasterTableView DataKeyNames="code" TableLayout="auto">
                            <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 DataField="description" UniqueName="GridBoundColumnDescription"
                                    FilterControlAltText="Filter column" FilterControlWidth="480" HeaderText="Search List"
                                    CurrentFilterFunction="Contains" AutoPostBackOnFilter="false" ShowFilterIcon="True"
                                    FilterDelay="1250">
                                    <HeaderStyle HorizontalAlign="left" />
                                    <ItemStyle HorizontalAlign="left" VerticalAlign="middle" />
                                </telerik:GridBoundColumn>
                            </Columns>
                            <ExpandCollapseColumn Visible="False">
                            </ExpandCollapseColumn>
                            <RowIndicatorColumn Visible="False">
                            </RowIndicatorColumn>
                        </MasterTableView>
                    </telerik:RadGrid>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:CheckBox ID="CheckboxClosedJobs" runat="server" AutoPostBack="True" Checked="False"
                        EnableViewState="True" Text="Show closed/archived jobs?" />
                </td>
            </tr>
            <tr>
                <td align="center" valign="top">
                    <asp:Button ID="ButtonSelect" runat="server" Text="Select" />&nbsp;&nbsp;&nbsp;
                    <asp:Button ID="ButtonCancel" runat="server" Text="Cancel" OnClientClick="cancelClick();" />
                </td>
            </tr>
        </table>
        <input id="txtClient" runat="server" name="txtClient" type="hidden" />
        <input id="txtDivision" runat="server" name="txtDivision" type="hidden" />
        <input id="txtProduct" runat="server" name="txtProduct" type="hidden" />
        <input id="txtJob" runat="server" name="txtJob" type="hidden" />
        <input id="txtJobComp" runat="server" name="txtJobComp" type="hidden" />
        <input id="txtType" runat="server" name="txtType" type="hidden" />
        <input id="txtPO" runat="server" name="txtPO" type="hidden" />
        <input id="txtCampaign" runat="server" name="txtCampaign" type="hidden" />
    </telerik:RadAjaxPanel>

 

Vessy
Telerik team
 answered on 12 Apr 2019
3 answers
393 views

Hello,

Radgrid, Require to have some column disable edit. Some Cell Disable Edit.

Able to achieve by cell opening to block, but "TAB" key stopped and jump out of Radgrid. User require to get mouse back for next cell to open edit mode again.

Any possible way to simulate Tab key move to next cell at batch edit opening ?

 

  function BatchEditOpening(sender, args) {

                    var row = args.get_row();
                    var cell = args.get_cell();
                    
                    // cancel edit based on cell data ***
                    var content = $telerik.$(cell).text().trim();
                    if (content == "three") {
                        args.set_cancel(true);      

====== How to tab focus cell opening to next cell ??
====== args.get_cell(); does not have cell index

====== so that batchManager1.openCellForEdit(??? how to call next available cell ?? ) 
                    }

 }

VIRUX
Top achievements
Rank 1
 answered on 12 Apr 2019
1 answer
926 views

I have a radgrid with 2 columns at 400px each. I have set the width of the grid to 600px and AllowScroll=true. I also have AllowColumnResize=true, when i resize column 1 to 500px by dragging, it will automatically resize column 2 down to 300px, maintaining the original overall width of a combined 800px for the 2 columns. Is there anyway to maintain the size of column 2 when column 1 is resized such that column 1 is the new resized 500px and column 2 stays at 400px, increasing the overall combined size to 900px? I looked at ReizeGridOnColumnResize=true but that causes my grid width of 600px and allowscroll to be ignored and the width of the grid is displayed as the full 900px causing the rest of my page layout to be stretched.

                               <telerik:RadGrid ID="RadGrid1" runat="server"
                                ClientSettings-Scrolling-AllowScroll="true"                                     
                                OnNeedDataSource="RadGrid_NeedDataSource"
                                height="200"
                                Width="600">
                              <ClientSettings>
                                <Resizing AllowColumnResize="True" ResizeGridOnColumnResize="false" />
                              </ClientSettings>
                                <MasterTableView AutoGenerateColumns="false" >
                                    <Columns>                                        
                                        <telerik:GridTemplateColumn HeaderStyle-Width="400" HeaderText="1">
                                        </telerik:GridTemplateColumn>
                                        <telerik:GridTemplateColumn HeaderStyle-Width="400" HeaderText="2">
                                        </telerik:GridTemplateColumn>                                        
                                    </Columns>
                                </MasterTableView>
                            </telerik:RadGrid>

Eyup
Telerik team
 answered on 11 Apr 2019
1 answer
79 views

Hi,

 

When looking at MetroTouch (and other) skin on FF, Edge and Chrome we see a little discrepance in the stepper bar, see attached.

 

This will be solved when altering css like so:

 

.RadWizard .rwzBreadCrumb .rwzLink::before {

    right: -0.5em;}

 

original value is:

right: -0.6em;

 

Marc

 

Rumen
Telerik team
 answered on 11 Apr 2019
8 answers
192 views

I have a RadScheduler and a button to export the calendar to pdf.  Below is the code and the error message that I'm getting on the button click.

protected void RadButton1_Click(object sender, EventArgs e)
       {           
           RadScheduler1.ExportToPdf();
       }


Unable to connect to the remote server<br/>System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 

Thanks for the suggestions!!

Peter Milchev
Telerik team
 answered on 11 Apr 2019
2 answers
113 views

Change value by mousewheel does not work in Edge (Microsoft Edge 44.17763.1.0, Microsoft EdgeHTML 18.17763), Chrome is ok
try here:

https://demos.telerik.com/aspnet-ajax/numerictextbox/overview/defaultcs.aspx

Rumen
Telerik team
 answered on 10 Apr 2019
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?