Jump to content

Mount Functions


FuryCell
 Share

Recommended Posts

Here are the Mount Functions i just made . they let you mount a path as a drive. It includes three functions , _Mount , _UnMount , and _MountList.check out the example below.

#Include <MountInclude.au3>
_Mount (@MyDocumentsDir,"Z:"); Mounts the my documents dir as drive Z
Sleep (30000)
_UnMount("Z:"); UnMounts Z Drive

Enjoy! :(

Edit: Fixed some bugs with _MountList () and removed some stuff that was left behind from debugging

Edit:Oops! :( Uploaded wrong MountInclude.au3

Mount_Example.au3

MountInclude.au3

Edited by SolidSnake
HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Link to comment
Share on other sites

Updated. See Post above.

P.S. GaFrost , I am going to try drive info now and thanks Busysignal and Kjactive for commenting on my post.

HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Link to comment
Share on other sites

You might be interested in the DriveInfo in my signature.

<{POST_SNAPBACK}>

I Tried your DriveInfo script but i can't figure out how to map a local Drive however.

This might be useful when we have our network set up.we have been putting it off for so long :">!

HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.
Link to comment
Share on other sites

Wasn't meant for local dir mapping, I couldn't map local dirs at work anyways, as an admin over many servers i need a quick way to map unmap drives depending on what i was working on, usally have most of the drive letters used up.

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

  • 10 months later...

Wasn't meant for local dir mapping, I couldn't map local dirs at work anyways, as an admin over many servers i need a quick way to map unmap drives depending on what i was working on, usally have most of the drive letters used up.

I'm just wondering if you really need to use drive letters for most of what you're doing, gafrost. My team manages all NAS servers for a very large distributed organization, so we're constantly hitting their fileshares, etc. Unless you have a particular need to access something via a drive letter, just access it via its UNC.

I only map drive letters to things that I need ongoing, consistent access to, or that the UNC is too long to remember or type into the Run dialog. Although I do map the X-Z drives to things occasionally, but rarely do I need more than 3 or 4 drives mapped aside from the ones I normally use for shared documents, etc.

My UDFs: ExitCodes

Link to comment
Share on other sites

I'm just wondering if you really need to use drive letters for most of what you're doing, gafrost. My team manages all NAS servers for a very large distributed organization, so we're constantly hitting their fileshares, etc. Unless you have a particular need to access something via a drive letter, just access it via its UNC.

I only map drive letters to things that I need ongoing, consistent access to, or that the UNC is too long to remember or type into the Run dialog. Although I do map the X-Z drives to things occasionally, but rarely do I need more than 3 or 4 drives mapped aside from the ones I normally use for shared documents, etc.

The reason for mounting the drives is I mount the share as an admin, do what I need to do then unmount.

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

The reason for mounting the drives is I mount the share as an admin, do what I need to do then unmount.

Right, but I'm curious what can be done by mapping it to a drive letter that can't be done via UNC? I know you can see the drive size and free space in My Computer when it's mapped, and some utilities (and the Command Prompt ) require a drive letter.

I know it has a lot to do with personal preference. I work with people who do the same thing. No one has ever made me aware of a reason to map a drive that was significant enough to make me want to do it consistently. I'm not trying to pick a fight, I'm just curious.

Edited by c0deWorm

My UDFs: ExitCodes

Link to comment
Share on other sites

Right, but I'm curious what can be done by mapping it to a drive letter that can't be done via UNC? I know you can see the drive size and free space in My Computer when it's mapped, and some utilities (and the Command Prompt ) require a drive letter.

I know it has a lot to do with personal preference. I work with people who do the same thing. No one has ever made me aware of a reason to map a drive that was significant enough to make me want to do it consistently. I'm not trying to pick a fight, I'm just curious.

Np, we're not allowed to log into our systems as admins, so to get to some of the shares that only admins have access to or to update shares that only admins can I map it as an admin.

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

Np, we're not allowed to log into our systems as admins, so to get to some of the shares that only admins have access to or to update shares that only admins can I map it as an admin.

My company does the same thing. We have one account for our daily work on our machines and a separate account for servers. I can, however, go to start, run, type the UNC, and it will prompt me for the login. I enter it in the domain\username format, but you can also use the username@domain format, and it will allow you access. There is no need to map a drive simply because you need to use an alternate username... Although I suppose if your "normal" account has readonly access to a share and you need to write something you would need to do that, or you could access that data using the root drive share, such as \\server\c$ or \\server\d$. You will have to type the root drive share into the Run dialog, login, then finish the path if you want to go deeper into the tree, but it's still faster and easier than mapping drives.

Just a thought.

My UDFs: ExitCodes

Link to comment
Share on other sites

  • 2 weeks later...

Hey... I just saw these functions. I just have created the need for the mounting and unmounting of drives through script.

I have rarely used mounted drives in the past, but I need to do it now to make everything easier here at this company until I get the server up.

The problem I am having is that when someone restarts one of the computers whether it be the one mapped to or one of the mapped one's it messes up the connection. Sometimes I can just goto My Computer dbl click the drive, and it asks for the username and password, but recently it seems to want me to have to disconnect the drive and reconnect it before asking me again for the username and password.

I guess my question is this: Does either of your programs (SolidSnake and gafrost) allow for the username and password to be submitted through your UDF's?

I am sorry I havent tried any of these apps before asking my question, but I dont really have a test computer setup that I can try it on yet.

Thanks for everyone's time,

JS

AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

Link to comment
Share on other sites

Hey... I just saw these functions. I just have created the need for the mounting and unmounting of drives through script.

I have rarely used mounted drives in the past, but I need to do it now to make everything easier here at this company until I get the server up.

The problem I am having is that when someone restarts one of the computers whether it be the one mapped to or one of the mapped one's it messes up the connection. Sometimes I can just goto My Computer dbl click the drive, and it asks for the username and password, but recently it seems to want me to have to disconnect the drive and reconnect it before asking me again for the username and password.

I guess my question is this: Does either of your programs (SolidSnake and gafrost) allow for the username and password to be submitted through your UDF's?

I am sorry I havent tried any of these apps before asking my question, but I dont really have a test computer setup that I can try it on yet.

Thanks for everyone's time,

JS

Not sure exactly the problem your running into, but the script I wrote allows you to select reconnect at logon and use different user name and password.

Gary

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

Not sure exactly the problem your running into, but the script I wrote allows you to select reconnect at logon and use different user name and password.

Gary

Thanks for the reply... I havent always been completely up on the networking end of computers. I have been more hardware/software so its hard for me to explain exactly whats going on with the connection between the shared drive and the host computer.

I think I have a test environment setup so I will try out the scripts and see what I can do. I may have to set it as a startup script and what not to make sure the "reconnect at logon" actually works as it should because right now its not working the way I have understood it to do so. The drive becomes unavailable after one of the computers are restarted (just that computers drive).

I'll let you know if I have any more questions/problems, and I will also try to be more specific if possible.

JS

AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

Link to comment
Share on other sites

  • 9 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...