Help, wierd thing happening

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a fairly complicated report, based on a query.

In the query, there is an expression which uses Switch to add words to some
underlying data, depending on what that data is, to produce a field I call
"AltWds".
This is working fine, if I run the query by itself.

In the detail field of the report, I have an unbound textbox with the
Control Source
=IIf([CtDetails]=1,Null,[AltWds])

For some reason, this is returning, for all details, the value it should
have for the first Detail.

I have another unbound textbox in the same field with the control Source
=IIf([CtDetails]=1,Null,[AltDesc])

This is working just fine. The only difference I can see is that the first
is based on an expression in the query while the second is based on
underlying table data. But that shouldn't make a difference, should it? Can
anyone help me out here?

Thanks in advance.
 
Make sure your "unbound textboxes" are not named the same as a field in your
report record source. eg. altwds or altdesc. This can cause Access no end of
confusion.

HTH

Terry
 
Thanks for the suggestion, but that's not it. Any other ideas?

TerryC said:
Make sure your "unbound textboxes" are not named the same as a field in your
report record source. eg. altwds or altdesc. This can cause Access no end of
confusion.

HTH

Terry

r. howell said:
I have a fairly complicated report, based on a query.

In the query, there is an expression which uses Switch to add words to some
underlying data, depending on what that data is, to produce a field I call
"AltWds".
This is working fine, if I run the query by itself.

In the detail field of the report, I have an unbound textbox with the
Control Source
=IIf([CtDetails]=1,Null,[AltWds])

For some reason, this is returning, for all details, the value it should
have for the first Detail.

I have another unbound textbox in the same field with the control Source
=IIf([CtDetails]=1,Null,[AltDesc])

This is working just fine. The only difference I can see is that the first
is based on an expression in the query while the second is based on
underlying table data. But that shouldn't make a difference, should it? Can
anyone help me out here?

Thanks in advance.
 
OK, this hasn't gotten me any farther, but perhaps it will help someone else.
I simplified the code in the text boxes to try to see where the problem is.
If the text box says [AltWds] all is well.
If it says =[AltWds], my problem comes back. Any ideas? Thanks

r. howell said:
Thanks for the suggestion, but that's not it. Any other ideas?

TerryC said:
Make sure your "unbound textboxes" are not named the same as a field in your
report record source. eg. altwds or altdesc. This can cause Access no end of
confusion.

HTH

Terry

r. howell said:
I have a fairly complicated report, based on a query.

In the query, there is an expression which uses Switch to add words to some
underlying data, depending on what that data is, to produce a field I call
"AltWds".
This is working fine, if I run the query by itself.

In the detail field of the report, I have an unbound textbox with the
Control Source
=IIf([CtDetails]=1,Null,[AltWds])

For some reason, this is returning, for all details, the value it should
have for the first Detail.

I have another unbound textbox in the same field with the control Source
=IIf([CtDetails]=1,Null,[AltDesc])

This is working just fine. The only difference I can see is that the first
is based on an expression in the query while the second is based on
underlying table data. But that shouldn't make a difference, should it? Can
anyone help me out here?

Thanks in advance.
 
Sorry about the delay in getting back to you ...... the slave drivers here
have had me working*&?!

A couple of things to check. Is your textbox in the detail section of your
report? Do the other fields in the report section reflect what you expect to
see? And as a double check the query is definitely returning different data
in the [altwrds] than what is displaying on the report?

I am running out of ideas ...... if anyone else has some input .....

Terry


r. howell said:
OK, this hasn't gotten me any farther, but perhaps it will help someone else.
I simplified the code in the text boxes to try to see where the problem is.
If the text box says [AltWds] all is well.
If it says =[AltWds], my problem comes back. Any ideas? Thanks

r. howell said:
Thanks for the suggestion, but that's not it. Any other ideas?

TerryC said:
Make sure your "unbound textboxes" are not named the same as a field in your
report record source. eg. altwds or altdesc. This can cause Access no end of
confusion.

HTH

Terry

:

I have a fairly complicated report, based on a query.

In the query, there is an expression which uses Switch to add words to some
underlying data, depending on what that data is, to produce a field I call
"AltWds".
This is working fine, if I run the query by itself.

In the detail field of the report, I have an unbound textbox with the
Control Source
=IIf([CtDetails]=1,Null,[AltWds])

For some reason, this is returning, for all details, the value it should
have for the first Detail.

I have another unbound textbox in the same field with the control Source
=IIf([CtDetails]=1,Null,[AltDesc])

This is working just fine. The only difference I can see is that the first
is based on an expression in the query while the second is based on
underlying table data. But that shouldn't make a difference, should it? Can
anyone help me out here?

Thanks in advance.
 
Thanks for getting back at all. Unfortunately, it's still a no go. The
textbox is inthe detail section. The box right next door (also in the detail
section) functions perfectly. The underlying query runs fine when it's run
Sorry about the delay in getting back to you ...... the slave drivers here
have had me working*&?!

A couple of things to check. Is your textbox in the detail section of your
report? Do the other fields in the report section reflect what you expect to
see? And as a double check the query is definitely returning different data
in the [altwrds] than what is displaying on the report?

I am running out of ideas ...... if anyone else has some input .....

Terry


r. howell said:
OK, this hasn't gotten me any farther, but perhaps it will help someone else.
I simplified the code in the text boxes to try to see where the problem is.
If the text box says [AltWds] all is well.
If it says =[AltWds], my problem comes back. Any ideas? Thanks

r. howell said:
Thanks for the suggestion, but that's not it. Any other ideas?

:

Make sure your "unbound textboxes" are not named the same as a field in your
report record source. eg. altwds or altdesc. This can cause Access no end of
confusion.

HTH

Terry

:

I have a fairly complicated report, based on a query.

In the query, there is an expression which uses Switch to add words to some
underlying data, depending on what that data is, to produce a field I call
"AltWds".
This is working fine, if I run the query by itself.

In the detail field of the report, I have an unbound textbox with the
Control Source
=IIf([CtDetails]=1,Null,[AltWds])

For some reason, this is returning, for all details, the value it should
have for the first Detail.

I have another unbound textbox in the same field with the control Source
=IIf([CtDetails]=1,Null,[AltDesc])

This is working just fine. The only difference I can see is that the first
is based on an expression in the query while the second is based on
underlying table data. But that shouldn't make a difference, should it? Can
anyone help me out here?

Thanks in advance.
 
Back
Top