FIX: When a report detail band starts on a new page, only the first detail record for this band is printed in Visual FoxPro 9.0 (897575)



The information in this article applies to:

  • Microsoft Visual FoxPro 9.0 Professional Edition

SYMPTOMS

Consider the following scenario. In Microsoft Visual FoxPro 9.0, you either preview or print a report that contains multiple detail bands. When a report detail band starts on a new page, only the first detail record for this band is printed. The remaining detail records are omitted from the report output.

This problem occurs when a report detail band starts on a new page because of overflow or because this band is configured to start on a new page.

RESOLUTION

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Visual FoxPro 9.0 service pack that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date         Time   Version     Size       File name
   --------------------------------------------------------
   26-Apr-2005  21:26  9.0.0.2826  5,758,976  Vfp9.exe         
   26-Apr-2005  21:30  9.0.0.2826  1,744,896  Vfp9chs.dll      
   26-Apr-2005  21:30  9.0.0.2826  1,744,896  Vfp9cht.dll      
   26-Apr-2005  19:50  9.0.0.2826  1,744,896  Vfp9enu.dll      
   26-Apr-2005  21:31  9.0.0.2826  1,744,896  Vfp9kor.dll      
   26-Apr-2005  21:27  9.0.0.2826  4,714,496  Vfp9r.dll        
   26-Apr-2005  21:34  9.0.0.2826  1,429,504  Vfp9rchs.dll     
   28-Apr-2005  16:46                315,392  Vfp9rchs.msm
   26-Apr-2005  21:34  9.0.0.2826  1,429,504  Vfp9rcht.dll     
   28-Apr-2005  16:46                317,440  Vfp9rcht.msm
   26-Apr-2005  21:34  9.0.0.2826  1,437,696  Vfp9rcsy.dll     
   28-Apr-2005  16:46                324,096  Vfp9rcsy.msm
   26-Apr-2005  21:34  9.0.0.2826  1,466,368  Vfp9rdeu.dll     
   28-Apr-2005  16:46                325,120  Vfp9rdeu.msm
   26-Apr-2005  20:04  9.0.0.2826  1,429,504  Vfp9renu.dll     
   26-Apr-2005  21:34  9.0.0.2826  1,466,368  Vfp9resn.dll     
   28-Apr-2005  16:46                322,048  Vfp9resn.msm
   26-Apr-2005  21:34  9.0.0.2826  1,466,368  Vfp9rfra.dll     
   28-Apr-2005  16:46                322,560  Vfp9rfra.msm
   26-Apr-2005  21:34  9.0.0.2826  1,429,504  Vfp9rkor.dll     
   28-Apr-2005  16:46                316,416  Vfp9rkor.msm
   26-Apr-2005  21:34  9.0.0.2826  1,449,984  Vfp9rrus.dll     
   28-Apr-2005  16:46                326,656  Vfp9rrus.msm
   02-May-2005  21:14              4,599,808  Vfp9runtime.msm
   26-Apr-2005  21:28  9.0.0.2826  3,878,912  Vfp9t.dll

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

MORE INFORMATION

For more information, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates

Steps to reproduce the problem

  1. Run the following code from a program (.prg) file.
    #define DBCNAME 	'testdb'
    #define TABNAME 	'testtab'
    #define TABCOUNT   	3
    
    
    clear 	
    close data all
    erase testdb.dbc
    erase testdb.dc?
    
    CREATE DATABASE DBCNAME
    
    for lni = 1 to TABCOUNT
    	erase (TABNAME+alltr(str(lni)))+'.dbf'
    	erase (TABNAME+alltr(str(lni)))+'.cdx'
    	if lni = 1
    		CREATE TABLE (TABNAME+alltr(str(lni))) (F1 C(10) NOT NULL PRIMARY KEY, ;
    	       F2 C(10) NOT NULL)
           
    	    for lnj = 1 to 3
    			insert into (Alias()) (f1, f2) values ('Number '+alltr(str(lnj)),'Parent '+alltr(str(lnj)))
    		endfor  
    	else 
    		CREATE TABLE (TABNAME+alltr(str(lni))) (F1 C(10) NOT NULL,  ;
    			F2 C(10),  foreign key f2 tag f2 references (TABNAME+'1'), f3 c(10) )
    	       
    	    for lnj = 1 to 3
    	    	 for lnk = 1 to 3
    				insert into (Alias()) (f1, f2, f3) values ;
    					('Child '+alltr(str(lnk)),'Number '+alltr(str(lnj)), Alias())
    			endfor  
    		endfor  
    	endif
    endfor
    close databases all 
    create report testxx.frx nowait
    return 
  2. In the Report Designer, add the testtab1 table, the testtab2 table, and the testtab3 table to the Data Environment window.
  3. On the Report menu, click Optional Bands.
  4. On the Optional Bands tab of the Report Properties dialog box, click Add one time to add an additional detail band.
  5. Click the Data Grouping tab, and then click Add. The Expression Builder dialog box opens.
  6. In Expression, type testtab1.f1.
  7. Click OK to close the Expression Builder dialog box, and then click OK to close the Report Properties dialog box.
  8. Increase the height of the Group Header 1 band to make the band tall enough to contain a textbox object.
  9. Drag the testtab1.f1 field and the testtab1.f2 field from the Data Environment window to the Group Header 1 band.
  10. Drag the testtab2.f2 field and the testtab2.f3 field from the Data Environment window to the Detail 1 band.
  11. Increase the height of the Detail 2 band to make the band tall enough to contain a textbox object.
  12. Drag the testtab3.f2 field and the testtab3.f3 field from the Data Environment window to the Detail 2 band.
  13. Double-click the Detail 1 band. In Target alias expression, type "testtab2", and then click OK.

    Note The quotation marks around the table name are required.
  14. Double-click the Detail 2 band, and then click to select the Start on new page check box. In Target alias expression, type "testtab3", and then click OK.
  15. Preview the report.
  16. To move to the second page, click the Next Page button on the Print Preview toolbar.

    Note One record from the testtab3 table appears at the top of the second page. You expect three records from the testtab3 table to appear at the top of the second page.

Modification Type:MinorLast Reviewed:7/25/2006
Keywords:kbReportWriter kbQFE kbpubtypekc KB897575 kbAudDeveloper