
30 Cal.App.2d 641 (1939)
ANTHONY MATTOS, Petitioner,
v.
THE SUPERIOR COURT OF MERCED COUNTY et al., Respondents.
Civ. No. 6173. 
California Court of Appeals. Third Appellate District.  
February 3, 1939.
 J. L. Royle for Petitioner.
 U.S. Webb, Attorney-General, Eugene M. Elson, Deputy Attorney-General, and F. A. Silveria, District Attorney, for Respondents.
 Thompson, J.
 The petitioner seeks by means of certiorari to annul an order of the Superior Court of Merced County, adjudging him to be guilty of contempt for violating an injunction issued in a suit to restrain certain associations and individuals named as defendants therein from interfering with the employees and agents of the department of agriculture of California in testing cattle under the provisions of the Bovine Tuberculosis Act of California. (Agr. Code, div. 2, chap. 3, art. III.)
 The suit which was then pending before that court is entitled "The People of the State of California, Plaintiff, v. Western Cooperative Dairymen's Union, etc., et al., Defendants." This petitioner was acting as president of the above-named Dairymen's Union. The injunction was issued *645 October 25, 1938, restraining the defendants, their "officers, agents, members, attorneys, servants and employees" from directly or indirectly resisting, obstructing or refusing to permit the administration of the tuberculin test to dairy cattle by the agents of the department of agriculture of California, pursuant to the provisions of article III, chapter 3 of division 2 of the Agricultural Code of California.
 The injunction was not personally served on the petitioner, but at the time of the application therefor he was represented in court by the attorney for the dairymen's association, of which he was president.
 The contempt proceeding was presented to the court upon the affidavit of George Smallbone, a veterinarian in the employ of the animal industry division of the department of agriculture of California, which affidavit avers that the accused, Anthony Mattos, was a member of the Western Cooperative Dairymen's Union, who was possessed of a herd of dairy cows in Merced County, and that on September 24, 1938, the affiant visited his premises and notified him of the intention of the department to make a tuberculin test of his cattle the following day and that affiant then directed him to "have said cattle properly confined in stanchions, or otherwise, so that the said test could be administered"; that affiant visited the premises of the petitioner the following day for the purpose of administering the tuberculin test to said cattle, but that the petitioner failed and neglected to place the cattle in stanchions as requested.
 The affidavit fails to aver that the petitioner received either actual or constructive notice of the injunction. It was not averred, nor is it contended that Anthony Mattos performed any act to obstruct or interfere with the testing of the cattle by the authorities. The only thing complained of in the conduct of the petitioner, upon which the adjudication of contempt depends, was his failure to place his cattle in the stanchions of his corral as the veterinarian requested him to do.
 This petitioner filed in the contempt proceedings a counteraffidavit. Oral evidence was also adduced. From that showing it appears without conflict that the petitioner is the president of the Western Cooperative Dairymen's Union; that he owns a herd of twenty-two dairy cattle in Merced *646 County, which were confined in a corral eighty feet square, equipped with several stanchions; that he also possessed a barn containing other stanchions, but that the barn was then temporarily filled with walnuts during the harvesting season, leaving no available space therein for the cattle. The evidence is uncontradicted that the petitioner did nothing to interfere with affiant's free use and control of the petitioner's cattle, his corral, the stanchions therein or of his premises for the purpose of tuberculin testing the animals pursuant to the Bovine Tuberculosis Act. All that appears from the record is that the petitioner failed to personally confine his cattle in the stanchions as requested, although they were enclosed in the corral. Upon that evidence the court adjudged the petitioner to be guilty of contempt for wilfully violating the terms of the injunction.
 [1] Certiorari will lie to vacate an order of court adjudging an individual to be guilty of contempt where it appears from the record that the court lacked jurisdiction or that it exceeded its jurisdiction. (5 Cal.Jur., p. 955, sec. 50.) Contempt proceedings are criminal in their nature, and should be strictly construed. When the record fails to show that the court had jurisdiction or when it affirmatively appears that it lacked jurisdiction of the party or proceeding, upon certiorari the order adjudging an accused person to be guilty of contempt should be annulled. (Frowley v. Superior Court, 158 Cal. 220 [110 P. 817]; 5 Cal.Jur., p. 956, sec. 50.)
 [2] In cases of constructive or indirect contempt committed without the presence of the court, the affidavit constitutes the complaint and unless it contains a statement of facts which show the commission of contempt by the accused person the court is without jurisdiction to pronounce the judgment of contempt and such an order should be vacated on certiorari. (Frowley v. Superior Court, supra.)
 [3] Although the petitioner was not a personal party to the action upon which the contempt proceeding was based, he was the president of the defendant Western Cooperative Dairymen's Union, and as such appeared by attorney in the proceeding and opposed the application for the injunction. He is, therefore, deemed to have had notice thereof and as such officer of the association he is bound thereby. *647
 [4] The general rule is that one may be guilty of contempt who violates an injunction, although he is not a party to the original action, provided he is included in the injunction as an officer, employee or agent of a party defendant, when he has either actual or constructive notice thereof. (Golden Gate Cons. Hydraulic Min. Co. v. Superior Court, 65 Cal. 187 [3 P. 628]; In re Morford, 137 Cal.App. 662, 666 [31 PaCal.2d 406]; In re Simoniello, 6 Cal.App.2d 425 [44 PaCal.2d 402]; 5 Cal.Jur., p. 916, sec. 21; 15 A.L.R. 387, note.) Officers of corporations or associations may be punished in contempt proceedings for violation of an injunction. It is common practice and proper to enjoin not only the corporation or association, but also its officers, employees and agents. (5 Cal.Jur., p. 894, secs. 5 and 6.) [5] It is not necessary to actually serve an injunction upon an accused person in order to hold him guilty of contempt for the violation of its terms. When the accused person appears personally in court or is represented by an attorney at the time the injunction is heard and granted, he is deemed to have actual notice thereof. (Transbay Const. Co. v. Superior Court, 12 Cal.App.2d 565, 569 [55 PaCal.2d 1237]; Romine v. Cralle, 83 Cal. 432 [23 P. 525].)
 [6] In the present case it is not claimed the petitioner had no actual notice of the injunction. It is merely asserted the affidavit for contempt fails to aver that he had notice thereof. The reciting of that jurisdictional fact in the affidavit was not necessary. The court which tries the original action will take judicial notice of the fact that the accused person was present in court personally or by attorney and participated in the hearing at which the injunction was granted. [7] In the present case the injunction recites that the order to show cause came on regularly for hearing in open court on September 19, 1938, and that "the defendants, and each of them", were represented by their attorney, J. L. Royle, Esq. In the case of Ex parte Ah Men, 77 Cal. 198 [19 P. 380, 11 Am.St.Rep. 263], it is said:
 "Although contempt of court is a specific criminal offense, and a judgment of conviction thereof the same as a judgment in a criminal case (Ex parte Hollis, 59 Cal. 405, 408), the practice has always been to prosecute a matter of contempt in the cause or proceeding out of which it arose, and not as a separate proceeding, with a title of its own. It *648 is, therefore, unnecessary in the affidavit to set forth the pendency of the cause or proceeding, or the provisions of the order which has been violated. The court takes judicial notice of those matters."
 Likewise, in the case of Mitchell v. Superior Court, 163 Cal. 423 [125 P. 1061], it is said:
 "This proceeding, although partaking of some of the characteristics of a prosecution for a criminal offense, is properly entitled in the style of the divorce proceeding itself and not as a separate action. The court takes cognizance of the pendency of the main cause and there is no necessity of setting forth in the affidavit that fact or 'the provisions of the order which has been violated'."
 The jurisdictional requirement that the accused person must have had notice of the injunction as a necessary prerequisite to an adjudication of contempt sufficiently appears in this record.
 [8] There is no merit in the petitioner's contention that the injunction which is the basis of this contempt proceeding became functus officio pending the appeal from a judgment in another suit in which the Dairymen's Union, of which he is president, and other parties challenged the constitutionality of the California Bovine Tuberculosis Act. That was an entirely different action. It had no bearing on the validity of the injunction which forms the basis of the contempt proceeding. That suit was decided against this petitioner. The constitutionality of the act was upheld, and the judgment has been subsequently affirmed. (Affonso Bros. v. Brock, 29 Cal.App.2d 26 [84 PaCal.2d 515].)
 [9] It affirmatively appears, however, that the petitioner did not violate the express language of the injunction which prohibits him "from in any manner, or at all, directly or indirectly, refusing to permit or allow, or resisting the administration of the tuberculin test". It does appear that the petitioner failed and neglected to assist the officer in making the tuberculin test of his cattle by placing them in the stanchions as requested. But the injunction contains no such requirement to aid or assist the officers in that manner, or at all. The cattle were confined within an enclosure eighty feet square, which contains ten or more stanchions in which the petitioner had a right to assume the officers could easily *649 place the cattle for the purpose of making the tuberculin test. At least the injunction required no affirmative action on the part of the petitioner.
 [10] It is true that section 228 of the Agricultural Code provides that:
 "It is unlawful to: * * *"
 "(b) Neglect or fail to properly secure and restrain any bovine animal to the tuberculin tested, or under tuberculin test, for examination, injection, observation, or other procedures pertaining to a tuberculin test."
 It is elsewhere made a misdemeanor for the owners of cattle to obstruct or prevent officers from the performance of their duties in testing cattle or for wilful failure to aid and assist them, when so requested, in administering tuberculin tests to animals. The injunction, however, made no reference to the above-quoted section, nor may any reasonable construction of the language of that injunction be said to imply that the petitioner or any other owners of cattle were required to affirmatively perform acts to personally aid or assist the officers in testing the cattle. The petitioner is not charged with violating section 228 of the Agricultural Code. He was merely charged with violating the prohibitory language of the injunction. The injunction does not include the offense of which the petitioner was found guilty.
 [11] An accused person may not be held guilty of contempt for violating the terms of an injunction which is uncertain or ambiguous with respect to its provisions. To hold one guilty of contempt for violating an injunction, its terms must be clear and specific. (Kelly v. City of Cape Girardeau, 230 Mo. App. 137 [89 S.W. (2d) 693]; McKelsey v. Lewis, (N.Y.) 3 Abb. N. C. 61; Tinkey v. Langdon, (N.Y.) 60 How. Prac. 180; 13 C.J. 15, sec. 17.) In the Kelly case, supra, it is said:
 "It is an accepted legal proposition that for the decree of a court to suffice to be the basis of a charge of contempt by reason of a party's disobedience to or non-compliance with it, it must be specific and definite so as to inform the party to be bound thereby what he is to do or what he is not to do. (Magel v. Gruetli Benevolent Society of St. Louis, 203 Mo. App. 335 [218 S.W. 704].)" *650
 [12] Certainly one is not guilty of contempt who violates none of the acts prohibited by the injunction. The affidavit in this case conferred no jurisdiction on the court to try or convict the petitioner of contempt for violating section 228 of the Agricultural Code.
 For the reason that it affirmatively appears without contradiction that the petitioner did not violate the terms of the injunction, the court exceeded its jurisdiction in finding him guilty of contempt and in punishing him therefor.
 The order is annulled and the petitioner is discharged.
 Pullen, P.J., concurred.
