We help IT Professionals succeed at work.
Get Started

Access forms not diplaying decimals after conversion to MDE

Dezzar82
Dezzar82 asked
on
222 Views
Last Modified: 2012-06-21
Hi All,

I have a very strange issue that has only occurred recently with an application I developed - as in the problem was not present previously, and I cannot determine anything that has changed to make it occur now.

The problem is:
I have subforms whos control source is controlled dynamically by code.  User makes various selections which drive modules that forumlate the appropriate SQL to be used as the record source of the subform. All works well.

One of the fields on many of these subforms is a percentage.  Previously formatted as a percentage on the form itself.  The data is pulled directly from the table by the query without re-determining the format.  The table is formatted as double.

0.0255 would therefore display as 2.5500% on form.  And any calculated items in the query ie: (2.5/100) would display as 2.5000% (4 decimals)

All of a sudden, I have packaged up the latest version of the system, converted to MDE and deployed to users as their new front end.  Packaged up from exactly the same mdb as before.

Now, these very same percentage fields show simply as 2.0000  Decimal PLACES retained, but no information in them.  Its not rounding the numbers as 1.9888 displays as 1.0000

I have tried:
> Changing the query source to multiply the results or value by 100 and formatted the forms field as Fixed 4 instead of Percentage
> Started a new database and imported everything from the old database
>Ripping my hair out....

Still the same problem.  I notice that it only occurs once the system is converted to MDE.

Here are some screen shots:

The MDB version of the subform (Figure1) Figure 1
The exact same from the MDE version on the same computer (Figure2).... Figure 2
You might notice randomly that the third line from the bottom has decided to show the decimals in full, but is a completely different result to what it should be.  Apart from being an mdb or mde format database, there is not a single difference between the two...

For this particular form the field is a calculated field in a query ("([Margin$]/[Amount])*100 AS AvgMargin").  But the same occurs for non-calculated values as well.

This is quickly becoming one of the most frustrating issues I've ever had with access and I'm hoping someone out there has come accross this before, or knows what might be happening.
Comment
Watch Question
Commented:
This problem has been solved!
Unlock 1 Answer and 4 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE