• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Datagrid rowCount property not being set at run time

Guest
Jun 20, 2011 Jun 20, 2011

Copy link to clipboard

Copied

My app shows  a datagrid on a print form that should only display the number of rows for which there are elements in the data provider.

I'm trying to set the rowCount property equal to the length of the data provider collection.

        formPrintView.dgPrtRecIngr.rowCount = dgIngrData.length
        trace("dgIngrData.length: " +dgIngrData.length + "   formPrintView.dgPrtRecIngr.rowCount: " + formPrintView.dgPrtRecIngr.rowCount)

        Trace output in the dbg console:

       dgIngrData.length: 7   formPrintView.dgPrtRecIngr.rowCount: 7

The trace is showing both ...rowCount and ...length to be 7 but the number of displayed rows in the print form is 10 which means that three

empty rows are displayed thus wasting space on the form.

I'm also setting the rowHeight based on a calculation derive from the number of elements in the  data provider -  could this be the problem?

Views

655

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Jun 21, 2011 Jun 21, 2011

Copy link to clipboard

Copied

You'll probably get better answers for this question over at the Flex General Discussions forum.

This forum is mostly visited by Flash Builder folks, whereas the other one has a lot of Flex SDK specific visitors.

-Anirudh

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jun 21, 2011 Jun 21, 2011

Copy link to clipboard

Copied

LATEST

Thanks for the tip Anirudh

I thought that forum was only for Flex 3

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines