8000 Include number formatting configuration · Issue #50 · ajryan/RptToXml · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Include number formatting configuration #50

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
ltickett opened this issue Apr 14, 2022 · 2 comments
Open

Include number formatting configuration #50

ltickett opened this issue Apr 14, 2022 · 2 comments

Comments

@ltickett
Copy link

I suspect like many others, I have just started using the tool in an attempt to provide some sort of audit trail/diff in Git when modifying Crystal Reports.

I just updated the format of a numeric field and re-generated the xml. To my surprise, it is exactly the same.

I will try and take a look at the source and see if it's something I can add in, but quite hectic at the moment.

Thanks for the great tool!

@ltickett
Copy link
Author

I've just taken a quick look. I guess we would want to add something around

else if (reportObject is FieldObject)

I don't think we're currently extracting any field formatting. But it looks like we might want to check fo.DataSource.ValueType, then we know which fo.FieldFormat property to examine?

For fo.FieldFormat.NumericFormat it shouldn't be too bad, I think we only have 5 properties to extract:

CurrencySymbolFormat
DecimalPlaces
EnableUseLeadingZero
NegativeFormat
RoundingFormat

It may be a bit more of a PITA for date/datetime.

I also wonder how simple the mapping is from the enum:

    [CLSCompliant(true)]
    public enum FieldValueType
    {
        Int8sField = 0,
        Int8uField = 1,
        Int16sField = 2,
        Int16uField = 3,
        Int32sField = 4,
        Int32uField = 5,
        NumberField = 6,
        CurrencyField = 7,
        BooleanField = 8,
        DateField = 9,
        TimeField = 10,
        StringField = 11,
        TransientMemoField = 12,
        PersistentMemoField = 13,
        BlobField = 14,
        DateTimeField = 15,
        BitmapField = 20,
        IconField = 21,
        PictureField = 22,
        OleField = 23,
        ChartField = 24,
        SameAsInputField = 250,
        UnknownField = 255
    }

Any words of wisdom if i'm to try throwing together a PR?

@christopherpickering
Copy link
Collaborator

Sorry I missed this - yes please send out a PR if you are able.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0