USE master
ALTER DATABASE myDatabase SET offline
ALTER DATABASE myDatabase MODIFY FILE (name=myDB_filename, FILENAME='X:\New_Path\myDatabase.mdf')
ALTER DATABASE myDatabase MODIFY FILE (name=myDB_logname, FILENAME='X:\New_Path\myDatabase_log.ldf')
** Physically move the files at this point to their new locations specified...