I have design a Customer Report in Nav2009 sp1,but when I run it,The Error is :the metadata of 50001 is invalid,See Event View! Then I have seen the Event View Error:Service: MicrosoftDynamicsNavServer
User: 65D667C8937D4F0\Administrator
Type: System.Xml.XmlException
LineNumber: 391
LinePosition: 10
Message: '.', hexadecimal value 0x00, is an invalid character. Line 391, position 10.
StackTrace:
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.Throw(String res, String[] args)
at System.Xml.XmlTextReaderImpl.Throw(Int32 pos, String res, String[] args)
at System.Xml.XmlTextReaderImpl.ThrowInvalidChar(Int32 pos, Char invChar)
at System.Xml.XmlTextReaderImpl.ParseCDataOrComment(XmlNodeType type, Int32& outStartPos, Int32& outEndPos)
at System.Xml.XmlTextReaderImpl.ParseCDataOrComment(XmlNodeType type)
at System.Xml.XmlTextReaderImpl.ParseElementContent()
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace)
at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc)
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.LoadXml(String xml)
at Microsoft.Dynamics.Nav.Service.Metadata.MetadataProvider.GetNavObjectAsXMLDocument(Int32 id, ObjectType navObjectType)
at Microsoft.Dynamics.Nav.Service.Metadata.MetadataProvider.<>c__DisplayClass7.<GetNavObjectAsXMLDocumentUsingCache>b__6()
at Microsoft.Dynamics.Nav.Types.Cache.GlobalVersionCache`2.GetItem[TItem](TKey key, ObtainItem`1 obtainItem)
at Microsoft.Dynamics.Nav.Service.Metadata.MetadataProvider.GetNavObjectAsXMLDocumentUsingCache(Int32 id, ObjectType navObjectType)
at Microsoft.Dynamics.Nav.Service.Metadata.MetadataProvider.GetReportMetadata(Int32 id)
Source: System.Xml
Please help me friends!
0
Answers
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
OBJECT Report 50001 CustBalance
{
OBJECT-PROPERTIES
{
Date=09-09-08;
Time=12:44:14 上午;
Modified=Yes;
Version List=GRUBBY;
}
PROPERTIES
{
}
DATAITEMS
{
{ PROPERTIES
{
DataItemTable=Table18;
ReqFilterFields=No.;
}
SECTIONS
{
{ PROPERTIES
{
SectionType=Body;
SectionWidth=12000;
SectionHeight=1692;
}
CONTROLS
{
{ 1000000000;TextBox;450 ;0 ;1500 ;423 ;SourceExpr="No.";
DataSetFieldName=Customer__No__ }
{ 1000000001;Label ;450 ;0 ;1500 ;846 ;ParentControl=1000000000;
VertAlign=Bottom;
FontBold=Yes;
MultiLine=Yes;
DataSetFieldName=Customer__No__Caption }
{ 1000000002;TextBox;2100 ;0 ;4500 ;423 ;SourceExpr=Name;
DataSetFieldName=Customer_Name }
{ 1000000003;Label ;2100 ;0 ;4500 ;846 ;ParentControl=1000000002;
VertAlign=Bottom;
FontBold=Yes;
MultiLine=Yes;
DataSetFieldName=Customer_NameCaption }
{ 1000000004;TextBox;7800 ;0 ;1800 ;423 ;SourceExpr="Balance (LCY)";
DataSetFieldName=Customer__Balance__LCY__ }
{ 1000000005;Label ;7800 ;0 ;1800 ;846 ;ParentControl=1000000004;
HorzAlign=Right;
VertAlign=Bottom;
FontBold=Yes;
MultiLine=Yes;
DataSetFieldName=Customer__Balance__LCY__Caption }
}
}
}
}
}
REQUESTFORM
{
PROPERTIES
{
Width=9020;
Height=3410;
}
CONTROLS
{
}
}
REQUESTPAGE
{
PROPERTIES
{
}
CONTROLS
{
}
}
CODE
{
BEGIN
END.
}
RDLDATA
{
<?xml version="1.0" encoding="utf-8"?>
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<Body>
<ColumnSpacing>1cm</ColumnSpacing>
<Height>2.5cm</Height>
<ReportItems>
<Table Name="table1">
<DataSetName>DataSet_Result</DataSetName>
<Details>
<TableRows>
<TableRow>
<Height>0.63492cm</Height>
<TableCells>
<TableCell>
<ReportItems>
<Textbox Name="Customer__No__">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value>=First(Fields!Customer__No__.Value)</Value>
<ZIndex>2</ZIndex>
<rd:DefaultName>Customer__No__</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="textbox1">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<ZIndex>1</ZIndex>
<rd:DefaultName>textbox1</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="textbox3">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<rd:DefaultName>textbox3</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
</TableCells>
</TableRow>
</TableRows>
</Details>
<Footer>
<TableRows>
<TableRow>
<Height>0.63492cm</Height>
<TableCells>
<TableCell>
<ReportItems>
<Textbox Name="textbox7">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<ZIndex>5</ZIndex>
<rd:DefaultName>textbox7</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="textbox2">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<ZIndex>4</ZIndex>
<rd:DefaultName>textbox2</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="Customer__Balance__LCY__">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<TextAlign>Right</TextAlign>
</Style>
<Value />
<ZIndex>3</ZIndex>
<rd:DefaultName>Customer__Balance__LCY__</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
</TableCells>
</TableRow>
</TableRows>
</Footer>
<Header>
<TableRows>
<TableRow>
<Height>0.63492cm</Height>
<TableCells>
<TableCell>
<ReportItems>
<Textbox Name="Customer__No__Caption">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value>=First(Fields!Customer__No__Caption.Value)</Value>
<ZIndex>8</ZIndex>
<rd:DefaultName>Customer__No__Caption</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="textbox5">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<ZIndex>7</ZIndex>
<rd:DefaultName>textbox5</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
<TableCell>
<ReportItems>
<Textbox Name="textbox4">
<CanGrow>true</CanGrow>
<Style>
<FontFamily>宋体</FontFamily>
<PaddingBottom>2pt</PaddingBottom>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<Value />
<ZIndex>6</ZIndex>
<rd:DefaultName>textbox4</rd:DefaultName>
</Textbox>
</ReportItems>
</TableCell>
</TableCells>
</TableRow>
</TableRows>
</Header>
<Height>1.90476cm</Height>
<Style>
<FontFamily>宋体</FontFamily>
</Style>
<TableColumns>
<TableColumn>
<Width>10cm</Width>
</TableColumn>
<TableColumn>
<Width>10cm</Width>
</TableColumn>
<TableColumn>
<Width>10cm</Width>
</TableColumn>
</TableColumns>
</Table>
</ReportItems>
</Body>
<BottomMargin>2.5cm</BottomMargin>
<Code>Public Function BlankZero(ByVal Value As Decimal)
if Value = 0 then
Return ""
end if
Return Value
End Function
Public Function BlankPos(ByVal Value As Decimal)
if Value > 0 then
Return ""
end if
Return Value
End Function
Public Function BlankZeroAndPos(ByVal Value As Decimal)
if Value >= 0 then
Return ""
end if
Return Value
End Function
Public Function BlankNeg(ByVal Value As Decimal)
if Value < 0 then
Return ""
end if
Return Value
End Function
Public Function BlankNegAndZero(ByVal Value As Decimal)
if Value <= 0 then
Return ""
end if
Return Value
End Function
</Code>
<DataSets>
<DataSet Name="DataSet_Result">
<Fields>
<Field Name="Customer__No__">
<DataField>Customer__No__</DataField>
</Field>
<Field Name="Customer__No__Caption">
<DataField>Customer__No__Caption</DataField>
</Field>
<Field Name="Customer_Name">
<DataField>Customer_Name</DataField>
</Field>
<Field Name="Customer_NameCaption">
<DataField>Customer_NameCaption</DataField>
</Field>
<Field Name="Customer__Balance__LCY__">
<DataField>Customer__Balance__LCY__</DataField>
</Field>
<Field Name="Customer__Balance__LCY__Format">
<DataField>Customer__Balance__LCY__Format</DataField>
</Field>
<Field Name="Customer__Balance__LCY__Caption">
<DataField>Customer__Balance__LCY__Caption</DataField>
</Field>
</Fields>
<Query>
<CommandText />
<DataSourceName>DummyDataSource</DataSourceName>
</Query>
<rd:DataSetInfo>
<rd:DataSetName>DataSet</rd:DataSetName>
<rd:TableName>Result</rd:TableName>
</rd:DataSetInfo>
</DataSet>
</DataSets>
<DataSources>
<DataSource Name="DummyDataSource">
<ConnectionProperties>
<ConnectString />
<DataProvider>SQL</DataProvider>
</ConnectionProperties>
<rd:DataSourceID>35f0fe1e-12fa-4983-8052-593d59e3e571</rd:DataSourceID>
</DataSource>
</DataSources>
<InteractiveHeight>29.7cm</InteractiveHeight>
<InteractiveWidth>21cm</InteractiveWidth>
<Language>zh-CN</Language>
<LeftMargin>2.5cm</LeftMargin>
<PageFooter>
<Height>0.75cm</Height>
<PrintOnFirstPage>true</PrintOnFirstPage>
<PrintOnLastPage>true</PrintOnLastPage>
</PageFooter>
<PageHeader>
<Height>0.75cm</Height>
<PrintOnFirstPage>true</PrintOnFirstPage>
<PrintOnLastPage>true</PrintOnLastPage>
</PageHeader>
<PageHeight>29.7cm</PageHeight>
<PageWidth>21cm</PageWidth>
<RightMargin>2.5cm</RightMargin>
<TopMargin>2.5cm</TopMargin>
<Width>30cm</Width>
<rd:DrawGrid>true</rd:DrawGrid>
<rd:GridSpacing>0.25cm</rd:GridSpacing>
<rd:ReportID>60d50698-e977-461b-912e-d7159439947a</rd:ReportID>
<rd:SnapToGrid>true</rd:SnapToGrid>
</Report>
END_OF_RDLDatA
}
}
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.