添加打印机和映射驱动器 [英] Adding Printers and Mapping Drives

查看:90
本文介绍了添加打印机和映射驱动器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好;

我的诊所中有很多新计算机,我想自动完成从网络映射驱动器以及将打印机添加到每台计算机的过程.机器将被设置并加入我们的域,然后移交给 诊所.我希望有一个从拇指驱动器访问的程序,用户可以运行它,然后它将网络驱动器映射到计算机,并且还向PC添加本地打印机(使用本地标准TCP/IP端口) .所有地点 和地址是已知的,因此我希望能够插入"值并让程序完成其余的工作.

I have many new computers coming into our clinic, and I would like to automate the process of mapping a drive from the network and also adding the printer to each one.  The machines will be set up and joined to our domain and then turned over to the clinic.  I would like to have a program accessed from a thumb drive and the user can run it and it would then map a network drive to the machine and also add a local printer (using a local standard TCP/IP port) to the PC as well.  All the locations and addresses are known, so I want to be able to just "plug in" the values and have the program do the rest.

任何帮助都会很棒.谢谢.

Any help would be great.  Thanks.

John

推荐答案

我的诊所中有很多新计算机,我想自动化从网络映射驱动器并将每个打印机添加到打印机的过程.

I have many new computers coming into our clinic, and I would like to automate the process of mapping a drive from the network and also adding the printer to each one.

尽管其中一些任务可以使用.Net Framework组件完成,但使用Windows中的内置实用程序可能会更容易.您可以使用从应用程序内部启动的进程来执行此操作(在命令中传递参数) 行),或者您可以编写一个批处理文件,并使用代码替换参数,然后执行该批处理文件.您可能最终会使用混合代码.

While some of these tasks can probably be done using .Net Framework components, it is probably easier to use the built-in utilities in Windows.  You can do this using processes started from within your application (with arguments passed in the command line), or you can write a batch file with the parameters replaced using code, and then execute the batch file.  You will probably end up using a mixture. 

在任何一种情况下,起点都是列出手动执行这些任务所要使用的确切过程.

In either case, the starting point is setting out the exact process that you would use to do these tasks manually. 

当您知道需要做什么时,请参见此处:
https://msdn.microsoft.com/zh-CN /library/system.diagnostics.process(v=vs.110).aspx

When you know what you need to do, see here:
https://msdn.microsoft.com/en-us/library/system.diagnostics.process(v=vs.110).aspx

对于您找不到与命令和命令行参数有关的任何方法,请描述任务,某人可能会从框架内知道实现此方法的方法.

For anything that you can't find a way to do with commands and command line arguments, describe the task and someone may know a way to do it from within the framework.


这篇关于添加打印机和映射驱动器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