Friday, May 15, 2015

SSRS Reports Excel merge cell issue

I found various blogs and forums discussing the Excel merging cells issue while exporting SSRS report to Excel. I found a simple and logical reason behind the issue.


In the above design consider Report Header Textbox with Grid in the details part. If Header Textbox does not align with Grid columns, Excel will start merging the difference of columns which is shown by red line in the picture. However, if you get it align with Grid column Excel will start a new column as there will be no difference in columns indicated by green line.

Thursday, May 7, 2015

Cheque modification in AX 2012

Cheque modification is a most common requirements in Dynamics AX world. In this post I will discuss the values which are prepared before these values are dumped in SSRS Report framework. All cheque values including Recipient name and address, Amount in words, Date, Slip transactions etc.

The class which needs to be modify in order to customize the values is "CustVendCheque".

CustVendCheque class methods are generally modified to get the cheque values customized:
  • getSlipText or (fillSlipTxt which is obsolete in AX 2012)
  • output

getSlipText method is responsible for most of the data that is printed on the check slip lines; the key point here is that it is sent as a single block of text which leaves the developer very little room to actually modify the cheque without getting into a stream of circular reference errors. So, whatever we need to do as far as Text formatting (for check stubs) goes, we should get it done before this text (‘chequeSlipTxt’) leaves the class.

Friday, May 1, 2015

Financial dimension lookup

While developing in AX "lookups" are the most common requirements you may come across. However, sometimes you may have to link your customized lookup to non-conventional datasets such as "Financial Dimensions". 
This post will show you how to create custom lookup listing one of "Financial Dimension" on report dialog. For this requirement it requires "UI Builder" class.

This customized lookup function will be using "DimensionDefaultingLookup" from.

Contract Class declaration : 

[
    DataContractAttribute,  SysOperationContractProcessingAttribute(classStr(xxxxReportUIBuilder))    
]
public class xxxxReportContract
{
    Name    dimensionValue;
}

Contract parameter :

[
    DataMemberAttribute(identifierStr(dimensionValue)),
    SysOperationLabelAttribute(literalstr('@SYS3794')),
    SysOperationDisplayOrderAttribute('1')
]
public Name parmFinDimLocation(Name _dimensionValue = dimensionValue)
{
    dimensionValue = _dimensionValue;
    return dimensionValue;
}