LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Validation Object error

None found so far.
I will (heavyheartedly) use your code.
No offence! Have a nice day!
Peter

"Tom Ogilvy" wrote:

I would disagree.

Let's see your elegant approach.

--
regards,
Tom Ogilvy


"Peter Zinniker" wrote:

Uff, not very elegant coding.
Anyway thank you very much for the hint.
Peter

"Tom Ogilvy" wrote:

Something like this:

Sub AABB()
Dim s As String
Set target = ActiveCell
s = ""
On Error Resume Next
s = target.Validation.Formula1
On Error GoTo 0
If s < "" Then
MsgBox s
Else
MsgBox "No validation"
End If
End Sub


--
Regards,
Tom Ogilvy


"Peter Zinniker" wrote:

I want to read the Formula1 property of a validation object of the cell Target.
Target.Validation.Formula1 produces an "Application-defined or
object-defined error" if Target don't have a validation rule.
How cant I check whether a validation list is defined?



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
runtime error '1004' application or object defined error Janis Excel Programming 4 November 18th 09 03:01 PM
Run Time Error 1004: Application or Object Defined Error BEEJAY Excel Programming 4 October 18th 06 04:19 PM
Object Variable Not Set Error on Selection object Jean Excel Worksheet Functions 3 July 24th 06 06:45 PM
Error 1004, Application-definded or object-defined error Mirco Wilhelm[_2_] Excel Programming 9 January 7th 06 04:56 PM
run-time error '1004': Application-defined or object-deifined error [email protected] Excel Programming 5 August 10th 05 09:39 PM


All times are GMT +1. The time now is 09:21 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"