Attempted to read or write protected memory

Discussions about barcode reading and writing
Post Reply
jacok
Posts: 4
Joined: Tue May 27, 2008 3:34 pm

Attempted to read or write protected memory

Post by jacok » Mon Feb 07, 2011 3:38 pm

Hi there,

We are getting the above error, specifically "Attempted to read or write protected memory. This is often an indication that other memory is corrupt."

This is when we try to do barcode recognition as per the following code snippet:

string curFile = "c:\\test.tif";
ArrayList arBarcodes = new ArrayList();
int iImg = gdImaging1.CreateGdPictureImageFromFile(curFile);
gdImaging1.Barcode1DReaderDoScan(iImg, Barcode1DReaderScanMode.BestQuality);
for (int i = 1; i <= gdImaging1.Barcode1DReaderGetBarcodeCount(); i++)
{ arBarcodes.Add(gdImaging1.Barcode1DReaderGetBarcodeValue(i)); }

We are running the current version of GdPicture.NET on VS2008 with all updates and service packs installed. The purpose of this application is to run through thousands of .tif files and take action depending on any barcodes found in the files. I would estimate around one in 10000 files cause this error.

Thank you in advance for your help. Let me know if you need a file that causes this error.

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Attempted to read or write protected memory

Post by Loïc » Mon Feb 07, 2011 4:32 pm

Hi,

Please send the file + a code snippet which reproduce the error at https://www.gdpicture.com/support/getting-support-from-our-team

We should fix the problem quickly.

Kind regards,

Loïc

jacok
Posts: 4
Joined: Tue May 27, 2008 3:34 pm

Re: Attempted to read or write protected memory

Post by jacok » Tue Feb 08, 2011 8:44 am

Thank you very much Loïc,

Done, ticket id is 8861.

Jaco

jacok
Posts: 4
Joined: Tue May 27, 2008 3:34 pm

Re: Attempted to read or write protected memory

Post by jacok » Wed Feb 09, 2011 9:42 am

Thank you so much for the quick resolution of this problem Loïc,

The support I have received so far has been great!

Jaco

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Attempted to read or write protected memory

Post by Loïc » Thu Feb 10, 2011 4:28 pm

Thank you very much for the public feedback Jaco :)

Loïc

ganeshj
Posts: 14
Joined: Fri Aug 07, 2009 7:46 am

Re: Attempted to read or write protected memory

Post by ganeshj » Tue Aug 30, 2011 7:34 am

Loic,

We are facing exactly the same problem. Can you let me know what the issue could be.

Regards
Ganesh

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Attempted to read or write protected memory

Post by Loïc » Tue Aug 30, 2011 7:35 am

Hi,

Please check you are using latest version.

If the problem still exists: send the file + a code snippet which reproduce the error at https://www.gdpicture.com/support/getting-support-from-our-team

Kind regards,

Loïc

vishalkb
Posts: 1
Joined: Mon Mar 25, 2013 4:24 am

Re: Attempted to read or write protected memory

Post by vishalkb » Mon Mar 25, 2013 4:26 am

Hi Guys,

We are having the same issue. Can you please tell me what the fix for this issue is? I see that it has been resolved for another user.

Regards

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Attempted to read or write protected memory

Post by Loïc » Mon Mar 25, 2013 7:12 pm

Hello,

Please see answer above:
Please check you are using latest version.

If the problem still exists: send the file + a code snippet which reproduce the error at https://www.gdpicture.com/support/getting-support-from-our-team

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest