PDA

View Full Version : MemorySnapImage hangs



niranjan
June 9, 2008, 15:22:59
Dear All,
I am using DMx 21AF04 in VB6.0 application.

Here is my initialization code -

Dim DeviceCollection As Devices
Set DeviceCollection = ICImagingControl1.Devices
If DeviceCollection.Count > 0 Then
' If devices have been found, select the first device.
ICImagingControl1.Device = "DMx 21AF04"
'start live capture
ICImagingControl1.LiveStart
bVideoStarted = True
Else
' No devices have been found.
End If

Here is the code called every 30 seconds -
If ICImagingControl1.LiveVideoRunning Then
' The live video is running. Therefore, we need to grab the
' current frame.


'SAVE THE LAST IMAGE IN MEMORY
ICImagingControl1.MemorySnapImage

'FROM MEMORY TO FILE
ICImagingControl1.MemorySaveImage "currentImage.bmp"
.
. SOME PROCESSING AND DISPLAY RESULTS.
.
End If

If I keep this running for multiple days together, sometimes the code hangs in MemorySnapImage function and I get a dialog box with timeout message. I have set the MemorySnapTimeOut = -1.

In my application I need to take image of an object every 30 seconds, perform some analysis and display results continuously.

Can anyone please help me? Its very urgent.

I appreciate your reply.

Thanks,
Niranjan

Stefan Geissler
June 9, 2008, 16:27:28
Hello Niranjan,

I send you additionally to my last email the download for the latest version of IC Imaging Control.