I continually get an access violation at read of address 0xfeeefeee where the debugger stops on the Ntdll.NtRaiseException, I can not debug further as I get a loop condition telling me that the app has faulted at ... Use step or run... and this takes me back to the beginning. This obviously only happens in the IDE (Delphi XE2) 32 bit. My application is using the following bits of code
Var
XMLDoc: IXMLDocument;
Begin
If FOD.Execute Then //File Open Dialog
Begin
Try
Try
XMLdoc := NewXMLDocument(); //TXMLDocument.Create(Nil);
Result := FOD.FileName;
XMLDoc.FileName := XMLFilename;
XMLDoc.Active := True;
when the file opens I call functions loaded from the xml data binding wizard (File New Other XML) to parse the xml file opened in the proc above. My intent is just to create a csv file and then use sqlldr to export the data to an oracle database. Outside of the IDE all works find, and I can leave the application running just showing the data in a sring grid overnight but in the ide it crashes within minutes. The call stack shows me nothing usefull. As you can see I have tried TXMDocument.create, as well as NewXML but to no avail. I have tried putting the object on the form and using that instance to no avail. Anyone please have any ideas. (Windows 7 64 bit, but I am complining into 32 bit due to the oracle depenancies)
Edit, The call stack even with debug dcus switched on shows nothing of use just references to ole32.dll and other nt related dlls
The code for the app is shown below (some of it)
Function TXMLForm.OpenFile: String;
Var
XMLDoc: IXMLDocument;
Begin
If FOD.Execute Then
Begin
Try
Try
XMLdoc := NewXMLDocument(); //TXMLDocument.Create(Nil);
Result := FOD.FileName;
XMLDoc.FileName := XMLFilename;
XMLDoc.Active := True;
SB1.Panels[1].Text := FOD.Filename;
Finally
// xmldoc := nil;
End;
Except
On E: Exception Do
ShowMessage('Excpetion in Opening or creating XML Document. ' + E.Message);
End;
End
Else
Result := '';
End;
The openfile is called by this type of procedure
Procedure TXMLForm.StandardProfile1Click(Sender: TObject);
Var
Stand: Standard.IXMLProfileData;
I, X: Integer;
Begin
XMLFileName := Openfile;
If Xmlfilename <> '' Then
Begin
Stand := Standard.LoadProfileData(XMLFileName);
SG1.RowCount := Stand.Count;
Sg1.ColCount := Stand.Device[Stand.Count - 1].Count + 7;
// SG1.ColCount := 55;
SG1.Cells[0, 0] := 'SERIALNO';
SG1.Cells[1, 0] := 'MFGSERIALNO';
SG1.Cells[2, 0] := 'SUPPLYTYPE';
SG1.Cells[3, 0] := 'SERVICEPOINTNO';
SG1.Cells[4, 0] := 'PARAMETERCODE';
SG1.Cells[5, 0] := 'INTERVALPERIOD';
SG1.Cells[6, 0] := 'STARTTIME';
// For X := 0 To 47 Do
// SG1.Cells[7 + X, 0] := 'INTERVAL' + Inttostr(X);
For X := 0 To Stand.Device[Stand.Count - 1].Count - 1 Do
SG1.Cells[7 + X, 0] := 'INTERVAL' + Inttostr(X);
For I := 0 To Stand.Count - 1 Do
Begin
SG1.Cells[0, I + 1] := Stand.Device[I].SerialNo;
SG1.Cells[1, I + 1] := Stand.Device[I].MfgSerialNo;
SG1.Cells[2, I + 1] := Stand.Device[I].SupplyType;
SG1.Cells[3, I + 1] := Stand.Device[I].ServicePointNo;
SG1.Cells[4, I + 1] := Stand.Device[I].ParameterCode;
SG1.Cells[5, I + 1] := Stand.Device[I].IntervalPeriod;
SG1.Cells[6, I + 1] := Stand.Device[I].StartTime;
// For X := 0 To 47 Do
For X := 0 To Stand.Device[Stand.Count - 1].Count - 1 Do // 47
Begin
If Stand.Device[I].Interval[X] = '' Then
SG1.Cells[7 + X, I + 1] := 'TRUE'
Else
SG1.Cells[7 + X, I + 1] := Stand.Device[I].Interval[X];
End;
End;
End;
End;
As stated before I have tried using the TXMDocument, the IXMLDocument and using Create and NewXMDocument but this still gives the errors. DEbug dcus' makes no difference. I have tired using FastMM4 in the project header and MadExcept but they don't catch the error.