Page 1 of 1

Using Camera on Windows for CSPRO

Posted: October 28th, 2019, 3:25 pm
by lmoriba
Hi CSPRO community,

I want to know if CSPRO supports Camera on windows based tablets. If so , what is the program for doing that. I need this information urgent because I am running a survey which will capture photos and we are planning to purchase Windows Tables because the survey has lots of rosters.

Thanks.

Re: Using Camera on Windows for CSPRO

Posted: October 29th, 2019, 11:36 am
by savy
Unfortunately, CSPro Desktop Application does not provide support for camera as it does on Android.

Re: Using Camera on Windows for CSPRO

Posted: October 29th, 2019, 7:21 pm
by josh
You can launch the camera from the command line in Windows 10 by calling "start microsoft.windows.camera:" so you could write that out to a .bat file and call that from your CSPro logic using execsystem. This isn't a great solution since it just starts the camera but doesn't give you a way to specify the name of the file to save the picture to. But here is the logic you would use:
    file launchScript;
    
    
setfile(launchScript, pathname(Application) + "launchcamera.bat");
    
filewrite(launchScript, "");
    
filewrite(launchScript, "start  microsoft.windows.camera:");
    
close(launchScript);
    
execsystem(filename(launchScript));
An alternative might be to find another application that you can launch from a .bat file but that lets you specify the file name for the picture. There is this one for example: https://batchloaf.wordpress.com/commandcam/ I have never tried it so I'm not sure if it would work.