I want a button to be placed in gallery onclick will duplicate the item in the list. what should be the formula that needs to be used on the Onclick in button
Solved! Go to Solution.
On the OnSelect of the button inside the gallery:
Set(CollectionName,ThisItem);
Patch('[dbo].[DataSource]',Defaults('[dbo].[ DataSource]'),
{FirstName: CollectionName. FirstName,
ReceipientName: CollectionName.ReceipientName,
FullName: CollectionName.FullName,
EntryDate: CollectionName.EntryDate})
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Change Label1.Text to the textbox or Label1.Text in the Gallery
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Please follow this:
2. Insert an Icon1 or button1 into YourGallery1
Set the Onselect of the Icon1 to; Select(Parent);Set(CollectionName,ThisItem) . This will create a variable of the item clicked
3. Insert a another button2 on your screen not in the gallery and put the onselect to the following Patch:
Patch('[dbo].[DataSource]',Defaults('[dbo].[ DataSource]'),
{FirstName: CollectionName. FirstName,
ReceipientName: CollectionName.ReceipientName,
FullName: CollectionName.FullName,
EntryDate: CollectionName.EntryDate})
Note; Point 2 above would create the collection1 while point 3 would insert the created items in the collection into your dataSource
Kindly change the datasource and column names to yours.
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Can we make the duplication in one click i.e in one button
On the OnSelect of the button inside the gallery:
Set(CollectionName,ThisItem);
Patch('[dbo].[DataSource]',Defaults('[dbo].[ DataSource]'),
{FirstName: CollectionName. FirstName,
ReceipientName: CollectionName.ReceipientName,
FullName: CollectionName.FullName,
EntryDate: CollectionName.EntryDate})
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Change Label1.Text to the textbox or Label1.Text in the Gallery
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Thank you very much
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
User | Count |
---|---|
206 | |
187 | |
82 | |
51 | |
37 |
User | Count |
---|---|
288 | |
244 | |
121 | |
76 | |
55 |