
99 Wis.2d 449 (1980)
299 N.W.2d 584
CITY OF WHITEWATER, a municipal corporation, Plaintiff,
v.
Harley E. BAKER, Mildred D. Baker, d/b/a Baker's Garage, Defendants.
Gerald W. PELISHEK, Plaintiff-Appellant,
v.
The CITY OF WHITEWATER, Wisconsin, The Wisconsin Department of Transportation and The State of Wisconsin, Defendants-Respondents.[]
No. 79-1697.
Court of Appeals of Wisconsin.
Submitted on briefs August 22, 1980.
Decided October 16, 1980.
*450 For the plaintiff-appellant there was a brief by Stephen P. Hurley of Pieper & Hurley of Stoughton. Of counsel was Bradford W. Wilcox of Vance, Wilcox & Short, S.C. of Fort Atkinson.
For the defendant-respondent there was a brief by Martin W. Harrison of Allen, Harrison & Williams of Whitewater.
Before Voss, P.J., Brown and Scott, J.J.
SCOTT, J.
Pelishek appeals from the trial court's judgment dismissing his complaint for a declaration of his interest in certain property located in the City of Whitewater and for an injunction against the City, the State and the Department of Transportation to prohibit their encroaching upon his property. Pelishek argues, among other things, that the trial court erred in failing to disqualify Attorney Clark Dempsey from representing the City because Dempsey had represented Pelishek during Pelishek's acquisition of the very property now in *451 dispute. We agree and remand the cause for a new trial in which Dempsey is disqualified from participating.
In our view, the record shows an obvious and serious conflict of interest on the part of Attorney Dempsey. In September 1969, Pelishek retained Dempsey to represent him in the purchase of certain property located in the City of Whitewater including an old grist mill and an adjacent dam. Dempsey prepared the offer to purchase, which was executed on September 9, 1969 and accepted by the owners of the mill and dam.
In December 1969, Pelishek was served by the City with an order of condemnation directing that the mill building be razed due to its structural decay. The order had been drafted by the city attorney, Mr. Dempsey. For the next three years, Dempsey continued to represent both Pelishek and the City, during which time Pelishek negotiated with the City to try to avoid the destruction of the building and close the real estate purchase.
Around October of 1972, Dempsey advised Pelishek he could no longer represent both Pelishek and the City due to a possible conflict of interest, and he was withdrawing from further representation of Pelishek regarding the purchase of the mill property. Dempsey continued to represent Pelishek in other business matters until 1976.
On October 13, 1972, the owners of the mill property executed a warranty deed conveying the grist mill property, but not the dam, to Pelishek. The deed was drafted by Pelishek's new attorney, Ronald Todd. The conveyance of the property had been delayed from 1969 to 1972 partly because of the condemnation proceedings and partly because of the Public Service Commission's lack of assent to the conveyance of the dam. After having delayed the condemnation proceedings for several years, Pelishek dismantled the mill for its possible future reconstruction.
*452 On August 30, 1975, the former owners of the mill property executed a quitclaim deed conveying to the City the dam Pelishek had attempted to acquire along with the grist mill. This deed was drafted by Dempsey on behalf of the City.
Around 1978, the City determined it would widen the street which traversed the dam and passed in front of the property owned by Pelishek. The street, named Main Street, was designated as U. S. Highway 12 and at this location followed the general route of the territorial road of 1839 between Rochester and Madison. The right of way of the territorial road was sixty-six feet. The proposed widening of Main Street to sixty-six feet overlapped that portion of the property deeded to Pelishek where the southwest corner of the grist mill used to stand.
On May 14, 1979, Pelishek instituted the present action under ch. 841, Stats., to declare his interest in the grist mill property and to enjoin the City, the State and the Department of Transportation from encroaching on his property. Pelishek's action was consolidated with an action instituted by the City against a certain Baker for the removal of Baker's alleged encroachments upon the street to be widened.
At the pretrial hearing held on June 7, 1979, Pelishek objected to Dempsey's appearance on behalf of the City. Pelishek pointed to Dempsey's representation of Pelishek from 1969 to 1972 in the acquisition of the grist mill property that was the basis for the present suit and asked the court for an order compelling the City to substitute counsel. Dempsey responded to the oral motion by maintaining he saw no conflict and stating:
I haven't pulled the old file out, I intentionally haven't pulled it, and I have instructed everybody in my office to leave the old file intact. We haven't used it in any way.
*453 The trial court denied Pelishek's motion and indicated the matter was more properly one for the State Bar Discipline Committee. On June 21, 1979, Pelishek filed a motion asking the trial court to reconsider its ruling and cited Ennis v. Ennis, 88 Wis.2d 82, 276 N.W.2d 341 (Ct. App. 1979). The trial court responded by holding a hearing on June 28, 1979 and treated Pelishek's motion for reconsideration as a renewed motion to bar Dempsey and his office from representing the City. At the hearing, the court took testimony from Pelishek concerning Dempsey's activities on his behalf, heard the arguments of counsel and again denied the motion, stating:
I think we have to recognize that lawyers who practice in small communities tend to represent a lot of people at many times. I guess at this point at least I can't feel that there's much of anything here in order for me to remove the firm. I've got to in effect make a finding that they were unethical in representing the city.
[1]
We believe the trial court misunderstood its duty. Before disqualifying an attorney from representing a client on the ground that such representation would conflict with his duties to a former client, a court need not find an attorney has actually been unethical or made disclosures of his former client's confidences. It need only find the attorney has undertaken representation of a client whose interests are adverse to those of the former client. Attorneys are obligated to avoid even the appearance of impropriety. Ennis, supra, 88 Wis.2d at 98-99, 276 N.W.2d at 348; Canon 9, Code of Professional Responsibility, 43 Wis.2d lxxi (1969). Attorneys are further obligated to preserve the confidences of a client and to exercise independent professional judgment on behalf of a client. Canons 4 and 5, Code of Professional Responsibility, 43 Wis.2d xxxvi and xxxix.
*454 [2]
"An attorney is an officer of the court charged by every rule of law and by the highest ethical consideration to keep inviolate the confidence of his client, and he should never under any circumstances make that relationship a basis of personal gain in another action against his client." Harvey v. Harvey, 202 Wis. 553, 560, 231 N.W. 580, 583 (1930).
The disadvantage under which a litigant must labor who is opposed, in the effort to enforce or defend his rights, by an attorney to whom he had, in the confidential relation of attorney and client, made a full disclosure of the facts as he claims them, is obvious. . . . The rule . . . is not only for the good of the profession, but for the safety of clients.
Michel v. McKenna, 199 Wis. 608, 611, 227 N.W. 396, 398 (1929) (quoting Kluht v. Mitchell, 199 Iowa 1163, 1168, 199 N.W. 294, 296 (1924)).
[3]
Of course, an attorney's acceptance of employment to act in opposition to his former client is not by itself improper. The interest represented by the attorney in the subsequent employment must be adverse to the interest represented in the original employment. See Annot., 52 A.L.R.2d 1243, 1262 (1957), and cases cited therein.
The test of whether the attorney's employment is inconsistent with his duty to a former client is whether acceptance of the new retainer will require him in forwarding the interest of the new client to do anything that will injuriously affect a former client in any matter in which he formerly represented him and also whether the attorney will be called on, in his new relation, to use against a former client any knowledge or information acquired in the former relationship.[1]See 7 Am. Jur.2d *455 Attorneys at Law §156, p. 140 (1963), and cases cited therein.
[4]
In the present case, Dempsey represented Pelishek in Pelishek's acquisition of certain property. Dempsey then represented the City in Pelishek's action against the City to clear Pelishek's title in the very same property. The two interests represented by Dempsey are obviously adverse to one another. In representing the City, Dempsey sought to deny Pelishek's title to part of the same property which he had earlier sought to acquire for Pelishek.[2]
*456 To avoid the appearance of impropriety and to avoid injuriously affecting Pelishek in his assertion of title to the mill property, Dempsey should not have undertaken to represent the City in Pelishek's action. Having done so, however, he should have voluntarily withdrawn when Pelishek first objected to his representation of the City. Upon his failure to withdraw, it became the duty of the trial court to bar Dempsey's further participation.
In Ennis v. Ennis, supra, we instructed on the duty of the trial court when confronted with an attorney's conflict of interest. In Ennis, an attorney represented the plaintiff in an action to reopen a divorce judgment despite the fact an attorney from his firm had represented the defendant in the original divorce action. The defendant moved to dismiss the action or to postpone it until the plaintiff obtained new counsel. The trial court denied the motion apparently because in its view, the defendant's only remedy was to complain to the State Bar in a grievance proceeding. This court vacated the trial court's order reopening judgment and remanded the cause, stating:
Plaintiff's counsel should have withdrawn from the case at the time the conflict of interest became apparent. Failing his voluntary withdrawal, we hold that the trial court had the power and responsibility to dismiss the action, or to disqualify him from proceeding.
Id. at 100, 276 N.W.2d at 348.
*457 [5]
We again emphasize that a trial court has "not only the power but the duty to intervene where the professional misconduct of an attorney before it affects the substantial rights of the parties." Id. at 97, 276 N.W.2d at 347. The trial court in the present case erred when it failed to grant Pelishek's motion for an order compelling substitution of counsel.
Pelishek argues on appeal that this court should not grant him a new trial but should dismiss the City's pleadings and enter judgment in his favor. We refuse to do so for such a remedy would amount to a judgment on the merits of Pelishek's case. We rejected a similar argument in Secord v. Chrysler Corp., 96 Wis.2d 521, 292 N.W.2d 365 (Ct. App. 1980). In Secord, a personal injury case, Attorney Skemp simultaneously represented during an eight month period three co-defendants with adverse interests. Skemp later disqualified himself from representing co-defendant Martell but continued to represent the other two co-defendants, Chrysler and INA. As a remedy for Skemp's possible breach of Martell's confidences, Martell moved to preclude Chrysler and INA from asserting any cross-claims or defenses against her. We affirmed the trial court's denial of the motion and stated:
As Martell may pursue actions against Skemp, INA and Chrysler for any actual damages from the alleged misconduct, which has never been proven in a court or before a professional disciplinary committee, this court does not believe it appropriate to take the unprecedented step of precluding a party from bringing a substantive claim having no connection to that misconduct.
Id. at 530, 292 N.W.2d at 370.
In our perception, the only viable remedy for the trial court's error in permitting Dempsey to represent the *458 City against Pelishek is to award Pelishek a new trial.[3] Pelishek argues, with some justification, that his confidences to Dempsey are now a matter of record and could be used against him in a new trial. The confidences of which Pelishek expresses most concern consist of his intentions regarding the grist mill property, his financial situation in general and his physical handicap. Our comprehensive review of the record in this case, however, reveals no particularly damaging information about Pelishek which an attorney would not otherwise discover while representing the City against Pelishek. Nevertheless, to protect Pelishek from any unfairness which could result from opposing counsel's access to the Dempsey law office file on the representation of Pelishek from 1969 to 1972 in the acquisition of the mill property, we direct that the file be suppressed and not used at trial or reviewed by the City's counsel.
We do not reach the other issues raised on appeal, all of which concern the merits of the highway right of way controversy.
By the Court.  Judgment reversed and remanded with directions.
NOTES
[]  Petition to review denied.
[1]  In the federal courts, the test of whether the attorney's employment is inconsistent with his duty to his former client is whether a "substantial relation" exists between the subject matter of the former representation and the issues in the later adverse representation. Westinghouse Elec. Corp. v. Gulf Oil Corp., 588 F.2d 221, 223-25 (7th Cir. 1978); Koehring Co. v. Manitowoc Co., Inc., 418 F. Supp. 1133, 1136 (E.D. Wis. 1976); Marketti v. Fitzsimmons, 373 F. Supp. 637, 639 (W.D. Wis. 1974). Under this test, Dempsey would have to be disqualified from representing the City. The acquisition of certain property is substantially related to the clearance of title in the same property. Compare Koehring in which the court disqualified a law firm from representing the defendant in a patent infringement action when it had formerly represented the plaintiff in asserting the validity of the same patents. The court held that disqualification was required even though the same claims within the patents were not at issue, no confidential information had been received by the law firm, and the firm member who had worked with the plaintiff in the prior litigation had died in the meantime.
[2]  Whether, in his representation of the City in the present case, Dempsey actually used against Pelishek any knowledge Dempsey had acquired from his former representation of Pelishek is irrelevant to the issue before us. The issue is whether the trial court erred in failing to disqualify Dempsey before trial. Nevertheless, to demonstrate the likelihood that Dempsey actually used such knowledge against Pelishek, Pelishek points to several instances in Dempsey's cross-examination of Pelishek at trial where Dempsey elicits testimony on subjects which Dempsey may, possibly, have had knowledge only through Pelishek's confidences:

Q: You knew when you were buying and when you were closing this partial agreement that you didn't want to take title to any part of the mill dam, didn't you?
. . . .
Q: Do you recall that [Frank Hasley of the DNR] did make an inspection of the dam at the time you were negotiating with Mr. Baskin in regard to the sale of the property?
. . . .
Q: Didn't [city manager Mr. Eggum] advise you [in 1969] that you better get [the mill] fixed up?
These instances during Dempsey's cross-examination of Pelishek furnish additional evidence of Dempsey's professional misconduct subjecting him to possible discipline by the Board of Attorneys Professional Responsibility.
[3]  Pelishek could have sought leave from this court to appeal the trial court's denial of his motion to disqualify Dempsey. Secs. 808.03(2) and 809.50, Stats. His failure to do so, despite his perception of the trial court's plain error, evidences a decision to take his chances at an extended trial and undercuts his present argument that another extended trial would be a punishment to him. If Pelishek's aversion to a new trial is really an aversion to having Judge Gollmar be the trial judge once again, his remedy lies in sec. 801.58(7), Stats., which permits the substitution of a new judge in a new civil trial.
