Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Making fields as a Variable in Report

Status
Not open for further replies.

Wendz

Programmer
Aug 9, 2000
47
0
0
PH
Visit site
Hi! Thanks for all the generousity of answering my questions. I hope you would not be tired of answering my questions. Can I assign a field to a variable? I tried to use the IIF command in Print When but it does not work. Whats the best way to do it?

Wendz
edbb@lycos.com
 
Hi!

Give more specifics. Its somewhat hard to understand from your question what really you want to do, just because it might have different meaning. For example, tell if you:

- want field in report to display something conditionally
- wnat field in report that displayed only in some cases
- want to have a variable in the report that calculates something using field in the table

etc.





Vlad Grynchyshyn
vgryn@softserve.lviv.ua
The professional level of programmer could be determined by level of stupidity of his/her bugs
 
Hello!

For a more clearer picture of my problem. It runs something like this.

if field1(Gender)==Female
display contents of field2(FemalePref)
else
display contents of field3(MalePref)
endif

How I am gonna implement this on the report. I have tried to implement this but it just display the upper content. What's the best way to do it. Thanks

Wendz
edbb@lycos.com





 
Hi,
I am not sure i understand your problem. IIF always work in Expression of TextBox.

Assign a field to a variable
>> For what?

Print When evaluate expression, not user-defined function.

Maybe the solution is:
- Make 2 objects and place them at the same co-ordinate in the report.
- Use Print When to restrict them to print only one at a time.

Jimmy
P/S: if anything is not clear, plz let me know and Helps nerver hurt

mailto:nhan_tiags@yahoo.com
 
JimmyK is right, just put expression into report textbox:
iif(Gender=='Female', FemalePref, MalePref)





Vlad Grynchyshyn
vgryn@softserve.lviv.ua
The professional level of programmer could be determined by level of stupidity of his/her bugs
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top