SoftMaker.com

English-Language Support
It is currently Sat May 25, 2013 11:43 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Wed Oct 20, 2010 12:56 am 
Offline

Joined: Wed Oct 20, 2010 12:48 am
Posts: 4
Hello,
how can I add some days to a date in basicmaker ?
For example I would like to be able to do
myDate = myDate + 2
but I get a type mismatch error.
I don't see any type conversion operator.
Also, when I do a print VarType(myDate),
I get 7 which is not mentioned in help :
Help mentions:
The possible values are :
Type
Return value

Empty
0

Null
1

Integer
2

Long
3

Single
4

Double
5

String
8


Thanks.


Top
 Profile  
 
PostPosted: Wed Oct 20, 2010 9:04 am 
Offline
SoftMaker Team
SoftMaker Team

Joined: Wed Apr 09, 2008 7:26 am
Posts: 4550
Location: Nuremberg
Hello,

the date has to be converted into a int or double value by using cdbl or clng

sub main
print datevalue(cLng(date) + 2)
end sub

_________________
Sven Leßmann
SoftMaker Software GmbH


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 0 guests


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 post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group