1

我想用 C# 创建一个远程桌面连接。我发现这个问题Run mstsc.exe with specified username and password

目前我可以使用用户名和密码创建一个新连接,但我想更改 .rdp 文件的保存路径。

也许您知道如何更改保存路径。

4

1 回答 1

0

最好设置默认路径,您可以创建rdp文件本身并将其保存在默认路径中。

rdp文件应包含以下内容。

"full address:s:" + IP
"username:s:" + User
"domain:s:" + Domain
"password 51:b:" + Pass
"port:i:" + Port
"screen mode id:i:1"
"desktopwidth:i:800"
"desktopheight:i:600"
"session bpp:i:32"
"auto connect:i:1"
"autoreconnection enabled:i:1"
"compression:i:1"
"keyboardhook:i:2"
"audiomode:i:2"
"redirectdrives:i:1"
"redirectprinters:i:1"
"redirectcomports:i:0"
"redirectsmartcards:i:0"
"displayconnectionbar:i:1"
"alternate shell:s:"
"shell working directory:s:"
"disable wallpaper:i:1"
"disable full window drag:i:1"
"disable menu anims:i:1"
"disable themes:i:1"
"bitmapcachepersistenable:i:1";
于 2015-10-26T10:34:37.710 回答