Error Running Geoprocessor in C#

1632
1
02-28-2012 09:19 AM
MasroorHussain
New Contributor II
Hi Guys

I am having a problem running the Geoprocessor  C#.
I want to extract values from multiple rasters to points (shape file). Getting the following error message at running the geoprocessor.

???Attempted to read or write protected memory. This is often an indication that other memory is corrupt.???

Need urgent help please .....

Masroor
0 Kudos
1 Reply
NobbirAhmed
Esri Regular Contributor
Could you please surround your code with try-catch and get gp messages in the catch block? What messages do you get?

Here is a snippet:
    Geoprocessor gp = new Geoprocessor()

    try{
        // your execution code here ...
    }
    catch(Exception ex){
        console.writeline(ex.Message);
        object sev = 2;
        console.writeline(gp.GetMessages(ref sev));
    }
0 Kudos