SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On



opening a folder Expand / Collapse
Author
Message
Posted Tuesday, September 15, 2009 1:23 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, February 28, 2010 10:27 PM
Points: 45, Visits: 135
Hi, is there any code in command prompt (which i can execute using xp_cmdshell ) to open a directory?
Post #787952
Posted Tuesday, September 15, 2009 8:37 AM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: 2 days ago @ 2:04 AM
Points: 1,725, Visits: 2,366
explorer.exe is the executable that you can run...
eg explorer c:\ will open the explorer with initial folder set to c:\
Its working in command prompt but not with xp_cmdshell..





Pradeep Singh
Post #788208
Posted Tuesday, September 15, 2009 8:52 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: Administrators
Last Login: 2 days ago @ 8:26 PM
Points: 23,166, Visits: 6,925
What are you trying to accomplish? When you shell out, you aren't using your login, you're using a service account (or proxy) login. running explorer.exe won't get you anything.
Post #788228
Posted Tuesday, September 15, 2009 6:53 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, February 28, 2010 10:27 PM
Points: 45, Visits: 135
ps (9/15/2009)
explorer.exe is the executable that you can run...
eg explorer c:\ will open the explorer with initial folder set to c:\
Its working in command prompt but not with xp_cmdshell..


PS, i've tried using explorer c:\, and it worked in command prompt... but it made me sad that it doesn't work in xp_cmdshell...

I want to open a folder using xp_cmdshell because when i execute xcopy using xp_cmdshell to auto copy my backup file to another destination, xcopy only copies my backup file when the destination folder is open. when it's not open, my job for xcopy returns "succeeded" but it didn't really copied my backup file to the destination... is there anything you can suggest for my problem?
Post #788653
Posted Tuesday, September 15, 2009 6:55 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, February 28, 2010 10:27 PM
Points: 45, Visits: 135
ps (9/15/2009)
explorer.exe is the executable that you can run...
eg explorer c:\ will open the explorer with initial folder set to c:\
Its working in command prompt but not with xp_cmdshell..


PS, i've tried using explorer c:\, and it worked in command prompt... but it made me sad that it doesn't work in xp_cmdshell...

I want to open a folder using xp_cmdshell because when i execute xcopy using xp_cmdshell to auto copy my backup file to another destination, xcopy only copies my backup file when the destination folder is open. when it's not open, my job for xcopy returns "succeeded" but it didn't really copied my backup file to the destination... is there anything you can suggest for my problem?
Post #788655
Posted Tuesday, September 15, 2009 6:57 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Sunday, February 28, 2010 10:27 PM
Points: 45, Visits: 135
ps (9/15/2009)
explorer.exe is the executable that you can run...
eg explorer c:\ will open the explorer with initial folder set to c:\
Its working in command prompt but not with xp_cmdshell..


PS, i've tried using explorer c:\, and it worked in command prompt... but it made me sad that it doesn't work in xp_cmdshell...

I want to open a folder using xp_cmdshell because when i execute xcopy using xp_cmdshell to auto copy my backup file to another destination, xcopy only copies my backup file when the destination folder is open. when it's not open, my job for xcopy returns "succeeded" but it didn't really copied my backup file to the destination... is there anything you can suggest for my problem?
Post #788657
« Prev Topic | Next Topic »


Permissions Expand / Collapse