cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
testaccPA
Helper III
Helper III

powerapps onnote error

hi, i want to play around with the possibilities of powerapps and onnote.
But I absolutely don't know why this doesn't work with the GetPagesInSection method.

The following scenario:


I have a normal onnote with sections, pages and content.

Now I want to be able to display and select everything with ComboBoxes (to add a message later if necessary).

 

My combo boxes:
ComboBox_notebook
in Items: 'OneNote (Business)'. GetNotebooks ()

 

ComboBox_section
in item: If (! IsEmpty (ComboBox_notebook.Selected.Key); 'OneNote (Business)'. GetSectionsInNotebook (ComboBox_notebook.Selected.Key) .value)

 

here is the error:
ComboBox_Page
in items: 'OneNote (Business)'. GetPagesInSection (ComboBox_notebook.Selected.Key; ComboBox_section.Selected.id) .value

 

error message: the section Id is invalid. if a custom value was entered, please try selecting from the supplied values.

 

onNote fehler.png

any idea?

 

 

1 REPLY 1
Pstork1
Dual Super User III
Dual Super User III

Several things I would change from the default to get this to work. 

  1. First set all the ComboBoxes so that SelectMultiple = false.
  2. Your Items formula for the Section Combobox should be
    If(!IsBlank(ComboBox_notebook.Selected.Key);'OneNote(Business)'.GetSectionsInNotebook(ComboBox_notebook.Selected.Key).value)​

    Is Empty is for a table.  You are testing the existence of a single value

  3. Change the DisplayFields and SearchFields property of the Section combobox to ["name"].  Otherwise it will populate the dropdown with the ID of the section.


-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

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

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Top Kudoed Authors
Users online (41,676)