rdlc tablix文本运行值对齐中心

时间:2019-03-18 14:26:27

标签: c# .net visual-studio rdlc

我是rdlc报表的新手,我想知道如何将textrun值居中对齐。我想对齐所有值。我已经尝试用textalign center添加样式标签,但是它不能解决我需要解决的任何问题 这是我的代码

<?xml version="1.0" encoding="utf-8"?>
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2008/01/reportdefinitio" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<Body>
<ReportItems>
  <Tablix Name="Tablix2">
    <TablixBody>
      <TablixColumns>
        <TablixColumn>
          <Width>1.26511in</Width>
        </TablixColumn>
        <TablixColumn>
          <Width>1.53594in</Width>
        </TablixColumn>
        <TablixColumn>
          <Width>1.37969in</Width>
        </TablixColumn>
        <TablixColumn>
          <Width>1.19218in</Width>
        </TablixColumn>
      </TablixColumns>
      <TablixRows>
        <TablixRow>
          <Height>0.26042in</Height>
          <TablixCells>
            <TablixCell>
              <CellContents>
                <Textbox Name="Textbox8">
                  <CanGrow>true</CanGrow>
                  <KeepTogether>true</KeepTogether>
                  <Paragraphs>
                    <Paragraph>
                      <TextRuns>
                        <TextRun>
                          <Value>Invoice Code</Value>
                          <Style>
                            <FontFamily>calibri</FontFamily>
                            <FontWeight>Bold</FontWeight>
                              <TextAlign>Center</TextAlign>
                          </Style>
                        </TextRun>
                      </TextRuns>
                      <Style />
                    </Paragraph>
                  </Paragraphs>
                  <rd:DefaultName>Textbox8</rd:DefaultName>
                  <Style>
                    <Border>
                      <Color>LightGrey</Color>
                      <Style>Solid</Style>
                    </Border>
                    <PaddingLeft>2pt</PaddingLeft>
                    <PaddingRight>2pt</PaddingRight>
                    <PaddingTop>2pt</PaddingTop>
                    <PaddingBottom>2pt</PaddingBottom>
                  </Style>
                </Textbox>
              </CellContents>
            </TablixCell>
           </TablixRow>
      </TablixRows>
    </TablixBody>
   </Tablix>
</ReportItems>
</Body>
</Report>

0 个答案:

没有答案