On October 14, 2015, Southeastern Energy Corp. petitioned this Court for a writ of mandamus ordering the Fayette Circuit Court to vacate its order denying Southeastern Energy’s motion for a change of venue for the underlying action and directing the Fayette Circuit Court to grant the motion and transfer the action to the Montgomery Circuit Court (case no. 1150033). On December 18, 2015, Southeastern Energy filed a second petition for a writ of mandamus asking this Court to direct the Fayette Circuit Court to vacate an order it entered on December 16, 2015, transferring the underlying action to the Lowndes Circuit Court and to direct the Fayette Circuit Court to enter an order transferring the action to the Montgomery Circuit Court (case no. .1150294). We dismiss Southeastern Energy’s petition in case no. 1150033, and we deny its petition in case no. 1150294.
Facts
The materials before us indicate that Clatus Junkin, a resident of Fayette County, owns and operates Johnco Materials, Inc., a sand and gravel pit located in Lowndes County. At some point in time, Junkin purchased diesel fuel from Southeastern Energy and had it delivered to Johnco Materials. When Southeastern Energy did not receive payment for the fuel, Southeastern Energy sued Johnco Materials and Junkin, individually, in Lowndes County. With regard to Junkin, Southeastern Energy alleged that “Junkin was personally liable to Southeastern Energy for diesel fuel that was sold and delivered to Johnco Materials.” At the request of the parties, the Lowndes Circuit Court entered a consent judgment against Johnco Materials and in favor of Southeastern Energy for an agreed-upon amount and dismissed Junkin from the action with prejudice.
On June 29, 2015, Junkin sued Southeastern Energy in the Fayette Circuit Court alleging malicious prosecution by Southeastern Energy in the Lowndes County case. On August 2, 2015, Southeastern Energy moved to dismiss the malicious-prosecution action or, in the alternative, to transfer the action to “Montgomery County, Alabama, or any other proper, venue, pursuant to Rule 82(d), Ala. R. Civ. P., and governing law.” In support of its request for a change of venue, Southeastern Energy attached an affidavit from Jack R. Pitts, the president of Southeastern Energy, who averred:
“2. Southeastern Energy Corporation does not do business by agent or otherwise in Fayette County, Alabama in any form or fashion and has never done business in Fayette County, Alabama.
“3. On September 11, 2014, Southeastern Energy filed a complaint against Johnco Materials, Inc., and Clatus Jun-kin in the circuit court for Lowndes County, Alabama, .,. to collect monies owed for the sale and delivery of diesel fuel to [Johnco Materials and Junkin’s] gravel pit operations in White Hall, Lowndes County, Alabama. Clatus Jun-kin was and is the 100 percent owner of Johnco Materials, Inc., and was named an individual defendant because he assumed certain of the obligations to Southeastern Energy by,' in part, paying for diesel fuel purchased by Johnco Materials with personal funds. [Johnco Materials and Junkin] ceased operation of the sand and gravel pit in Lowndes *1210County, Alabama, and left owing Southeastern Energy oyer $67,000 worth of diesel fuel Southeastern Energy had supplied to [their] operations; and never paid for. A consent judgment was ultimately entered in this Lowndes County action whereby Defendant Johnco Materials consented to a judgment for all monies claimed by Southeastern Energy plus interest totaling at the time $77,969.41 on February 23, 2015.
“4. All matters related to the above-referenced litigation in Lowndes County, Alabama occurred in Lowndes or Montgomery County, Alabama, and at no time had anything to do with Fayette County, Alabama. Johnco Materials and its owner, Clatus Junkin, determined to open and operate a sand and gravel pit as noted in Lowndes County, Alabama, and to purchase its diesel fuel for such operations from Southeastern Energy Corporation in Montgomery County, Alabama.”
On September 23, 2015, the Fayette Circuit Court denied Southeastern Energy’s motion to dismiss or, in the alternative, for a change of venue.
On October 14, 2015, Southeastern Energy petitioned this Court for a writ of mandamus ’ directing the Fayette Circuit Court to vacate its September 23, 2015, order and to direct the Fayette Circuit Court to enter an order dismissing the underlying action or, in the alternative, transferring the action to Montgomery Circuit Court (case no. 1150033). Southeastern Energy did not request a stay of the action in the trial court pending resolution of its request for mandamus relief. On November 23, 2015, this Court denied Southeastern Energy’s request for mandamus relief with regard to the dismissal of the action but ordered answers and briefs to determine whether Southeastern Energy was entitled to mandamus relief with regard to its request for a change of venue.
On December 16, 2015, the layette Circuit Court ordered the case transferred to the Lowndes Circuit Court. On December 18, 2015, Southeastern Energy moved this Court to stay the underlying action until resolution of its earlier request for mandamus relief with regard to venue. It also petitioned this Court for a writ of mandamus directing the Fayette Circuit Court to vacate its December 16, 2015, order transferring the 'action to the Lowndes Circuit Court (case no. 1150294). On January 14, 2016, this Court granted Southeastern Energy’s motion to stay, ordered answers and briefs to address the request for mandamus relief in case no. 1150294, and consolidated case nos. 1150033 and 1150294 for purposes of writing one opinion.
Standard of Review
“‘The proper method for obtaining review of a denial of a motion for a change of venue in a civil action is to petition for the writ of mandamus.’ Ex parte Alabama Great Southern R.R., 788 So.2d 886, 888 (Ala.2000). ‘Mandamus is a drastic and extraordinary writ, to be issued only where there is (1) a clear legal right in the petitioner to the order sought; (2) an imperative .duty upon the respondent to perform, accompanied by a refusal to do so; (3) the lack of another adequate remedy; and (4) properly invoked jurisdiction of the court.’ Ex parte Integon Corp., 672 So.2d 497, 499 (Ala.1995)....
“‘The burden of proving improper venue is on the party raising the issue and on review of an order transferring or refusing to transfer, a writ of mandamus will not be granted unless there is a clear showing of error on the part of the trial judge.’ Ex parte Finance America Corp., 507 So.2d 458, 460 (Ala.1987).’’
*1211Ex parte Pike Fabrication, Inc., 859 So.2d 1089, 1091 (Ala.2002).
Discussion
Case No. 1150033
Southeastern Energy contends that the trial court erred in denying its motion to transfer the case from Fayette County to Montgomery County. In its motion, Southeastern Energy asked the trial court to transfer the underlying action to “Montgomery County, Alabama, or any other proper venue, pursuant to Rule 82(d), Ala. R. Civ. P., and governing law.”
Rule 82(d)(1), Ala. R. Civ. P., provides:
“(1) As of the Commencement of the Action. When an action is commenced laying venue in the wrong county, the court, on timely motion of any defendant, shall transfer the action to the court in which the action might have been properly filed and the case shall proceed as though originally filed therein.”
In Ex parte Pike Fabrication, this Court set forth the law with regard to proper venue:
“ ‘The question of proper venue for an action is determined at the commencement of the action.’ Ex parte Pratt, 815 So.2d 532, 534 (Ala.2001); see also Rule 82(d)(1), Ala. R. Civ. P. ‘If venue is not proper at the commencement of an action, then, upon motion of the defendant, the action must be transferred to a court where venue would be proper.’ Ex parte Overstreet, 748 So.2d 194, 196 (Ala.1999).
“Section 6-3-7, Ala.Code 1975, governs venue for actions against corporate defendants. That section provides:
“ ‘(a) All civil actions against corporations may be brought in any of the following counties:
“ ‘(1) In the county in which a substantial part of the events or. omissions giving rise to the claim occurred, or a substantial part of real property that is the subject of the action is situated; or
■ “ ‘(2) In the county of the corporation’s principal office in this state;, or “‘(3) In the county in which the plaintiff resided, or if the plaintiff is an entity other than an individual, where the plaintiff had its principal office in this state, at the time of the accrual of the cause of action, if such corporation does business by agent in the county of the plaintiffs residence; or
“‘(4) If subdivisions (1), (2), or (3) do not apply, in any county in which the corporation was doing business by agent at the time of the accrual 'of the cause of action.’
“A party may submit evidentiary material in support of a motion to dismiss attacking venue. Ex parte D.M. White Constr. Co., 806 So.2d .370, 372 (Ala.2001)....” ‘
859 So.2d at 1091-92.
The materials before us . demonstrate that the trial court erred in denying Southeastern Energy’s motion for a change of venue. Southeastern Energy made a prima facie showing that venue is not proper in Fayette County. Pitts’s affidavit states that Southeastern Energy does not do business by agent pr otherwise in Fayette County, that Southeastern Energy is located in Montgomery County, and that all matters relating to the underlying facts supporting Junkin’s claim of malicious prosecution occurred in Lowndes County or Montgomery County. The burden then shifted to Junkin to prove that Southeastern Energy did in fact conduct business in Fayette County. See Ex parte Citizens State Bank, 989 So.2d 507, 508 *1212(Ala.2008)(explaining that § 6-3-7(a)(3), Ala.Code 1975, provides that venue is proper in the county of a plaintiffs residence when the plaintiff establishes that the corporation does business by agent in that county). Junkin, however, did not respond to Southeastern Energy’s motion. Therefore, the only evidence before the trial court when it ruled on Southeastern Energy’s motion indicated that venue is not proper in Fayette County but is proper in either Lowndes County, see § 6-3-7(a)(1), or in Montgomery County, see § 6-3-7(a)(2). The trial court erred on September 23,2015, when it denied Southeastern Energy’s motion for a change of venue.
However, after Southeastern Energy filed its petition for a writ of mandamus asking this Court to vacate the trial court’s September 23, 2015, order and to direct the trial court to enter an order transferring the case, but before this Court exercised its supervisory power and addressed the matter, the trial court sua sponte reconsidered Southeastern Energy’s motion for a change of venue, determined that venue was not proper in Fayette County, and ordered that the case be transferred to Lowndes County. Because the parties did not ask for a stay of the proceedings in the trial court while this Court considered Southeastern Energy’s mandamus petition in case no. 1150033, the trial court had jurisdiction to reconsider its order denying a change of venue and to enter an order transferring the case. See State v. Webber, 892 So.2d 869, 871 (Ala.2004)(“The filing of a petition for a writ of mandamus against a trial judge does not divest the trial court of jurisdiction, stay the case, or toll the running of any period for obeying an order or perfecting a filing in the case.... The petition for a writ of mandamus, if meritorious, merely prompts the appellate court to exercise its supervisory power to tell the trial judge, as an official, as distinguished from the trial court itself, to do his or her duty when that duty is so clear that there are no two ways about it.”). By reconsidering Southeastern Energy’s motion for a change of venue and transferring the casé to Lowndes County, the trial court performed its duty, and Southeastern Energy’s request for mandamus relief in case no. 1150033 became moot; therefore, the petition is dismissed.
Case No. 115029J/.
In case no. 1150294, Southeastern Energy’s second petition for a writ of mandamus, Southeastern Energy asks this Court to “hold for naught” the trial court’s order transferring the case to Lowndes County. However, as previously discussed, the trial court had jurisdiction to reconsider its decision on Southeastern Energy’s motion for a change of venue. Therefore, Southeastern Energy has not established a clear, legal right to have the trial court’s order transferring the case to Lowndes County vacated based on the timing of the entry of the order.
A fair reading of Southeastern Energy’s petition establishes that Southeastern Energy’s actual objection is that the trial court transferred the case to Lowndes County, “a venue nobody had sought.” However, a review of the materials submitted to this Court indicates that Southeastern Energy asked the trial court to transfer venue to “Montgomery County, Alabama, or any other proper venue, pursuant to Rule 82(d), Ala. R. Civ. P., and governing law.” The materials also establish that “a substantial part of the events or omissions giving rise to” Junkin’s malicious-prosecution claim occurred in Lowndes County; therefore, venue is proper in Lowndes County, see § 6-3-7(a)(1). Because the materials before us indicate that the transfer ordei-ed by the *1213trial court is proper, Southeastern Energy has not demonstrated a clear, legal right to have the trial court’s order vacated; therefore, Southeastern Energy’s petition in case no. 1150294 is denied.
Conclusion
Based on the foregoing, Southeastern Energy’s petition in case no. 1150033 is dismissed as moot and Southeastern Energy’s petition in case no. 1150294 is denied.
1150033 — PETITION DISMISSED.
1150294 — PETITION DENIED.
PARKER, MAIN, and WISE, JJ., concur. SHAW, J., concurs in the result. MOORE, C.J., recuses himself.