Why does report generate this: []!

  • Thread starter Thread starter James A
  • Start date Start date
J

James A

In the past few days a report box in the report has stoped working.
Instead of saying #error it is delivering a box with a exclamation
mark: []!

It is reading the value out of a table which is of type memo.

A few months ago I changed the field from text to memo because 255
text was too small.

I've looked in the table and the value is what it should be, " This
Now Completes your order"

Any ideas ppls ?

Thanks.
 
Do you get the same garbage characters if you open the table directly and
view the record? If so, the database is partially corrupt.

1. Create a copy of the database while Access is not running.

2. Try a repair: Tools | Database Utilities | Compact/Repair

3. If not fixed, create a new (blank) database, and import all objects.
 
Allen Browne said:
Do you get the same garbage characters if you open the table directly and
view the record? If so, the database is partially corrupt.

No, the table is fine. I opened up up and saw the text, "This now
completes your order" - Exactly what it should be, no fields are
corrupt at all.

1. Create a copy of the database while Access is not running.

2. Try a repair: Tools | Database Utilities | Compact/Repair

Option 1 & 2 brought no success :(

3. If not fixed, create a new (blank) database, and import all objects.

Hrm, leaving working right now will try this tomorrow morning.

The database backend is resonably big ~ 20meg will probably take a
while, yes?

Thanks for the help allen.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.
James A said:
In the past few days a report box in the report has stoped working.
Instead of saying #error it is delivering a box with a exclamation
mark: []!

It is reading the value out of a table which is of type memo.

A few months ago I changed the field from text to memo because 255
text was too small.

I've looked in the table and the value is what it should be, " This
Now Completes your order"

Any ideas ppls ?

Thanks.
 
Okay, it the table looks good, concentrate on the report.

Right-click the problem text box, and choose Properties.
What is the Font Name? Not Wingdings or something?

If you can't see anything wrong with the text box, and the opening the
query(?) the report is based on shows the right results, then try gettting
Acess to tell you the value it's putting into that box for each record,
i.e.:
Private Sub Detail_Print()
Debug.Print Me![NameOfThisTextBox]
End Sub
After running the report, check the Immediate window (Ctrl+G) to see if the
data is showing correctly there.

Hopefully this process will help narrow down whether the problem is with the
display of the data, or the retrieval of the data.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

James A said:
"Allen Browne" <[email protected]> wrote in message
Do you get the same garbage characters if you open the table directly and
view the record? If so, the database is partially corrupt.

No, the table is fine. I opened up up and saw the text, "This now
completes your order" - Exactly what it should be, no fields are
corrupt at all.

1. Create a copy of the database while Access is not running.

2. Try a repair: Tools | Database Utilities | Compact/Repair

Option 1 & 2 brought no success :(

3. If not fixed, create a new (blank) database, and import all objects.

Hrm, leaving working right now will try this tomorrow morning.

The database backend is resonably big ~ 20meg will probably take a
while, yes?

Thanks for the help allen.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.
James A said:
In the past few days a report box in the report has stoped working.
Instead of saying #error it is delivering a box with a exclamation
mark: []!

It is reading the value out of a table which is of type memo.

A few months ago I changed the field from text to memo because 255
text was too small.

I've looked in the table and the value is what it should be, " This
Now Completes your order"

Any ideas ppls ?

Thanks.
 
Allen Browne said:
Okay, it the table looks good, concentrate on the report.

Right-click the problem text box, and choose Properties.
What is the Font Name? Not Wingdings or something?

No, it's arial.

If you can't see anything wrong with the text box, and the opening the
query(?) the report is based on shows the right results, then try gettting
Acess to tell you the value it's putting into that box for each record,

I've now opened up the query and here that is where the problem must
be. The query is returning the funny characters []! or [][]

I wrote a way around the problem by getting the report to grab the
note directly from the form. I would however, like to work out why it
happened. No one has touched the query for a long period of time.
i.e.:
Private Sub Detail_Print()
Debug.Print Me![NameOfThisTextBox]
End Sub
After running the report, check the Immediate window (Ctrl+G) to see if the
data is showing correctly there.

Hopefully this process will help narrow down whether the problem is with the
display of the data, or the retrieval of the data.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

James A said:
"Allen Browne" <[email protected]> wrote in message
Do you get the same garbage characters if you open the table directly and
view the record? If so, the database is partially corrupt.

No, the table is fine. I opened up up and saw the text, "This now
completes your order" - Exactly what it should be, no fields are
corrupt at all.

1. Create a copy of the database while Access is not running.

2. Try a repair: Tools | Database Utilities | Compact/Repair

Option 1 & 2 brought no success :(

3. If not fixed, create a new (blank) database, and import all objects.

Hrm, leaving working right now will try this tomorrow morning.

The database backend is resonably big ~ 20meg will probably take a
while, yes?

Thanks for the help allen.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.
In the past few days a report box in the report has stoped working.
Instead of saying #error it is delivering a box with a exclamation
mark: []!

It is reading the value out of a table which is of type memo.

A few months ago I changed the field from text to memo because 255
text was too small.

I've looked in the table and the value is what it should be, " This
Now Completes your order"

Any ideas ppls ?

Thanks.
 
Okay: you have identified the problem is with the data, not the report.

Now you need to discover what the unprintable characters are, so you can fix
the data.

1. Create a query that selects a problem record.

2. Open the Immediate Window (Ctrl+G), and enter:
? DLookup("MyField", "MyQuery")
so that Access dumps the contents of the field into the Immediate
Window.

3. Use Mid() and Asc() to ask Access what the character is. For emample, it
it were the 13th character in the field:
? Asc(Mid(DLookup("MyField", "MyQuery"), 13, 1))

Once you know what the problem characters are, you can use an Update query
to replace them. Use the Replace() function in combination with Left(),
Mid(), and Right() to replace the characters with what you want.

If the data came from elsewhere, you may find these are things like Chr(10).

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

James A said:
"Allen Browne" <[email protected]> wrote in message
Okay, it the table looks good, concentrate on the report.

Right-click the problem text box, and choose Properties.
What is the Font Name? Not Wingdings or something?

No, it's arial.

If you can't see anything wrong with the text box, and the opening the
query(?) the report is based on shows the right results, then try gettting
Acess to tell you the value it's putting into that box for each record,

I've now opened up the query and here that is where the problem must
be. The query is returning the funny characters []! or [][]

I wrote a way around the problem by getting the report to grab the
note directly from the form. I would however, like to work out why it
happened. No one has touched the query for a long period of time.
i.e.:
Private Sub Detail_Print()
Debug.Print Me![NameOfThisTextBox]
End Sub
After running the report, check the Immediate window (Ctrl+G) to see if the
data is showing correctly there.

Hopefully this process will help narrow down whether the problem is with the
display of the data, or the retrieval of the data.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

James A said:
"Allen Browne" <[email protected]> wrote in message
Do you get the same garbage characters if you open the table
directly
and
view the record? If so, the database is partially corrupt.

No, the table is fine. I opened up up and saw the text, "This now
completes your order" - Exactly what it should be, no fields are
corrupt at all.


1. Create a copy of the database while Access is not running.

2. Try a repair: Tools | Database Utilities | Compact/Repair

Option 1 & 2 brought no success :(


3. If not fixed, create a new (blank) database, and import all objects.

Hrm, leaving working right now will try this tomorrow morning.

The database backend is resonably big ~ 20meg will probably take a
while, yes?

Thanks for the help allen.


--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.
In the past few days a report box in the report has stoped working.
Instead of saying #error it is delivering a box with a exclamation
mark: []!

It is reading the value out of a table which is of type memo.

A few months ago I changed the field from text to memo because 255
text was too small.

I've looked in the table and the value is what it should be, " This
Now Completes your order"

Any ideas ppls ?

Thanks.
 
Back
Top