Telerik Forums
Reporting Forum
1 answer
102 views
  Hi ,
i am using web config based authentication and autharization
Although i give permission in web config the report does not display as a attached image
i give permissin to report( report.cs) and .aspx file which containes reportviewer

http://f1212.hizliresim.com/14/t/h8dpq.png
Hadib Ahmabi
Top achievements
Rank 1
 answered on 28 Dec 2012
1 answer
140 views
Hi,

I'm having a problem when loading the report viewer control in to a Web Form, a drag the control and nothing happens, if a try to insert the code directly in the form an error of a TAG PREFIX appears, what it can be wrong or what a need to configure to solve this issue, i already  add the following references:

* Telerik.reporting
* Telerik.ReportViwer.WebForms
* Telerik.ReportViwer.WinForms

I posted a similar issue about 2 weeks ago and it simply disappear, it think maybe i need to post this under another topic?, but a didn't get any email, i don't know what happens with the other thread i posted.


Anyone can help me, thanks in advance.
Armando
Top achievements
Rank 1
 answered on 27 Dec 2012
2 answers
455 views
I'm attempting to adjust the column width programatically and from other forum posts I've read that there is allot involved.

I can Hide Column content on ItemDataBound, but I cannot collapse the width.
Using JustCompile and the debugger I believe I'm setting all the proper widths, but I cannot get it to collapse.

below is my code.
Can you provide any insight on the events between ItemDataBound and rendering and if there is an event between where I can adjust these values.  
public static void RemoveColumns(this Telerik.Reporting.Table tableDef, params int[] columns)
{
    /*
    var colGroups = Flatten(tableDef.ColumnGroups).ToList();
 
    foreach (int column in columns)
    {
        // colGroups[column].Visible = false; // Object not found Error in binding
        colGroups[column].Filters.Clear();
        colGroups[column].Filters.Add(new Telerik.Reporting.Filter("=1", Telerik.Reporting.FilterOperator.Equal, "=0")); // Object not found Error in binding
    }
 
    return;
    */
 
    var tableBody = tableDef.Body;
    var tableCells = tableBody.Where(x => x.ReportItem != null).ToList();
    var zero = Telerik.Reporting.Drawing.Unit.Inch(0);
 
 
    foreach (int colIndex in columns.OrderByDescending(x => x))
    {
        tableBody.Columns[colIndex].Width = zero;
 
        // shrink all cell.reportItem(s)
        foreach (var cell in tableCells.Where(x => x.ColumnIndex == colIndex))
        {
            // cell.ReportItem.Visible = false; throws error during Binding
            cell.ReportItem.Width = zero;
                     
            if (cell.ReportItem is Telerik.Reporting.TextItemBase)
                ((Telerik.Reporting.TextItemBase)cell.ReportItem).CanGrow = false;
        }
    }
}
 
         
/// <summary>
/// ItemDataBound, Remove columns by settings its content Visibility
/// </summary>
/// <param name="table"></param>
/// <param name="columns"></param>
public static void RemoveColumns(this Telerik.Reporting.Processing.Table table, params int[] columns)
{
    RemoveColumns((Telerik.Reporting.Table)table.ItemDefinition, columns);
    var zero = Telerik.Reporting.Drawing.Unit.Inch(0);
 
             
    foreach (var textbox in table.TableCells(x => columns.Contains(x.ColumnIndex)).OfType<Telerik.Reporting.Processing.TextBox>())
    {
        // textbox.Visible = false; // Doesn't collapse column
        textbox.Width = zero;
        textbox.Value = string.Empty;
 
        TextboxCanGrowProperty.SetValue(textbox, false, null);
    }
 
    foreach (var column in table.Columns.Where(x => columns.Contains(x.Index)))
    {
        TableColumnWidthProperty.SetValue(column, 0D, null);
    }
 
}
 
 
private static IEnumerable<Telerik.Reporting.Processing.ITableCell> TableCells(this Telerik.Reporting.Processing.Table table, Func<Telerik.Reporting.Processing.ITableCell, bool> predicate = null)
{
    Telerik.Reporting.Processing.ITableCell cell;
    int colCount = table.Columns.Count;
    int rowCount = table.Rows.Count;
 
    for (int rowIndex = 0; rowIndex < rowCount; rowIndex++)
    {
        for (int colIndex = 0; colIndex < colCount; colIndex = colIndex + cell.ColumnSpan)
        {
            cell = table.GetCell(rowIndex, colIndex);
 
            if (predicate == null || predicate(cell))
                yield return cell;
        }
    }
}
 
