In VB6, I can turn webcam on, close it, & save an image. But, I get a green screen in the picture box when I use the Format after first time. Then, I notice I can tell it to save a pic without the canera being on and it bombs out. Of course, the obvious is that nobody should click Save Pic without the camera being on but I'm sure somebody would test it. Is there code test to see if the camera is on then turn it on if not? I can test if the built-in camera is available but that's not the same as whether it's on!!!
Nothing much. I just put code temporarily that automatically go to turn camera on when the save pic is clicked just so it doesn't bomb out. But, if the camera wasn't on, I don't see the pic it saves ahead of time. I would prefer to put an error handling routine there instead.