good day all..
While I am compiling a vb6 project, the error highlighted this:
format(date,"YYYYMM")
Can anyone help me? Thank u very much..
good day all..
While I am compiling a vb6 project, the error highlighted this:
format(date,"YYYYMM")
Can anyone help me? Thank u very much..
Jump to PostFORMAT is a function, so you have to set some variable equal to it. So, for example:
Dim myVar As String myVar = Format(Date, "YYYYMM")
Should work fine. At least, it did when I ran it. Hope that helps.
Sorry the title is wrong, not "YYYY" but "YYYYMM" and i'm using Windows 7.. Thanx for your help..
you have to compile in this modality
format(now mm/yyyy)
or
label1 = format(now yyyy)
label2 = format(now mm)
label3 = label1 + label2
I that this could be the soluction
good work
FORMAT is a function, so you have to set some variable equal to it. So, for example:
Dim myVar As String
myVar = Format(Date, "YYYYMM")
Should work fine. At least, it did when I ran it. Hope that helps.
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.
You're trying to visit a URL that doesn't currently exist on the web. Most likely, a member posted a link a long time ago to a web page that has since been removed. It's also possible that there was a typo when posting the URL. We redirect you to this notice instead of stripping out the link to preserve the integrity of the post.