Text(a1, "mmm") in a cell correctly converts the date's month 11 to Nov.
EntryMonth = pm.activesheet.Text(pm.activesheet.Range("LastUpdate").Value, "mmm")
results in...
Object doesn't support this property or method
Have I done wrong or is it not supported?
Text(a1, "mmm") not in Basicmaker
-
- SoftMaker Team
- Posts: 3103
- Joined: Fri Nov 21, 2003 4:57 pm
- Location: Nürnberg, Germany
- Contact:
Re: Text(a1, "mmm") not in Basicmaker
You can't use PlanMaker calculation functions in BasicMaker scripts (you can use them in a cell and read the result from BasicMaker).
What you are looking for is the BasicMaker function "Format".
What you are looking for is the BasicMaker function "Format".
Martin Kotulla
SoftMaker Software GmbH
SoftMaker Software GmbH
Re: Text(a1, "mmm") not in Basicmaker
Thank you for your useful guidance martin-k.
I am actually surprised, in VBA (which I know is not Basicmaker) the following is the full item...
EntryMonth = WorksheetFunction.Text(pm.activesheet.Range("LastUpdate"), "mmm")
which I guess means you do not have the equivalent of "WorksheetFunction".
I am actually surprised, in VBA (which I know is not Basicmaker) the following is the full item...
EntryMonth = WorksheetFunction.Text(pm.activesheet.Range("LastUpdate"), "mmm")
which I guess means you do not have the equivalent of "WorksheetFunction".
Re: Text(a1, "mmm") not in Basicmaker
Whilst I have you, If I may be so bold, may I ask why the following does not work.
a1 is a date and date formatted.
pm.activesheet.Range(a1).Value = pm.activesheet.Range(a1).Value +1
to simply add one day.
a1 is a date and date formatted.
pm.activesheet.Range(a1).Value = pm.activesheet.Range(a1).Value +1
to simply add one day.
-
- SoftMaker Team
- Posts: 3103
- Joined: Fri Nov 21, 2003 4:57 pm
- Location: Nürnberg, Germany
- Contact:
Re: Text(a1, "mmm") not in Basicmaker
You need to put "a1" in quotes. It is a string that represents a cell name.
Martin Kotulla
SoftMaker Software GmbH
SoftMaker Software GmbH
Re: Text(a1, "mmm") not in Basicmaker
I am sorry matin-k I was generalising by using a1 the actual is...
pm.activesheet.Range("LastUpdate").Value = pm.activesheet.Range("LastUpdate").Value + 1
where LastUpdate is A1 named.
edit: what happens is that it changes 26/11/2019 to 26/01/1900
pm.activesheet.Range("LastUpdate").Value = pm.activesheet.Range("LastUpdate").Value + 1
where LastUpdate is A1 named.
edit: what happens is that it changes 26/11/2019 to 26/01/1900