Gives me a great idea of using this with the excel AI toolkit to create an AI data validation to validate reliable AI prompts to create consistant output and flag halussiations (rate scal 1 to 5) and only use 5 for and decisions
That is a really great idea. Thanks so much for sharing. Within the next month I am going to be adding VBA Code Optimizer to the AI Addin. I am sure you will love that too. Thanks again for your continued support.
HI and thanks very much. I do not have one on Data Validation - Date values, however I do have a training on Mastering Dates with VBA Here: th-cam.com/video/AyO2ysfGfMk/w-d-xo.html I hope this helps and thanks so much.
Thanks a lot for anothert helpful video. (I downloaded the Excel file too) I have a question: The VBA codes don't restrict any value (over 100 or below 1) if I copy it from a cell and paset in cell G2. How may I restrict Pasting wrong value?
Hi and thanks so much. I am glad you got the file. If you create a data validation with VBA, you can then copy and paste that cell validation to another cell and it will also contain the same validation. If you don't want to allow copy and paste, this can also be disabled. I hope this helps and thanks so much.
Hi and thanks, you can try something like this: Private Sub Worksheet_Change(ByVal Target As Range) ' Check if the changed cell is G2 If Not Intersect(Target, Me.Range("G2")) Is Nothing Then ' Disable pasting by clearing G2 if changed Application.EnableEvents = False Application.Undo ' Undo the change, preventing the paste MsgBox "Pasting into cell G2 is not allowed.", vbExclamation Application.EnableEvents = True End If End Sub Private Sub Worksheet_SelectionChange(ByVal Target As Range) ' Check if G2 is selected If Not Intersect(Target, Me.Range("G2")) Is Nothing Then ' Check if the clipboard has data (indicating a potential paste) If Application.CutCopyMode False Then Application.CutCopyMode = False ' Clear the clipboard MsgBox "Copying and pasting into cell G2 is disabled.", vbExclamation End If End If End Sub
Hi and thanks. I have checked the link and seems ok (there may have been an initial issue) Please try here www.excelforfreelancers.com/data-validation-with-vba/ I hope this helps and thanks so much.
Great presentation! Thanks.
Thank you so very much, I really appreciate that and I am so glad you enjoyed the training
Gives me a great idea of using this with the excel AI toolkit to create an AI data validation to validate reliable AI prompts to create consistant output and flag halussiations (rate scal 1 to 5) and only use 5 for and decisions
That is a really great idea. Thanks so much for sharing. Within the next month I am going to be adding VBA Code Optimizer to the AI Addin. I am sure you will love that too. Thanks again for your continued support.
❤❤❤ Excel lovers assemble here
Thank you so very much, I really appreciate that Nazar and great to have you here
Very useful tips thanks
Thanks so very much, I really appreciate that.
Great tips, do you have one based on date validation, always seem to pick up issues on this
HI and thanks very much. I do not have one on Data Validation - Date values, however I do have a training on Mastering Dates with VBA Here:
th-cam.com/video/AyO2ysfGfMk/w-d-xo.html
I hope this helps and thanks so much.
Thanks a lot for anothert helpful video. (I downloaded the Excel file too)
I have a question:
The VBA codes don't restrict any value (over 100 or below 1) if I copy it from a cell and paset in cell G2. How may I restrict Pasting wrong value?
Hi and thanks so much. I am glad you got the file. If you create a data validation with VBA, you can then copy and paste that cell validation to another cell and it will also contain the same validation. If you don't want to allow copy and paste, this can also be disabled.
I hope this helps and thanks so much.
@ExcelForFreelancers
Thanks a lot.
Could you give me an idea, how to disable 'paste' in cell G2.
Regards
Hi and thanks, you can try something like this:
Private Sub Worksheet_Change(ByVal Target As Range)
' Check if the changed cell is G2
If Not Intersect(Target, Me.Range("G2")) Is Nothing Then
' Disable pasting by clearing G2 if changed
Application.EnableEvents = False
Application.Undo ' Undo the change, preventing the paste
MsgBox "Pasting into cell G2 is not allowed.", vbExclamation
Application.EnableEvents = True
End If
End Sub
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
' Check if G2 is selected
If Not Intersect(Target, Me.Range("G2")) Is Nothing Then
' Check if the clipboard has data (indicating a potential paste)
If Application.CutCopyMode False Then
Application.CutCopyMode = False ' Clear the clipboard
MsgBox "Copying and pasting into cell G2 is disabled.", vbExclamation
End If
End If
End Sub
@@ExcelForFreelancersThank you so much Randy!
That's going to help me a lot.
Grateful to you.....
For sure, you are very welcome
Sorry, I can't access the book through the link, the error is page not found
Hi and thanks. I have checked the link and seems ok (there may have been an initial issue)
Please try here
www.excelforfreelancers.com/data-validation-with-vba/
I hope this helps and thanks so much.