There are numerous practical solutions, such as calling their supervisor, or calling the employee of yours who set up this arrangement, or providing some kind of proof that you are the ultimate boss. From a legal perspective, (1) the guards are acting as your agents which gives them some authority to exclude people but (2) you can revoke that authority. There are many things that security guards can do to keep people out, and some of them would be technically illegal (others would be blatantly illegal and we can skip that). I'll cite Washington state criminal law, and you can probably find analogs in Mexican law.
First, are they on your property? If you revoke permission to be in the property, that is trespass:
(9A.52.070: Criminal trespass in the first degree.)
(1) A person is guilty of criminal trespass in the first degree if he
or she knowingly enters or remains unlawfully in a building.
(9A.52.080 Criminal trespass in the second degree.)
(1) A person is guilty of criminal trespass in the second degree if he
or she knowingly enters or remains unlawfully in or upon premises of
another under circumstances not constituting criminal trespass in the
How are they stopping you? If they are physically stopping you, that is assault (battery), the severity of which depends in the degree of force:
(9A.36.031: Assault in the third degree)
(1) A person is guilty of assault in the third degree if he or she,
under circumstances not amounting to assault in the first or second
(d) With criminal negligence, causes bodily harm to another person by
means of a weapon or other instrument or thing likely to produce
bodily harm; or (f) With criminal negligence, causes bodily harm
accompanied by substantial pain that extends for a period sufficient
to cause considerable suffering; or
(9A.36.041: Assault in the fourth degree)
(1) A person is guilty of assault in the fourth degree if, under
circumstances not amounting to assault in the first, second, or third
degree, or custodial assault, he or she assaults another.
Another possibility is 9A.40.040 Unlawful imprisonment:
(1) A person is guilty of unlawful imprisonment if he or she knowingly
restrains another person.
They don't have to actually use force, they can simply threaten to do so, which is
(1) A person is guilty of coercion if by use of a threat he or she
compels or induces a person to engage in conduct which the latter has
a legal right to abstain from, or to abstain from conduct which he or
she has a legal right to engage in.
Though the police are supposed to enforce the law, they may decline to act if it us not clear to them that there is a violation of the law. It would not really help to prove that you own the company, because nobody really knows the relationship between the company and the building – maybe you own the company, someone else owns the building, and you've been legally evicted. So looking for a legal solution isn't the most productive use of your time. Instead, make sure you can contact the guard supervisors, company colleagues in charge of security, and carry your ID badge with you.
Let us suppose that the guard company, guards, and your security chief are conspiring to rob you. The long-term and slow solution is to get a court order plus sue the pants of everybody who has done you wrong. The crux of the matter for the police would be, who owns the building (what evidence do you have that you own the building). I could actually show the police proof that I own my house. If the crooked security chief shows up with a document saying that he owns the building, you'd be stuck. But otherwise, establishing ownership of the building should cause them to stop the guards from blocking you. Unless the cops are part of the conspiracy. There's nothing you can do to absolutely protect yourself against a well-planned conspiracy (they make movies based on that).