help me pls~~ data report data section does not match data source

Reply

Join Date: Apr 2007
Posts: 1
Reputation: kkh86 is an unknown quantity at this point 
Solved Threads: 0
kkh86 kkh86 is offline Offline
Newbie Poster

help me pls~~ data report data section does not match data source

 
0
  #1
Apr 23rd, 2007
With rptSalesEnquiryChecklist
Set .DataSource = ar
.DataMember = ""

With .Sections("Section7").Controls
For i = 1 To .Count
If TypeOf .Item(i) Is RptTextBox Then

Select Case .Item(i).Name
Case "txtAddress"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Address").Name

Case "txtSupplier_Company_Name"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Supplier_Company_Name").Name

Case "txtSupplier_Name"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Supplier_Name").Name

Case "txtProduct"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Product").Name

Case "txtContact_No"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Contact_No").Name
End Select
End If
Next i
End With
End With

[img] http://i48.photobucket.com/albums/f245/zykhoo/11.jpg [/img]
why my data report will prompt out this msg box? the data report got subreport or not?
Reply With Quote Quick reply to this message  
Join Date: Aug 2007
Posts: 10
Reputation: epok13hart is an unknown quantity at this point 
Solved Threads: 0
epok13hart epok13hart is offline Offline
Newbie Poster

Re: help me pls~~ data report data section does not match data source

 
0
  #2
Aug 12th, 2007
Originally Posted by kkh86 View Post
With rptSalesEnquiryChecklist
Set .DataSource = ar
.DataMember = ""

With .Sections("Section7").Controls
For i = 1 To .Count
If TypeOf .Item(i) Is RptTextBox Then

Select Case .Item(i).Name
Case "txtAddress"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Address").Name

Case "txtSupplier_Company_Name"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Supplier_Company_Name").Name

Case "txtSupplier_Name"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Supplier_Name").Name

Case "txtProduct"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Product").Name

Case "txtContact_No"
.Item(i).DataMember = ""
.Item(i).DataField = ar.Fields("Contact_No").Name
End Select
End If
Next i
End With
End With

[img] http://i48.photobucket.com/albums/f245/zykhoo/11.jpg [/img]
why my data report will prompt out this msg box? the data report got subreport or not?

i think u set ur datasource wrongly
is ar the dataenvironment?
check the file name of your source in the properies of the data report
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. set datareport.datasource= ar
Reply With Quote Quick reply to this message  
Join Date: Nov 2006
Posts: 848
Reputation: QVeen72 is on a distinguished road 
Solved Threads: 120
QVeen72's Avatar
QVeen72 QVeen72 is offline Offline
Practically a Posting Shark

Re: help me pls~~ data report data section does not match data source

 
0
  #3
Aug 13th, 2007
Hi,

Do u have "Section7" yn ur datareport..
If u dont have any Groups and detail section must be "Section1"

Regards
Veena
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Visual Basic 4 / 5 / 6 Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC