Windows Xojo saves Width and Height values as scientific notation

In my current porting work on Windows, I’ve just discovered an oddity where Xojo 2014r1.1 saved some of my updated Window files (VCP project) with their Width and Height properties entered as scientific notation instead of integer values (6.44e+2 instead of 644).

It doesn’t seem to negatively impact the project, but it feels very odd when I diff the current source against my repository and the only difference is those lines.

Project was originally from RS2007r1 and hadn’t been edited in any newer version until now.

Bug or oddity?

Certainly an oddity
We’ve been working hard to get rid of the format of data flip flopping around like this as it drives us just as crazy in svn :stuck_out_tongue:

Okay, so I’m not losing my marbles… I’ll keep my eyes open and see if a trend shows up.

Oh, and it only seems to affect the Window Width and Height properties. Other properties (Left, Right, etc.) aren’t affected.

Also: I have the feeling that one better create a project using Xojo instead or updating a project created before Xojo era.

This is just a feeling.

Something that I’ve now started doing after this is to update the projects to 2012r2.1 first and THEN move them to Xojo. I restarted this project’s port effort that way and the scientific notation seems to have gone away.

Also, I’ve started “touching” every control to make sure that the parenting is retained across the updates. Sometimes, Xojo is not recognizing the controls’ parent. By select the controls and then using the cursor keys and move the controls one left , one right seems to resolve this.

It displays this behavior in the report editor as well in my setup.

I saw an issue in an app recently where Str() had started putting out commas in numbers larger than 1000 (ie 1,000). This didn’t used to be the case, perhaps this has had a knock-on effect in the IDE.

This is why I always use Str(x, “-0”) instead of Str(x). Of course, swap in the format that makes the most sense for you.

I tend to use Format() and specify a format, but, occasionally a str() slips through. :slight_smile:

Format obeys the system settings. For integers, this usually isn’t an issue, but can be for doubles. That’s why Format(x, “pattern”) should be used for display and Str(x, “pattern”) should be for storage.