How do I connect to a network share via the Windows Command Prompt?

use net use, example:

net use X: \\SERVER\Share

Where X: is the drive letter you wish to map the share to, and \\SERVER\Share is the UNC path to the share. This should make the share visible in My Computer and the command line as well like all other shares mapped through the GUI.

In order to later disconnect the share, you would use

net use X: /delete

If you don't to map a network drive with net use you can access a UNC Path directly from the Command Prompt using pushd.

For example:

pushd \\server\share

This will create a temporary mapped drive automatically for you and make it your current working directory.

When you're finished on the network share enter the popd command. This will return you to the directory you were in before and delete the temporary network drive.

The popd and pushd commands can be used with local directories. They build up a stack of visited directories which can be handy if you work on the command line a lot. So when you change to a directory with pushd, you can get back to where you were with popd. A stack of directories is built up with each pushd and you go one directory back up the stack with popd.