 |
|
|
| View previous topic :: View next topic |
| Author |
Message |
Babe Ruth
Joined: 18 Apr 2008 Posts: 6
|
Posted: Thu Jun 05, 2008 11:23 am Post subject: Using Validator |
|
|
I am trying to make a date format validation in which the a value of the cell must be in (mm/dd/yyyy). If a cell will be typed for example (abcdeef), it will not be printed in the cell. There will prompt a message that it is not the correct format.
I used this code
$row_count = 7;
$valformula =& $workbook->addValidator();
$valformula->allowBlank('true');
$valformula->setFormula1('(CONCATENATE(MID($row_count,1,2),"/",MID($row_count,4,2),"/",MID($row_count,7,4)))');
$valformula->setError('Invalid Date Format','Please fill correct format (mm/dd/yyyy)','true');
$worksheet->setValidation($row_count,1,$row_count,1,$valformula);
There is an operation time-out when I run it. How will I used the Spreadsheet_Excel_Writer_Validator. How will I use correctly the fomula for validation. I cannot see any documentation or samples regarding the usage of Validator |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|