|
![]() | 作者: amp34 [amp34]
![]() |
登录 |
因为见别人做过。想改一下,所以自己也想知道怎么做。 执行命令已经可以了。但是不知道怎么返回DOS的回显。。。我的连接代码是: Dim cm As New ADODB.Command cm.CommandType = adCmdTable cm.CommandText = "xp_cmdshell 'dir'" 不知道怎么回显。试了几次。不知道要加什么参数。。。。或是不可以直接显示,要在数据库添加回显,然后读取后再删掉????? 忘知道的大大帮帮小弟。在此谢过。。。。。 |
地主 发表时间: 04-12-21 23:09 |
![]() | 回复: 286 [unique] ![]() |
登录 |
回显是什么意思? cm.CommandText = "xp_cmdshell 'dir>a.txt'" cm.CommandText = "xp_cmdshell type a.txt'" |
B1层 发表时间: 04-12-22 13:02 |
![]() | 回复: amp34 [amp34] ![]() |
登录 |
回显就是返回执行命令以后的信息咯。 如果用type 可以显示的话。那都不用dir >a.txt咯。 我想知道的是。如果返回了这些信息,如何显示出来。返回的信息是存放在哪的。 谢谢大大。 |
B2层 发表时间: 04-12-26 02:42 |
![]() | 回复: battle [battle] ![]() |
登录 |
用connect和Recordset比较方便 set recordset = connect.execute(xp_cmdshell .....) 返回的数据会放在Recordset里面 然后读出来就可以了.. |
B3层 发表时间: 04-12-29 18:27 |
|
20CN网络安全小组版权所有
Copyright © 2000-2010 20CN Security Group. All Rights Reserved.
论坛程序编写:NetDemon
粤ICP备05087286号