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

Data type of column when using patch function to excel file

Hello, I am still a newbie in PowerApps and encountered some problems while creating an app. I had a Text Input Box to allow user to input an amount and when the user click a button, it will patch the amount into an excel data file. 

 

The amount is generally stored as number format in the excel file. However, i noticed that when the total number of digits including decimals exceed 9, the number will be stored as text instead.

 

Can i check whether is there any method to ensure that the amount will be stored as number format in excel no matter how many decimal places are there?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @jackyyong ,

Based on the needs that you mentioned, I afraid that there is no way to achieve your needs in PowerApps directly, this issue is related to Excel itself.

 

As an fixed solution, you could consider change the format the "Amount" column in your Excel table as below:

3.JPG

Select the Amount column in your Excel table, then expand the number Format Dropdown box, choose "More Number Formats..." option, then select Number, change the Decimal Places into a proper value.

Note: Please make sure you have formatted the Amount column as Number type already in your Excel table before your create your canvas app.

 

If the issue still exists, please consider generate a new app based on your Excel table, then try it again, check if the issue is solved.

 

Note: If you have formatted the "Amount" column as Number type before generating canvas app, after you generated your app based on your Excel table, the Amount field Text Box would be formatted as Number Text Box as below:

4.JPG

force you entering number value within the Text Input Box.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Community Support
Community Support

Hi @jackyyong ,

Based on the needs that you mentioned, I afraid that there is no way to achieve your needs in PowerApps directly, this issue is related to Excel itself.

 

As an fixed solution, you could consider change the format the "Amount" column in your Excel table as below:

3.JPG

Select the Amount column in your Excel table, then expand the number Format Dropdown box, choose "More Number Formats..." option, then select Number, change the Decimal Places into a proper value.

Note: Please make sure you have formatted the Amount column as Number type already in your Excel table before your create your canvas app.

 

If the issue still exists, please consider generate a new app based on your Excel table, then try it again, check if the issue is solved.

 

Note: If you have formatted the "Amount" column as Number type before generating canvas app, after you generated your app based on your Excel table, the Amount field Text Box would be formatted as Number Text Box as below:

4.JPG

force you entering number value within the Text Input Box.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Hi @v-xida-msft, thank you for your solution. It works perfectly fine for me 😄

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (61,668)