Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Check an Excel workbook availability
#6
Not Solved
Hi!

Thank you supputuri,

Your help is greatly appreciated.

After navigating in forums for a day, it seems that wscript and cscript are unavailable in QTP because they are "Host specific object ". I guess this would discard the Wshell solution?
Quote:2) Create Wshell object pointing to the remote box where the file is opened and then use popup method.


For your first option, the WMI, it seems the right way to go.
Quote:1) Using WMI and send message

I already have some wmi in my script

Code:
Function GetFileOwner(strFileName)
'    http://www.vbsedit.com/scripts/security/ownership/scr_1386.asp
     Set objWMIService = GetObject("winmgmts:")
     Set objFileSecuritySettings = _
     objWMIService.Get("Win32_LogicalFileSecuritySetting='" & strFileName & "'")
     intRetVal = objFileSecuritySettings.GetSecurityDescriptor(objSD)

The thing is, I really have no clue how to code this. Sad

May I ask for your help? Is there something I could work out of the above code to send a message?

Also, in case someone would be interested, forgot to mention I took my code here http://stackoverflow.com/questions/15555...7#16820357


Thanks,
François
Reply


Messages In This Thread
Check an Excel workbook availability - by utestqa - 05-28-2013, 07:57 PM
RE: Check an Excel workbook availability - by utestqa - 05-30-2013, 06:42 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How to check whether data exists in excel.. venkatesh9032 1 3,084 03-06-2014, 04:37 PM
Last Post: supputuri

Forum Jump:


Users browsing this thread: 1 Guest(s)