strange behaviour

S

sunilpatel

D$ = FORMAT(Date, "dd-mmm-yy") & Chr$(10)

this statement worked fine in one workbook but now does not work. "wrong
number of arguments or invalid property error is returned"
The word Format is highlighted and stays in capitals. In another workbook
Script editor accepts the "FORMAT" and it becomes "Format", and works fine.

This occured after i changed a cells date format on a particular worksheet.

Is this a bug ?
 
S

smartin

sunilpatel said:
D$ = FORMAT(Date, "dd-mmm-yy") & Chr$(10)

this statement worked fine in one workbook but now does not work. "wrong
number of arguments or invalid property error is returned"
The word Format is highlighted and stays in capitals. In another workbook
Script editor accepts the "FORMAT" and it becomes "Format", and works fine.

This occured after i changed a cells date format on a particular worksheet.

Is this a bug ?

A guess... DATE is a reserved word (a function). Suggest you change the
name of this variable.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top