Day of the Week - Forum

Forum Navigation
You need to log in to create posts and topics.

Day of the Week

Is there a chance that there is a function or plug-in that would determine the day of the week from a date?

Working on a scheduling program where I would like to show the day of the week with the date.

Try this

 

{NeoBook Function}
Version=5,70
Language=VBScript
Param=[%1]|Text|Fecha:
Param=[%2]|Variable|Variable con el resultado:
{End}
publication.nbSetVar "[%2]", Weekday("[%1]", 1)

Thanks for your answer.

I may need some help.

I have to study using Functions (adding and using)

I will look in help.

Copy and save to a WeekDay file, save it in the functions folder.

Use it with the Call command.
Call "WeekDay" "03/05/2021" "[yourVar]"

 

salu2

Thank you so much. I believe I have it working.

I seem to have avoided functions.

Maybe not so much now.

Hi overthere,

Check your locale settings about language. May be several inconsistences using literals.

By example;  Sábado (Saturday in spanish) could be "Sábado" or "Sabado" (depending on your operating system version)

My 0.01

David de Argentina

@daviddeargentina

With the above code I receive a number. Obviously the number of the day of the week. A series of If/Then actions solves that but is there an alternative to get the name of the day as you seem to be alluding to?

@pauljonestindall

Take a look of:

https://www.w3schools.com/asp/func_weekdayname.asp

Greetings from Buenos Aires

I keep getting a type mismatch.

@pauljonestindall

Try the plugin asDateTime (Andrei Solodyankin)

Command asDTDayOfWeek

iretz has reacted to this post.
iretz

Did realize there was so much active on this question.

I have installed the asDateTime plugin.  But I am a little rusty on use plugins.

Not sure how to use this one.  Not sure what the fields are asking for because of language difference.

Ideas for me?

@cssystems

In the example project, click the "Get Day of the Week by Date" button. The number of the day of the week appears in the text object.

Uploaded files:
  • You need to login to have access to uploads.

Thanks for the help. Now I understand.