Run the htascript for another domain with admin credentials

Posted on 2011-03-11
Last Modified: 2012-05-11
I want to run the hta script from one domain to another domain which is complely different domain. We have network connections established to acces that domain and how to run the script with another credentials and add the runas option.
Question by:sivark14
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 19

Expert Comment

by:Miguel Angel Perez Muñoz
ID: 35107672
Try this way:  runas /env /user:user@other.domain "WSCRIPT "route to file.vbs""
LVL 19

Expert Comment

by:Miguel Angel Perez Muñoz
ID: 35107699
Sorry I read vbscript. Change wscript  and enter the program that runs the script.

Author Comment

ID: 35107744
The above is not running for hta script.
Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

LVL 12

Expert Comment

ID: 35108118
do you have any trust relatioship with that domain, if it's completely separate entity then you won't be able to run otherwise you can right click on the file and select Run As runas

Author Comment

ID: 35108344
Thanks for the update. I know how to add the runas option thorugh reged but i don't have access to edit the registry on the machine. Some time back I used the command runas /user:' "C:\windows\system32\mshta.exe test.hta"" which was working. I forgot the exact command which will give the results.


Accepted Solution

sivark14 earned 0 total points
ID: 35108453
I tried  this command runas /user:domain\domainadmin "c:\windows\system32\mshta.exe \"h:\test.hta\"" which is working fine.
LVL 74

Expert Comment

by:Glen Knight
ID: 37433058
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.

Featured Post

Office 365 Training for IT Pros

Learn how to provision Office 365 tenants, synchronize your on-premise Active Directory, and implement Single Sign-On.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Removing Exchange 2003 3 28
Powershell code to query find desktop PC only 8 28
Compatibility view list registry key 1 34
IF statement on a PowerShell Script 2 22
Active Directory security has been a hot topic of late, and for good reason. With 90% of the world’s organization using this system to manage access to all parts of their IT infrastructure, knowing how to protect against threats and keep vulnerabil…
Auditing domain password hashes is a commonly overlooked but critical requirement to ensuring secure passwords practices are followed. Methods exist to extract hashes directly for a live domain however this article describes a process to extract u…
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles from a Windows Server 2008 domain controller to a Windows Server 2012 domain controlle…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question