code:
$username='johndoe'
shell '%comspec% /c NET LOCALGROUP ADMINISTRATORS /ADD '+$username

This must be executed under an account that has the right to add users to local groups (e.g. an administrative account).

It might be easier to add the 'Domain Users' group to the local 'Administrators' group. Then you don't have to update your local computers all the time when you add/delete domain users.

BTW, search for 'net localgroup' to retrieve threads discussing this.
_________________________
There are two types of vessels, submarines and targets.