cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Kristoffer88
Advocate I
Advocate I

Getting the type of an Input Parameter at runtime

Hello.

When trying to get the type of an input parameter (eg. SingleLine.Text), there is no information on context.parameters.TextProperty.type.

When doing the same in the harness, the information is there.

Does anyone know if there is any other way to get the type of an input parameter at runtime?

7 REPLIES 7
a33ik
MVP

Hello,

I used the same approach in this component - https://github.com/AndrewButenko/CompositeAddress_PCF/blob/master/CompositeAddress/index.ts and it worked fine for me. I was able to check if the bound field is a string or optionset.

Thanks.

 

I will take a look again and reply back.

 

 

Hi Again.

 

I can see  that this issue only appear with additional properties on a PCF that targets data-sets and not fields.

 

forum.png

 

Kristoffer88
Advocate I
Advocate I

Hope i can find a solution to this problem.

 

 

@Kristoffer88 

 

Why do you need to get this info dynamically? It doesn't change. 

I need this for a configuration module for our components.

 

We need some more advanced way to configure our components, like lookup fields etc.

 

To make it as easy as possible, i want to fetch the configuration that is used now, and parse it into the configuration module and then only override the inputs that is not supported ( Lookup.Single ) and other things

@Kristoffer88 

 

You can try reading the ControlManifest.xml file and getting the information that way.

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Apps Community Call

Monthly Power Apps Community Call

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

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Users online (61,705)