The VB trick to get the path of the current temporary directory:
Private Declare Function GetTempPath Lib \"kernel32\" Alias \"GetTempPathA\" (ByVal nBufferL
You can also keep using the GetTempPath API. It's a bit tricky to call APIs from vbscript though. Here are some pointers on how to make Win32 API calls from vbscript:
GetTempPath
Reference 1
Reference 2
Reference 3