|
-
Aug 10th, 2005, 10:22 PM
#1
Thread Starter
Member
Vb6 with Active report - cannot call other report data field
Below is the coding:
Problem is this sentences: rptAmt2.Fields("Amt3").Value = 0
It cannot identifier rptAmt2 which another report data field.
Can anyone help me, thank you.
Dim rptAmt As New rptFinanceAmt
Dim rptAmt2 As New rptFinanceAmt2
If Fields("Amt3").Value = 0 And rptAmt2.Fields("Amt3").Value = 0 And rptAmt.Fields("Amt3").Value = 0 Then Fields("Amt3").Value = ""
ElseIf Fields("Amt3").Value = 0 And rptAmt2.txtAmt2 = Empty And rptAmt.txtAmt <> Empty Then Fields("Amt3").Value = 0
ElseIf Fields("Amt3").Value = 0 And rptAmt2.txtAmt2 <> Empty And rptAmt.txtAmt = Empty Then Fields("Amt3").Value = 0
ElseIf Fields("Amt3").Value = 0 And rptAmt2.txtAmt2 <> Empty And rptAmt.txtAmt <> Empty Thenb Fields("Amt3").Value = 0
End If
-
Aug 10th, 2005, 11:32 PM
#2
Hyperactive Member
Re: Vb6 with Active report - cannot call other report data field
what the hell does this mean:
"It cannot identifier rptAmt2 which another report data field"
-
Aug 11th, 2005, 07:48 PM
#3
Thread Starter
Member
Re: Vb6 with Active report - cannot call other report data field
 Originally Posted by frigginjerk
what the hell does this mean:
"It cannot identifier rptAmt2 which another report data field"
means that it cannot detect rptAmt2 data field.
-
Aug 11th, 2005, 09:10 PM
#4
Thread Starter
Member
Vb6 with Active report - cannot call other report data field
very hard to find Active report syntax!
anyone can help me how to write the syntax for link to another form or report data field inside text?
thank you
-
Aug 11th, 2005, 09:56 PM
#5
Re: Vb6 with Active report - cannot call other report data field
Don't have AR handy but as far as I can remember each control has its name (just like in VB) so all need to do is call the same way you would in VB (each may have a different properties - Text or Caption or ...):
rptAmt.ActualControlName.Text = "SomeValue"
-
Aug 12th, 2005, 03:31 AM
#6
Hyperactive Member
Re: Vb6 with Active report - cannot call other report data field
In AR Fields and TextBoxes are not the same thing. It's important to realize that unless you added an AR data control to the report the fields will not be created automatically.
in the initialize event of your report try adding the field like this:
Code:
me.Fields.Add "FieldName"
and be sure to type that same "FieldName" into the DataField property of your textbox.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|