Import XML - Runtime Error 31592

M

Melissa M

I've had a procedure in a db which has worked just fine for the last several
months, up until today. The procedure executes this line:
Application.ImportXML DataSource:="http://" & P2L_URL &
"/P2L_PICK_TO_LABEL.aspx?ORDER_I=" & _
Left(Forms!frm_MainMenu.txtSalesOrder.Value, 8) & "&PRINT_I=" &
strP, ImportOptions:=acAppendData

and I get: Run-time error '31592' [Database Name] has encountered an error
processing the XML schema in file
'P2L_PICK_TO_LABEL.aspx?ORDER_I=29204982&PRINT_I=001'. Illegal xml character.

Anybody have any ideas?
 
P

Peter Doering

Melissa said:
I've had a procedure in a db which has worked just fine for the last several
months, up until today. The procedure executes this line:
Application.ImportXML DataSource:="http://" & P2L_URL &
"/P2L_PICK_TO_LABEL.aspx?ORDER_I=" & _
Left(Forms!frm_MainMenu.txtSalesOrder.Value, 8) & "&PRINT_I=" &
strP, ImportOptions:=acAppendData

and I get: Run-time error '31592' [Database Name] has encountered an error
processing the XML schema in file
'P2L_PICK_TO_LABEL.aspx?ORDER_I=29204982&PRINT_I=001'. Illegal xml character.

Anybody have any ideas?

The messages of these methods are fairly reliable. Have you checked the
file content on illegal characters? There could be a control characters
outside the supported range:

http://www.w3.org/TR/2006/REC-xml11-20060816/#charsets

Can you open the file with another XML reader like IE or XML notepad? See http://www.microsoft.com/downloads/...49-787d-4118-ba5f-4f30fe913628&displaylang=en
 
M

Melissa M

The file opens just fine in IE - that's why this is so frustrating. When I
enter the actual string created by the expression in the IE Address, the file
displays immediately.

Any other thoughts?

Peter Doering said:
Melissa said:
I've had a procedure in a db which has worked just fine for the last several
months, up until today. The procedure executes this line:
Application.ImportXML DataSource:="http://" & P2L_URL &
"/P2L_PICK_TO_LABEL.aspx?ORDER_I=" & _
Left(Forms!frm_MainMenu.txtSalesOrder.Value, 8) & "&PRINT_I=" &
strP, ImportOptions:=acAppendData

and I get: Run-time error '31592' [Database Name] has encountered an error
processing the XML schema in file
'P2L_PICK_TO_LABEL.aspx?ORDER_I=29204982&PRINT_I=001'. Illegal xml character.

Anybody have any ideas?

The messages of these methods are fairly reliable. Have you checked the
file content on illegal characters? There could be a control characters
outside the supported range:

http://www.w3.org/TR/2006/REC-xml11-20060816/#charsets

Can you open the file with another XML reader like IE or XML notepad? See http://www.microsoft.com/downloads/...49-787d-4118-ba5f-4f30fe913628&displaylang=en
 
P

Peter Doering

Melissa said:
The file opens just fine in IE - that's why this is so frustrating. When I
enter the actual string created by the expression in the IE Address, the file
displays immediately.

Any other thoughts?

As you can open the file, you can check for illegal characters. If IE
doesn't show any, they may be skipped during rendering. You can use a hex
viewer, e.g. then one included in Total Commander http://www.ghisler.com/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top