Forum Discussion

Inanna80's avatar
Inanna80
Copper Contributor
Jan 09, 2023

How to set up a field in PowerApps, which can be used as calculation field or as a input field?

Hi, 

I would like to set up a field, which can be used in a flexible way:

  • either it is an output field of the calculation:   e.g. Costs + Margin = selling price. The selling price gets calcultaed automatically by giving the inputs: Costs and margin
  • or as a simple input field of the selling price, without giving any information on costs and margin. 

Does anyone has an idea if this featue exists? 

  • SvenSieverding's avatar
    SvenSieverding
    Bronze Contributor
    Hi,

    just create three TextFields (Cost,Margin and "Selling Price") and switch them to "Number"-Format.

    Then set the "default" property of "Selling Price" to "Cost.Text+Margin.Text"

    If you now update
    1) "Selling Price" : then you get that number
    2) "Cost" or "Margin" : then "Selling Price" contains the sum of "Cost" and "Margin"

    Best Regards,
    Sven
    Best Regards

Resources