RDLC Missing Fields

tikitiki Member Posts: 16
edited 2013-02-22 in NAV Three Tier
Something that has annoyed me for some time with the RDLC reporting in NAV is the fact that changing a Classic layout by adding fields does not always mean these fields get propagated to the RDLC XSD and therefore are not available in the RDLC report.

Does anyone have a solution for this? For example, I am just now editing a standard NAV report - I save it as a custom report object, add some fields with unique dataset names, and only *some* of these fields make it to be available in the RDLC version of the report. I have seen this happen at multiple clients, and so much time is wasted trying to browbeat RDLC to cooperate. Is there an easy solution?

Comments

  • mohana_cse06mohana_cse06 Member Posts: 5,503
    adding fields in classic sections does not reflect in rdlc report..we have to manually add them in rdlc layout also..
  • tikitiki Member Posts: 16
    Thanks for the reply.

    How do you mean manually add them? I have tried opening the XSD file in the XML editor and entering them, but when I save and close it, the RDLC file still cannot see the fields.

    For example, I create a field on an existing report with a lablel and a textbox. I have the label dataset name set to MyField_Caption and the textbox set to MyField. Oftentimes, MyField_Caption will be available in the RDLC layout, but MyField will not be there. Putting the field in the XSD for the report doesn't seem to make a difference.
  • mohana_cse06mohana_cse06 Member Posts: 5,503
    I am not sure from where you are entering..

    From desing mode of report, click view-->Layout
    then rdlc layout will open..
    add the fields like classic..
  • clauslclausl Member Posts: 455
    Any fields I add as fields in Section Designer is visible in DataSet/Result in Visual Studio.

    Maybe you could give a concrete example of a field which is added but not visible from Visual Studio?

    /Claus Lundstrøm
    Claus Lundstrøm | MVP | Senior Product Manager | Continia.com
    I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
    I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
  • clauslclausl Member Posts: 455
    You cannot add fields to XSD, new XSD is created from NAV everytime you hit "View / Layout", so you loose you changes. Fields need to place in the Section designer to be appear in XSD.

    /Claus Lundstrøm
    Claus Lundstrøm | MVP | Senior Product Manager | Continia.com
    I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
    I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
  • tikitiki Member Posts: 16
    Thanks claus. Yes, I expected modifying the XSD would be irrelevant, but I have tried it anyway.

    The problem is intermittent, but the example above is exactly what happens. I'm looking at a report right now where I have a label and a textbox in the classic with unique DataSetFieldName values. The label's DataSetFieldName to MyField_Caption and the textbox's DataSetFieldName is MyField. This is a copy of the Sales Invoice report that I made yesterday and added these fields to after making some initial changes to the RDLC layout.

    I save the file in Classic, view the RDLC layout, and try to add both of these new fields to the report. I can also look at the fields available in the dataset to confirm this. MyField_Caption is in the dataset and available for use, but MyField is nowhere to be found. Some other custom fields I added to this same report do not exhibit this issue, but then some others do. Not all of the fields make it across to the RDLC layout from the Classic layout. Thoughts? This is not the first report/client I've seen this happen to, and I'm on 2009 R2 with the latest build.
  • tikitiki Member Posts: 16
    Thanks to claus this problem was solved... the fields in the Section Designer had '' as their SourceExpr as they were placeholders while the underlying fields get sorted out. Evidently a field with '' as the SourceExpr won't show up in the RDLC layout.

    Thanks claus! =D>
  • clauslclausl Member Posts: 455
    No problem, now you have my contact details, so just call if you run into Reporting issues in the future. :)

    /Claus Lundstrøm
    Claus Lundstrøm | MVP | Senior Product Manager | Continia.com
    I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
    I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
  • lanoxxlanoxx Member Posts: 1
    If anyone comes across this problem again. Here is what I have found out:

    If the field only contains the name of the column but not the name of the table then sometimes the field is not available in the RDLC Layout. I had this particular problem with the "Sales Invoice Line" table. I tried to add the field "Line Amount" to an invoice and it would not show up in the RDLC layout. Yet I could see the caption/label for this field and also the format item for this field, for example in the classic client I have the following fields defined:
    "Sales_Invoice_Line_LineAmount_Caption" and
    "Sales_Invoice_Line_LineAmount_Field" which had SourceExpr="Line Amount" set.

    In the RDLC Layout I could only see:
    "Sales_Invoice_Line_LineAmount_Caption" and
    "Sales_Invoice_Line_LineAmount_FieldFormat"
    but not
    "Sales_Invoice_Line_LineAmount_Field"

    The ___SOLUTION___:
    The solution was to add change the SourceExpr field of the "Sales_Invoice_Line_LineAmount_Field" to SourceExpr="Sales Invoice Line"."Line Amount", after closing and reopening the layout the field was immediately there.

    Particularly interesting was to see, that if I changed the source expression to either some static text or another field of the same table, then I could see it in the RDLC layout. Only with "Line Amount" it was not possible to get the field in RDLC unless I added the name of the table to the source expression.

    For me this is clearly a bug in Navision.
  • Big_DBig_D Member Posts: 203
    Oh my goodness lanoxx you are so right :D !
    Was driving me bananas as the RDLC Report just wasn't seeing some of the new Fields I placed on the Report Section???
    Changed the SourceExpr from "VAT Bus. Posting Group" to "VAT Entry"."VAT Bus. Posting Group" - Saved the Report and now RDLC can see the new fields o:) !
    Big D signing off!
Sign In or Register to comment.