public static IEnumerable<Telerik.Reporting.TableGroup> Flatten(this IEnumerable<Telerik.Reporting.TableGroup> collection)
{
    foreach (var group in collection)
    {
        yield return group;
 
        foreach (var subGroup in Flatten(group.ChildGroups))
            yield return subGroup;
    }
}
 
private static PropertyInfo _tablecolumnWidthProperty = null;
public static PropertyInfo TableColumnWidthProperty
{
    get
    {
        if (_tablecolumnWidthProperty == null)
            _tablecolumnWidthProperty = typeof(Telerik.Reporting.Processing.TableColumn).GetProperty("Width", BindingFlags.Instance | BindingFlags.NonPublic);
 
        return _tablecolumnWidthProperty;
    }
}
 
private static PropertyInfo _textboxCanGrowProperty = null;
public static PropertyInfo TextboxCanGrowProperty
{
    get
    {
        if (_textboxCanGrowProperty == null)
            _textboxCanGrowProperty = typeof(Telerik.Reporting.Processing.TextItemBase).GetProperty("CanGrow", BindingFlags.Instance | BindingFlags.NonPublic);
 
        return _textboxCanGrowProperty;
    }
}


Thanks
Steve
Steven
Top achievements
Rank 1
 answered on 27 Dec 2012
5 answers
821 views
I have a crosstab report which shows stats for permits submitted over a 6 year period. I have them broken down by several different parameters. I have the latest year column set to be shaded a dark grey and the 2nd, 4th, and 6th years shaded a light grey. I sort them into the years based on a date permit was approved. My problem is that if here is no permits that match one of the categories it doesn't shade that box. It doesn't make the report look good with breaks in the shading. I have it filling 0's for the null cells by checking for nulls but it still doesn't shade the cells.

Any help would be greatly appreciated.
IvanY
Telerik team
 answered on 27 Dec 2012
3 answers
354 views
Hello,

We are running on an older version of the Reporting  2011 Q2 but need to user the native header features.

I have set the device information header variables (they work fine for grid lines) to true for UseNativePageHeader but the report is rendered with the header at the top of the page basically ignoring the variable.

Is there anything I am missing?
Petio Petkov
Telerik team
 answered on 27 Dec 2012
3 answers
1.1K+ views
Hi Telerik Team,

I have a table in one of my reports and I now want to change the background color of specific rows, depending of data which is contained in the row.

How can I achieve that?

Thanks in advance.
IvanY
Telerik team
 answered on 27 Dec 2012
1 answer
187 views
Hi Telerik Team
I need know if can apply ReportBook for files .trdx(without classes), this because  i have some subreports and i need export to excel, every report in every sheet of one excel file

This is possible?

Thanks
Stef
Telerik team
 answered on 27 Dec 2012
1 answer
131 views
When i Upload data in  Silverlight ReportViewer 
      Error show:-  Report Viewer not display more then 1000 record only show first 1000 record.

Please its urgent!
Hadib Ahmabi
Top achievements
Rank 1
 answered on 27 Dec 2012
1 answer
61 views
RE: http://www.telerik.com/products/reporting/data-presentation-and-analysis.aspx

We are internally evaluating Telerik Reporting. Looks like to use/show charts (bar, graph, pie, etc.) we would need to also buy RAD controls. Is that a right assessment?
Petio Petkov
Telerik team
 answered on 27 Dec 2012
4 answers
228 views
My report is not bound to a DataSource, but in the PageHeaderSection my Textbox_ItemDataBinding event keeps getting called in an infinite loop.

I have a pretty complex table in a ReportHeaderSection that is bound, but stepping through the debugger the Table finishes binding its dataset without any issues.  I originally had it in the detailSection but changed it in my debugging efforts.



How can I determine what is causing the infinite loop in the PageHeaderSection when the processing is done in the ReportEngine.


Steve
Stef
Telerik team
 answered on 27 Dec 2012
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?