
471 S.E.2d 718 (1996)
Tyler E. NIX, Appellant,
v.
COLUMBIA STAFFING, INC., a/k/a Quality Systems, Inc., Respondent.
No. 2495.
Court of Appeals of South Carolina.
Submitted March 5, 1996.
Decided April 15, 1996.
Rehearing Denied June 20, 1996.
*719 Hal J. Warlick, of Warlick Law Office, of Easley, for appellant.
Steven M. Wynkoop and Robert T. Lyles, Jr., both of Ogletree, Deakins, Nash, Smoak & Stewart, of Charleston, for respondent.
PER CURIAM:
In this negligence action, Tyler E. Nix (Nix) appeals the order of the circuit court granting Columbia Staffing, Inc.'s (CSI) motion for summary judgment and its motion to dismiss on the ground the Workers' Compensation Act is Nix's exclusive remedy. We affirm.

Facts
Nix worked as a painter for T & M Construction, a subcontractor of Duke Power. He was standing on scaffolding constructed by personnel of CSI when he fell, causing injuries to his back. Nix filed for workers' compensation benefits from T & M Construction and was awarded medical expenses as well as temporary total and partial permanent disability awards. Subsequently, he filed this negligence action against CSI.
CSI initially filed a motion for summary judgment on the ground the court lacked subject matter jurisdiction over the case because Nix's exclusive remedy was under the South Carolina Workers' Compensation Act. This motion was denied by Judge William H. Ballenger. After further discovery, CSI moved to dismiss pursuant to Rule 12(b)(1), SCRCP, on the same ground. The court declined to address the issue, concluding it had already been decided by Judge Ballenger. CSI appealed the denial of its motion to dismiss to the South Carolina Supreme Court which dismissed the appeal and remanded to the trial court for further proceedings.[1] After remand, CSI again filed a motion to dismiss and a motion for summary judgment on the same ground. The trial court granted both motions.

I.
Nix argues the trial court erred in setting aside the previous order of Judge Ballenger. We disagree. It is true one circuit court judge may not set aside the order of another circuit court judge. Enoree Baptist Church v. Fletcher, 287 S.C. 602, 340 S.E.2d 546 (1986). However, in dismissing CSI's appeal and remanding, the South Carolina Supreme Court pointed out that subject matter jurisdiction is properly raised by a motion to dismiss and the previous denial of a motion for summary judgment is not the law of the case. See McLendon v. South Carolina Dep't of Highways and Pub. Transp., 313 S.C. 525, 443 S.E.2d 539 (1994) ("like the denial of a motion for summary judgment, the denial of a motion to dismiss does not establish the law of the case and the issue can be raised again at a later stage of the proceedings.") Furthermore, lack of subject matter jurisdiction can be raised at any time, can be raised for the first time on appeal, and can be raised sua sponte by the court. Ex parte Reichlyn, 310 S.C. 495, 427 S.E.2d 661 (1993); Hallums v. Bowens, ___ S.C. ___, 428 S.E.2d 894 (Ct.App.1993).

II.
Nix also argues the trial judge erred in granting CSI's motion to dismiss and motion *720 for summary judgment because there were genuine issues of material fact concerning whether those responsible for his injuries were employees of Duke Power at the time of their negligent acts. We disagree.
Nix argues the employees who built the faulty scaffolding were employees of CSI at the time of their acts and, thus, his suit is not barred by the exclusive remedy provision of the Workers' Compensation Act under S.C.Code Ann. § 42-1-540 (1976). Section 42-1-540 provides:
The rights and remedies granted by this Title to an employee when he and his employer have accepted the provisions of this Title, respectively, to pay and accept compensation on account of personal injury or death by accident, shall exclude all other rights and remedies of such employee, his personal representative, parents, dependents or next of kin as against his employer, at common law or otherwise, on account of such injury, loss of service or death.

Provided, however, this limitation of actions shall not apply to injuries resulting from acts of a subcontractor of the employer or his employees or bar actions by an employee of one subcontractor against another subcontractor or his employees when both subcontractors are hired by a common employer. (Emphasis added).
CSI argues § 42-1-540 does not apply to Nix because the employees who built the faulty scaffolding were either direct employees of Duke Power, or were "lent employees," loaned from CSI to Duke Power. As such, CSI argues, they share Duke Power's tort immunity. Thus, this case turns on a factual determination of whether the negligent employees were employed by CSI or by Duke Power at the time of their negligent acts.
The test used to determine whether an employee furnished by one person to another becomes a "lent employee" is whether the employee passes under the latter's right of control with regard not only to the work to be done but also to the manner of performing it. Parker v. Williams & Madjanik, Inc., 269 S.C. 662, 239 S.E.2d 487 (1977) (citing Young v. Warr, 252 S.C. 179, 165 S.E.2d 797 (1969)). Furthermore, an injured worker's employment status, as it affects jurisdiction, is a matter of law for decision by the court and includes necessary findings of fact relating to jurisdiction. Wheeler v. Morrison Machinery Co., 313 S.C. 440, 438 S.E.2d 264 (CtApp.1993). Any dispute in the facts giving rise to this issue should be resolved by the court, not a jury. Id. 438 S.E.2d at 265. See also Bridges v. Wyandotte Worsted Co., 243 S.C. 1, 132 S.E.2d 18 (1963) ("[i]t has been consistently held that whether the claim of an injured workman is within the jurisdiction of the Industrial Commission is a matter of law for decision by the court, which includes the finding of the facts which relate to jurisdiction.")
The trial judge found CSI took prospective employees' applications, performed various administrative tasks, and then sent them to Duke Power, where Duke assigned the employees to their tasks. The employees performed their assigned tasks under the direct supervision and control of Duke Power. Duke Power also provided the employees with all equipment necessary to perform their work. Furthermore, the trial judge found Duke had full authority to reject, transfer, or terminate the employees sent to it by CSI. These findings were well supported by the deposition testimony presented to the trial judge in support of CSI's motions and satisfied the control test stated in Parker v. Williams & Madjanik, 269 S.C. 662, 239 S.E.2d 487 (1977). Thus, the trial judge did not err, as a matter of law, in granting CSI's motion for summary judgment and its motion to dismiss.
Accordingly, the order of the trial judge is
AFFIRMED.
HOWELL, C.J., and CURETON and CONNOR, JJ., concur.
NOTES
[1]  The Supreme Court has recently determined that the denial of a motion for summary judgment based solely on subject matter jurisdiction is not immediately appealable. Johnson v. Paraplane Corporation, ___ S.C. ___, 468 S.E.2d 620 (S.C.Sup.Ct. filed Mar. 4, 1996) (Davis Adv. Sh. No. 5 at 29); see also Woodard v. Westvaco Corporation, ___ S.C. ___, 460 S.E.2d 392 (1995) (an order which determines a question of subject matter jurisdiction is not immediately appealable).
