# Limit the multi image add quantity

**URL:** <https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118>\
**Category:** Ask for Help\
**Created:** [May 6, 2024, 3:15pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118 "2024-05-06T15:15:54Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rimatcom](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/rimatcom/32/32285_2.png) [@Rimatcom](https://community.glideapps.com/u/Rimatcom)\
**Post date:** [May 6, 2024, 3:15pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/1 "2024-05-06T15:15:54Z")

</div>

Hi! Is there a way to limit the number of images a user uploads using the Image Picker component?

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/7/e/7e101638562999b761c0d2a00c866d7997b9159d.jpeg)

Thanks

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [May 6, 2024, 3:21pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/2 "2024-05-06T15:21:57Z")

</div>

The only way I can think of to do this would be to use a Custom Form. The images would then be loaded into a User Specific Multiple Images column, you could do a rollup on that to get a count, and then show a message to the user and prevent them from submitting the form if the count exceeds whatever threshold you set.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 6, 2024, 3:38pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/3 "2024-05-06T15:38:32Z")

</div>

You can create a rollup column and display it through a message with the hint component.

 ![Screenshot 2024-05-06 at 22.29.25](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/7/2/724b9ee9e2862f40785121b573fb19d04d13720e.jpeg)

 ![Screenshot 2024-05-06 at 22.31.55](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/6/2/6228a17c2dd7b6e66b31d3d43085388cce0ecdcb.jpeg)

And prevent submission through the method in the following link:

> [@Exploring the Enhanced Capabilities of Glide's Native Form](https://community.glideapps.com/t/exploring-the-enhanced-capabilities-of-glides-native-form/69876):
>
> I want to share about the additional capabilities that we can achieve with Glide’s native form. What I have tested with the help of CSS is that native forms can also be applied for validation. Create your validation in the table columns and present it through messages via the “hint” component. Add the visibility conditional and the class “prevent-submit” to these hint components. Add the following CSS code: /\*Container Form\*/ #page-root:has(.prevent-submi…

---

<div class="post-metadata">

**Author:** ![Rimatcom](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/rimatcom/32/32285_2.png) [@Rimatcom](https://community.glideapps.com/u/Rimatcom)\
**Post date:** [May 6, 2024, 3:46pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/4 "2024-05-06T15:46:31Z")

</div>

Thanks but this is just a warning message right?

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 6, 2024, 3:47pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/5 "2024-05-06T15:47:37Z")

</div>

For prevent submission follow the link above.

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [May 6, 2024, 4:42pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/6 "2024-05-06T16:42:47Z")

</div>

@Himaladin I admittedly haven’t tried your method yet. I think Robert’s video demonstrating your method only relied on basic columns instead of computed columns. It’s always been my understanding that computed columns were inaccessible or not computed from within a native form.

Based on what you are saying here, and what you had shown back in January, would it be correct that computed columns do actually compute within a native form, but are only accessible for visibility conditions? I have a different use case where I need to submit computed columns with my form, but I’ve never been able to access them in a native form, so I’ve had to use a custom form instead. Just curious if I’m missing something that I didn’t know was possible.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 6, 2024, 5:17pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/7 "2024-05-06T17:17:25Z")

</div>

> [@Jeff\_Hager](#):
>
> I have a different use case where I need to submit computed columns with my form, but I’ve never been able to access them in a native form

Yes… I don’t know how deep/complex it is… but almost all the computed columns I use work well, as long as you return them as true-false or empty-not empty, except for displaying their values. I mentioned at the end of my thread, even dates and times can be used. I have nested validations (many columns) as long as they ultimately result in true-false, they also work well to display the hint component.

Although there are many limitations imposed by Glide, I feel there is a spirit wandering around in the application. The Hint component is just one of its manifestations. You can also use other components and if assisted by CSS, making this new application is quite enjoyable.

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [May 6, 2024, 5:42pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/8 "2024-05-06T17:42:38Z")

</div>

That’s good to know. Too bad they don’t make some of that stuff more accessible since they are doing the computations. Could eliminate almost any need for custom forms.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 6, 2024, 5:50pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/9 "2024-05-06T17:50:11Z")

</div>

