cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
wolfrat
Regular Visitor

Calculation in a GalleryItem Label returns wrong results. (ThisItem.Fieldx * 100)

Hey Everybody - strange behavior found in a Label Calculation.

 

I import data from an excel File. The values are floating point values.

 

When I calculate the Values as shown below, I get strange results:

 

0 * 100 results 0 

1 * 100 results 100 

0.5 * 100 results 500 

0.75 * 100 results 7500 

Bildschirmfoto 2022-06-01 um 10.04.24.png

 

Does anyone know the problem and how to solve it? Thanks a lot.

1 ACCEPTED SOLUTION

Accepted Solutions
timl
Super User
Super User

@wolfrat 

The most likely problem is that the data type of your Fortshritt column in Excel is text, rather than floating point.

I guess you're running Power Apps in a non English locale (German?), so Power Apps is recongising 0.5 as 5, and 0.75 as 75.

If this is the case, the following should provide a more accurate result.

Value(ThisItem.Fortshritt, "en") * 100

If you're running the Power Apps Studio in German, you'll need to replace the , with a ;

 

Value(ThisItem.Fortshritt; "en") * 100

 

 

View solution in original post

2 REPLIES 2
timl
Super User
Super User

@wolfrat 

The most likely problem is that the data type of your Fortshritt column in Excel is text, rather than floating point.

I guess you're running Power Apps in a non English locale (German?), so Power Apps is recongising 0.5 as 5, and 0.75 as 75.

If this is the case, the following should provide a more accurate result.

Value(ThisItem.Fortshritt, "en") * 100

If you're running the Power Apps Studio in German, you'll need to replace the , with a ;

 

Value(ThisItem.Fortshritt; "en") * 100

 

 

This was it, timl. Thank you so much for a quick solution.

 

kind regards from the alps.

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (1,999)