Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

VB Script to Map a Hidden Network Share in a Different Domain

Posted on 2011-03-23
1
Medium Priority
?
398 Views
Last Modified: 2012-05-11
Hello,

I am trying to write a VB logon script for specific users in my domain to map to a hidden network share in a different domain.  When I try to reference the hidden share in my script the conventional way.

WSHNetwork.MapNetworkDrive "i:", "\\Server\D$"

It errors out.  This is because I must reference the other domain somehow in the script.  The usernames and passwords match in both domains, but the UPN prefix is obviously different.  Any help would be greatly appreciated.  
0
Comment
Question by:Techop09
[X]
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
1 Comment
 
LVL 65

Accepted Solution

by:
RobSampson earned 1000 total points
ID: 35203264
Hi, try specifying the username and password manually, to see what happens:
http://msdn.microsoft.com/en-us/library/8kst88h6(v=vs.85).aspx

WSHNetwork.MapNetworkDrive "i:", "\\Server\d$", False, "domain\username", "password"

Regards,

Rob.

0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Recently, Microsoft released a best-practice guide for securing Active Directory. It's a whopping 300+ pages long. Those of us tasked with securing our company’s databases and systems would, ideally, have time to devote to learning the ins and outs…
After seeing many questions for JRNL_WRAP_ERROR for replication failure, I thought it would be useful to write this article.
This tutorial will walk an individual through the steps necessary to join and promote the first Windows Server 2012 domain controller into an Active Directory environment running on Windows Server 2008. Determine the location of the FSMO roles by lo…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …

704 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