> [@Jeff\_Hager](#):
>
> Too bad they don’t make some of that stuff more accessible since they are doing the computations.

Yes… I remember my professor’s words: “what ought to be” and “Deontic.”

Do you remember the pseudo :has I used, and its usage always being rejected by GPT? Sometimes this pseudo is like the end of the Matrix movie, where Keanu Reeves can fly anywhere, transcending all the matrices.

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [May 7, 2024, 12:28am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/10 "2024-05-07T00:28:02Z")

</div>

I use Himaladin’s method in various apps. It works very well in most cases, except in edit forms. It seems like they don’t calculate columns “in advance” for edit forms only.

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [May 7, 2024, 12:30am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/11 "2024-05-07T00:30:41Z")

</div>

Also good to know. Good things to have in our toolbox.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 7, 2024, 12:37am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/12 "2024-05-07T00:37:51Z")

</div>

Can you please share an explanation of what it’s like? I don’t quite understand the case. Perhaps this will provide an opportunity to delve deeper.

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [May 7, 2024, 12:40am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/13 "2024-05-07T00:40:13Z")

</div>

I use it to block emails from being duplicated.

I set up a query in my Users table, pointing to the same Users table, filter by email is this row \> email and rowID is not this row \> rowID.

I have a hint component that tells people that there’s a duplicate and prevent submission based on your method, if that query is not empty.

It works in the add form, not the edit form.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 7, 2024, 12:53am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/14 "2024-05-07T00:53:38Z")

</div>

So you check if there are duplicate emails that have already occurred in the user table, and prevent any further action to submit something?

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [May 7, 2024, 1:02am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/15 "2024-05-07T01:02:29Z")

</div>

Yep, in my case it was for admins who add new clients. They can not add new clients with an email that already exists in the Clients table.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 7, 2024, 1:04am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/16 "2024-05-07T01:04:33Z")

</div>

Alright. I’ll try it when I have some free time.

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [May 7, 2024, 1:05am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/17 "2024-05-07T01:05:08Z")

</div>

Thanks a lot. I owe you so much for creating that method, I learned to use :has since that day.

---

<div class="post-metadata">

**Author:** ![Himaladin](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/himaladin/32/71023_2.png) [@Himaladin](https://community.glideapps.com/u/Himaladin)\
**Post date:** [May 7, 2024, 11:33am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/19 "2024-05-07T11:33:52Z")

</div>

I got the answer. Is there any mistake?  
@Jeff_Hager, @ThinhDinh, @Darren_Murphy  
~~Obviously, you shouldn’t use a query to check for duplicate emails because the query value won’t change even if the email in the entry is already being changed.~~  
Here, I use jointlist and JavaScript to extract the duplicate emails, then return them as a boolean value.  
I also want to ask, does this duplicate email cause any issues in the application during sign-in?

 ![Screenshot 2024-05-07 at 18.27.43](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/0/2/02c796c62830132bf7c7b469c48e5f4c6dc70370.png)

 ![Screenshot 2024-05-07 at 17.54.12](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/d/a/dafe73ca880bebc03d1cbe2c97c6bf702c982d77.png)

 ![Screenshot 2024-05-07 at 17.54.23](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/3/c39ac7d1afe22a9942fad1eef4c6c7ebf908d083.png)

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [May 7, 2024, 11:53am UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/20 "2024-05-07T11:53:30Z")

</div>

> [@Himaladin](#):
>
> Obviously, you shouldn’t use a query to check for duplicate emails because the query value won’t change even if the email in the entry is already being changed.

Yeah, you can use a Query.

- Email is This row-\>New email
- RowID is not This row-\>RowID

 ![CleanShot 2024-05-07 at 19.52.54@2x](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/8/e/8eb9fe51ff1e36e5154ed008c986a4705c87c269.png)

---

<div class="post-metadata">

**Author:** ![Eric\_Penn](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/eric_penn/32/73888_2.png) [@Eric\_Penn](https://community.glideapps.com/u/Eric_Penn)\
**Post date:** [May 7, 2024, 12:02pm UTC](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118/21 "2024-05-07T12:02:54Z")

</div>

He’s inside of a Native Edit screen and going to restrict the submit button using css based on the visibility of hint component… so smart

[Next page](https://community.glideapps.com/t/limit-the-multi-image-add-quantity/73118.md?page=2)
