Page 1 of 1
CaptureSingleFrameTo error
Posted: Sat Jan 27, 2018 2:16 am
by denjoan
When I execute the following command:
SharpCap.SelectedCamera.CaptureSingleFrameTo("c:\test.fits")
I get the error message:
Path must be an absolute path
Not sure why I get this message.
Thank you.
Dennis
Re: CaptureSingleFrameTo error
Posted: Sat Jan 27, 2018 11:57 am
by admin
Hi,
I think that the python language is interpreting 'c:\test.fits' as 'c:<tab>est.fits' since '\t' is the way to put a tab in a python string. Try 'c:\\test.fits' - I think that's the right way to do it.
cheers,
Robin
Re: CaptureSingleFrameTo error
Posted: Sat Jan 27, 2018 12:11 pm
by denjoan
Hi Robin,
Actually, I found that if "/" is used instead of "\", it works - must be a Windows file naming thing.
Thanks anyway for your response.
Dennis
Re: CaptureSingleFrameTo error
Posted: Sat Jan 27, 2018 12:13 pm
by denjoan
Hi Robin,
BTW: your suggestion works as well.
Dennis