Недопустимый знак xml excel

#xml #excel

#xml #excel

Вопрос:

Я получаю ошибку синтаксического анализа XML при импорте XML-файла в Excel 2007. Ошибка заключается в том, что «В текстовом содержимом был обнаружен недопустимый символ». В моем XML-файле в некоторых строках был обнаружен следующий недопустимый символ (`). Мое объявление XML-файла выглядит следующим образом… <?xml version="1.0"?> и получает ту же ошибку, если объявление XML равно as <?xml version="1.0" encoding="UTF-8"?> . Пожалуйста, найдите вложение для ошибки и дайте мне знать, как преодолеть эту ошибку, и дайте мне знать, нужно ли мне использовать какое-либо конкретное объявление XML в начале, чтобы пропустить эту ошибку.

Комментарии:

1. Попробуйте использовать онлайн-средство проверки, подобное этому, чтобы точно определить, в чем проблема с файлом XML

2. К сожалению, мое редактирование удалило его (возможно, потому, что редактор SO более умный), но копирование-вставка символа показала, что нарушителем был U 0014 DEVICE CONTROL FOUR , который является управляющим символом, не разрешенным в XML. Резервный шрифт Unicode часто полезен для идентификации этих символов.

Ответ №1:

Откройте свой XML-файл в notepad . Затем перейдите к строке, в которой excels говорит, что имеет недопустимый символ. Там будет какой-то символ Unicode, вам нужно будет его удалить.

Excel 2016 (16.0.6965.2076)

SQL Server 2014 (12.0.4213.0)

I have an SSRS report with 10 parameters — two are dates and the other 8 are text dropdowns using a query to populate the options. If I try to fetch this report into a Power Pivot Data Model in Excel (Power Pivot -> Manage -> From Other Sources -> Report), when completing the Table Import Wizard (after successfully specifying my report and parameter values and seeing the report render correctly in the wizard) by clicking on the Finish button on the Select Tables and Views page I receive an error message:

XML parsing failed at line 1345, column 36: Illegal xml character.

The line given varies depending on what parameter values I specify for the report, but the column is always 36. I have inspected my report and these line and column numbers do not appear to relate to my report, as often they are both greater than the total number of rows/columns being returned in the report.

I have looked around online and found a few resources which deal with this issue, but I’ve been unable to find a solution to my issue:

This blog and this associated Microsoft Connect ticket suggest that I can get this to work by exporting my report as a Data Feed and referencing that from within the Power Pivot wizard instead, but this also doesn’t work for me, I get a different error:

Unable to obtain schema for data feed ‘[Report feed Name]’. Please make sure this feed exists.

I have found suggestions elsewhere online that this subsequent error (or the original problem) may be as a result of the report URL being too long (including parameters/values). Unfortunately I cannot see any further way to reduce the URL length (currently over 700 characters), as I have minimised my parameter names and the report name, but still have this issue (I do not believe I can reduce the parameter values as they are fetched from an application database which we cannot change).

I have also seen suggestions to replace my «Get values from a query» parameters with «Specify values» parameters, but this is not viable as the parameter values must be fetched from the application database mentioned above and will change over time, so need to be fetched dynamically.

Can anyone suggest a solution or further troubleshooting steps I can follow for this issue?

RRS feed

  • Remove From My Forums
  • Question

  • hi,

    im having problems openning .xlsx on excel it says xml error on sharedstring, i oppened the in notepad, its a us symbol in a square..

    this file is an export file from a .rpt from crystal reports..

    with openoffice i dont have problems..funny.

    plz help.

    ty

All replies

  • Hi,

    As far as I know, the whole error message might be like this:

    >>Errors were detected in file ‘filename.xlsx’:
    Removed Part: /xl/sharedStrings.xml part with XML error.  (Strings) Illegal xml character. Line X, column XXXX.
    Removed Records: Cell information from /xl/worksheets/sheet1.xml part.<<

    It might be the case of an invalid character or an encoding error in the XML when export from crystal reports. I recommend we check error column XXXX and edit it to check if we could repair it manually.

    If we still can’t repair it, I suggest you upload this file and post the question to crystal reports forum.

    http://social.msdn.microsoft.com/Forums/en-US/home?forum=vscrystalreports

    Regards,

    George Zhao
    TechNet Community Support


    It’s recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • hi,

    ty for your help, i can find the error and i can repair it..

    its just for in the future to not
    always be
    doing this..

    strange that in openoffice there is no problem.

    ty

  • hi,

    im having problems openning .xlsx on excel it says xml error on sharedstring, i oppened the in notepad, its a us symbol in a square..

    this file is an export file from a .rpt from crystal reports..

    with openoffice i dont have problems..funny.

    plz help.

    ty

    ——————

    Hi,

    As far as I know, the whole error message might be like this:

    >>Errors were detected in file ‘filename.xlsx’:
    Removed Part: /xl/sharedStrings.xml part with XML error.  (Strings) Illegal xml character. Line X, column XXXX.
    Removed Records: Cell information from /xl/worksheets/sheet1.xml part.<<

    It might be the case of an invalid character or an encoding error in the XML when export from crystal reports. I recommend we check error column XXXX and edit it to check if we could repair it manually.

    If we still can’t repair it, I suggest you upload this file and post the question to crystal reports forum.

    http://social.msdn.microsoft.com/Forums/en-US/home?forum=vscrystalreports

    Regards,

    George Zhao
    TechNet Community Support

    ————————————

    <?xml version=»1.0″ encoding=»UTF-8″ standalone=»true»?>

    <style xmlns=»http://www.w3.org/1999/xhtml»>@namespace html url(http://www.w3.org/1999/xhtml); :root { font:small Verdana; font-weight: bold; padding: 2em; padding- } * { display: block; padding- } html|style { display: none; } html|span,
    html|a { display: inline; padding: 0; font-weight: normal; text-decoration: none; } html|span.block { display: block; } *[html|hidden], span.block[html|hidden] { display: none; } .expand { display: block; } .expand:before { content: ‘+’; color: red; }
    .collapse { display: block; } .collapse:before { content: ‘-‘; color: red; } </style><recoveryLog
    xmlnshttp://schemas.openxmlformats.org/spreadsheetml/2006/main«><logfilename><logFileName>error014361_01.xml</logFileName></logfilename><summary><summary>Foram
    detetados erros no ficheiro ‘C:Userspt7129Desktopteste.xlsx’</summary></summary><removedparts summary=»Segue-se uma lista de partes removidas:»><removedParts
    summarySegue-se uma lista de partes removidas:«><removedpart><removedPart>Parte
    Removida: Parte /xl/sharedStrings.xml com erro de XML.  (Cadeias) Carácter xml ilegal. Linha 2, coluna 1359714.</removedPart></removedpart></removedParts></removedparts><removedrecords
    summary=»Segue-se uma lista de registos removidos:»><removedRecords
    summarySegue-se uma lista de registos removidos:«><removedrecord><removedRecord>Registos
    Removidos: Informações da célula da parte /xl/worksheets/Sheet1.xml</removedRecord></removedrecord></removedRecords></removedrecords></recoveryLog>

    —————————

    <si><t>FFO-E01-1409/00148</t></si><si><t>FCL[usus]A414/00789</t></si>

    in notepad++ [usus] is square with us inside..

    plz help

    • Merged by

      Monday, October 6, 2014 5:25 AM
      same question

Проблемы

При попытке импорта данных из веб-источника в Microsoft Excel может появиться сообщение об ошибке, подобное следующему:

Не удается открыть файл, так как: недопустимое объявление XML.

За этим следуют строки, указывающие на расположение ошибки и версию XML-файла, предназначенную для языка наращиваемой.

Причина

Это происходит из-за того, что средству синтаксического анализа Excel XML требуется, чтобы знаки XML-тега <? > XML были абсолютно первыми символами на XML-странице. Им не могут предшествовать другие символы, а также символы пробелов, которые обычно игнорируются интерпретатором XML. Примечание. Средство синтаксического анализа XML в Microsoft Excel 2000 не будет работать в этих требованиях.

Обходное решение

Чтобы устранить эту ошибку, убедитесь в том, что в документах, которые будут открываться в качестве источников веб-данных в Excel, не требуется ничего, чем тег XML.

Статус

Корпорация Майкрософт подтверждает наличие этой проблемы в своих продуктах, которые перечислены в разделе «Применяется к».

Дополнительная информация

XML-документы с правильным форматом начинаются с объявления XML, которое определяет их как XML-документы и определяет используемую версию XML, как показано в следующем примере:

<?xml version="1.0"?>

Браузеры и другие программы, которые интерпретируют XML, обычно игнорируют пробелы (пробел, табуляция или новая строка) в исходном документе, а некоторые средства синтаксического анализа XML игнорируют эти символы, если они происходят впереди объявления XML. Тем не менее, в случае синтаксического анализа XML, включенного в Excel, важно, чтобы ни один из этих знаков не предшествует объявлению XML. Средство синтаксического анализа XML, которое входит в состав Excel 2000, а также многие браузеры, не пропускует символы пробела перед объявлением XML. Таким образом, документы, которые могли открыться в этих средах в обычном режиме, создают сообщение об ошибке, описанное в разделе «симптомы» этой статьи при использовании веб-запросов в Excel.

Нужна дополнительная помощь?

0 / 0 / 0

Регистрация: 23.04.2022

Сообщений: 2

1

23.04.2022, 09:32. Показов 1010. Ответов 3


Студворк — интернет-сервис помощи студентам

При попытке открыть файл xml в Excel выбивает ошибку «в текстовом комментарии обнаружен недопустимый знак». Как это можно исправить?

файл.zip



0



малоболт

1143 / 442 / 193

Регистрация: 30.01.2020

Сообщений: 1,095

23.04.2022, 10:33

2

Цитата
Сообщение от armstronger
Посмотреть сообщение

Как это можно исправить?

Взяв нормальный xml файл, а не совершенно пустой файл на много-много мегабайт.



0



0 / 0 / 0

Регистрация: 23.04.2022

Сообщений: 2

23.04.2022, 10:36

 [ТС]

3

Проблема в том, что он не пустой, но не отображает данные.



0



малоболт

1143 / 442 / 193

Регистрация: 30.01.2020

Сообщений: 1,095

23.04.2022, 10:43

4

Цитата
Сообщение от armstronger
Посмотреть сообщение

Проблема в том, что он не пустой, но не отображает данные.

Тот, что вы приложили — пуст полностью. Там нет ни одного символа. 27МБ пустоты.



0



IT_Exp

Эксперт

87844 / 49110 / 22898

Регистрация: 17.06.2006

Сообщений: 92,604

23.04.2022, 10:43

4

Понравилась статья? Поделить с друзьями:
  • Недопустимые ссылки excel как найти
  • Недопустимые символы в excel
  • Недопустимое имя сводной таблицы в excel причина
  • Недопустимое имя microsoft excel
  • Недопустимая ссылка на расположение в excel график