How to set a date from datetimepicker?


#1

when I set a date from a datetimepicker, UiPath have error.
the logmessage as fellow:
The workflow has validation errors. Review and resolve them first.

System.Activities.InvalidWorkflowException: The workflow has validation errors. Review and resolve them first. —> System.Activities.InvalidWorkflowException: The following errors were encountered while processing the workflow tree:
‘DynamicActivity’: The private implementation of activity ‘1: DynamicActivity’ has the following validation error: Compiler error(s) encountered processing expression “13”.
Option Strict On 不允许从“Integer”到“String”的隐式转换。

‘DynamicActivity’: The private implementation of activity ‘1: DynamicActivity’ has the following validation error: Compiler error(s) encountered processing expression “7”.
Option Strict On 不允许从“Integer”到“String”的隐式转换。

‘DynamicActivity’: The private implementation of activity ‘1: DynamicActivity’ has the following validation error: Compiler error(s) encountered processing expression “2016”.
Option Strict On 不允许从“Integer”到“String”的隐式转换。

at System.Activities.Validation.ActivityValidationServices.ThrowIfViolationsExist(IList`1 validationErrors, ExceptionReason reason)
at System.Activities.WorkflowInspectionServices.CacheMetadata(Activity rootActivity, LocationReferenceEnvironment hostEnvironment)
at UiPath.Workflow.ViewModels.MainViewModel.IsWorkflowValid()
— End of inner exception stack trace —


#2

I Think DataTimePicker will work with the help of List Box,
ListBox only support the DataTimePicker,
There is no option for List Box, So our UiPath Will not Support DataTimePicker


#3

@rainman

Hi rain man,
try this "DateTime.tryparseexact(your_date,formats,provider,style,result)"
it returns boolean values whether its true or false


#4

Mr. Ajith,
rainman, is not asking about date and time. he is asking about DateTimePicker Like this…
WeekNumbers


#5

@Poovarasan2
its k Poovarasan … i am just mention the function that is used in date time operations


#6

This error is thrown when the workflow which you are trying to execute has a syntactical error which is displayed in Workflow designer.
Please check all activities and ensure that there is no validation error being shown on any of those[exclamation mark in blue/red]

Share your workflow if possible.