You are viewing limited content. For full access, please sign in.

Question

Question

New Designer - Stored Procedure with Auto Fill button. Possible to click with JavaScript?

asked on December 12, 2024

I have a stored procedure that forces the Auto Fill button to show on the form. There is no checkbox in lookup rules to choose if it is there or not - it just shows. Is this expected behavior?

Now onto workarounds... how to use javaScript to click it? I don't see anything in the LFForm object documentation. But... it looks like (maybe) @████████ found a way on this thread?

The stored procedure should just autofill, right? I have others that do that, so not sure what the difference is here. 

Thanks all :)

 

0 0

Replies

replied on December 12, 2024

Are you sure the autofill button is grayed out? Could you show me what you mean? When there are two or more "When" conditions the option is displayed but I'm not sure what would cause it to force you to use it.

As for the second part of your question, you cannot click/focus/blur/change pages/add rows/auto-submit automatically via JS in the new form designer. Yet... 

2 0
replied on December 12, 2024 Show version history

Thanks Zach. 

The Auto Fill button is not grayed out, it is clickable and the only way for the data load. I am wanting it to simply load without clicking the button:


Here is the SP in lookup rules.

Top:


Bottom:


My best guess was that since the SP is returning 2 SELECT rows, that was the cause of the Auto Fill button being there...

I tried to get it out of there by wrapping it in another SP, but no luck. Not even sure if that matters??

0 0
replied on December 12, 2024

The option I was referring to being grayed out is this one. In my testing of the latest versions of v11 and v12 modern and classic forms, a stored procedure with two "Use" values has the option to enable the autolookup button but it is not forced.

Modern

Classic

1 0
replied on December 12, 2024

So I need to use a second 'use'? I only have one currently.

 My pics above are from the modern designer v11. 

First I'll try and delete it and recreate it. 

0 0
replied on December 12, 2024

That shouldn't be the case. You should only see the autofill button on the form if there are more than 1 'use' in the lookup rule. Just using a single one form me does not show the autofill button

1 0
replied on December 13, 2024 Show version history

Well, you gave me something to try that is working. I don't think this is intended behavior though. 

I added a dummy parameter into my SP. That got the 'Show auto fill button' checkbox to show. Then I can de-select it and the data loads perfectly:



I tried removing it and returning the number of use/parameters back to 1, but no checkbox:
 

@████████, can you reproduce this in the new designer? or am I just special ha ha...

 

0 0
replied on December 16, 2024

I cannot reproduce it, although the content our stored procedures return may be different. I am just doing a simple select a few columns I dont have any special return values or anything like that

1 0
replied on December 17, 2024

Thanks, that helps clarify where the issue is. 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.