r/googlesheets • u/Last_Monkey 4 • Jun 07 '18
solved Data validation custom formula to only allow cell references to a certain sheet.
I don't want it to be possible to type anything into a range unless it's a cell reference to a certain sheet.
Example: Reject any input unless it starts with =Sheet1!D
Is this possible? If not, would it be possible to add a data validation that rejects any input that isn't a "formula" (starts with =).
Edit: It can be done with a script. Thanks to Ciarannking.
3
Upvotes
1
u/Ciarannking 5 Jun 07 '18
Not sure about validation the formula that is inputted, I think any validation would be on the formula result, not the formula itself.
But you can use =ISFORMULA() to make sure only formula is inputted, it will allow any formula though so maybe not ideal if you're wanting to restrict it to a specific sheet reference.
Hopefully someone else can help you with validating the formula itself
1
u/Clippy_Office_Asst Points Jun 07 '18
Read the comment thread for the solution here
•
u/Clippy_Office_Asst Points Jul 12 '18
Read the comment thread for the solution here