Son/Daughter Report

bigbadbess24

Registered User.
Local time
Today, 09:23
Joined
Mar 9, 2006
Messages
83
I am creating a letter in a report for parents. In the report I want it to figure out whether it should say son or daughter. I do have a field for sex (M/F). Is there a way to tell the report to say son or daughter base on the sex field?
 
Unless your M/F field only refers to sons and daughters andnot to parents, then the answer is no. You need to be able to tell who is a son or daughter. Another field with say S for son and D for daughter will do the trick.
 
The Field says Sex, underneath it, it will have either a M or F next to their name. It does not refer to parents. M/F does not refer to anything. Is there an expression where I can write to translate M into Son and F into Female?
 
you could try a query that will transfer M to Son and F to Daughter the expression should look some thing like this:

iff ([Sex] = M,"Son" & iff[Sex]=F,"Daughter")

Not sure if this will work but you could give it a go.

Alastair
 
updated message this worked for me:
Test: IIf([Sex]="M","Son ","") & IIf([Sex]="F","Daughter ","")
 
When I put that Line in expression IIf([Sex]="M","Son ","") & IIf([Sex]="F","Daughter ","") nothing comes up. But should I be putting it up under critiera?
 
Have a look at this simple database and you should see how to set it up at your end.

If you need any more help cry out and i will answer

Alastair
 

Attachments

Another quick question, I want to put that piece in the middle of some text into report. What is the best way to do it?
 
can you give me an example of the text and i will have a look for you.
 
Rich
Iif([Sex]="M","Son ","Daughter")

The Daughter part of the code will that asum that all other letter except "M" are Daughter. Just checking my understanding.
 
Below is the text I want to have. Where it says son/daughter is where I want the "code" to go:

Due to the change in your son/daughter schedule, there is a change in the required textbook(s). Therefore, we request that you go to your textbook supplier with this letter and obtain and/or return the book lsited below. If a course has been added it is essential that you obtain the textbook(s) as soon as possible. Since. without these books your son/daughter academic performance will be severely hindered. Thank you for your attention in this matter.
 
alastair69 said:
Rich
Iif([Sex]="M","Son ","Daughter")

The Daughter part of the code will that asum that all other letter except "M" are Daughter. Just checking my understanding.
There is no other option here, it's just M or F so it can only be one of two conditions, or should be.
 
I belive this is the answer to your current needs, you will find the text under Query1 in the attached database.

Alastair
 

Attachments

Please don't start multiple threads on the same topic.
 
It worked!! You are really good.

But the only problem is when I look at the report it does not display it all. I made sure the box on the report is big enough to hold the text but not all of it is displaying
 

Users who are viewing this thread

Back
Top Bottom