It depends what do you want to do. For example if you have in your system scrrun32.dll, you may use FileSystemObject to gain acces to disk. For this you must use extended stored procedures sp_OACreate, sp_OAMethod to create and call methods from activeX objects.
Another way, much more limited is the extended stored procedure xp_cmdshell. With this you may call all dos commands.
xcata.