Clear Statement Does Not Work


#1

The clear statement does not seem to work in my procedure.

When I use the command from the menu Field > Morph > Clear Field, then the command works as expected.


#2

I think the documentation needs some clarification. The Clear command only deletes the current cell, which is exactly what it did in Panorama 6. In my test, it did that. Choosing Field > Morph > Clear Field clears every visible cell in the field.

Dave


#3

I think the clear statement does have some other problems. If I have a field and run the clear command it will remove the current field for that record. If I then move up or down a record it blanks that field for that record as well. It continues to do this even if I go to another field and come back again. If I go to a procedure window and then back to the datasheet it no longer exhibits that action.


#4

I thought that was the purpose of the clearcell statement. But the documentation uses a quite similar description for both statements.


#5

Some additional info. I noticed that if you move to another field then that field will also be cleared. It is almost like the clear statement is stuck in the on position and keeps firing in whatever cell it is in. I put a message statement after the clear statement and the message never appeared until I left the datasheet and activated the procedure window.


#6

What do you suggest for clearing a field (column) of data?

My fields are integer numeric, and I tried formulafill zeroblank(0), but that was not completely successful. Some zeros were left in the data sheet.


#7

When I read your first reply, I thought the procedure was moving from record to record, and I tested with this code

Field A Clear DownRecord DownRecord DownREcord

It cleared field A in the first record, but the DownRecord statements never happened.

Dave


#8

For the moment, ClearCell seems to be the only thing working correctly. You could write a loop and step down from record to record until info(“stopped”) and use ClearCell. Your FormulaFill should have worked, and so should

Fill ""

which worked in Panorama 6, but neither do.

Dave