Make more than one condition Annotation Asp.net mvc

Asked

Viewed 61 times

1

I have my class

and in it I have a property

public TipoPessoa TipoPessoa {get;set;}

The same is an enumerator that has value "Physical and Juridical"

And I own a property that’s CNPJ or CPF

public string Cpf_Cnpj {get;set;}

How do I make it condition at time to validate in annotationion?

1 answer

1


Browser other questions tagged

You are not signed in. Login or sign up in order to post.