Converting date string into date format
![Post Post](./styles/prosilver/imageset/icon_post_target.gif)
I have astring as this
![Image](https://i.postimg.cc/0jM961MQ/date2.png)
and I wish converte it into a date value
I tried with this function but I not Know how found the mounth
someone can Help me please
![Image](https://i.postimg.cc/0jM961MQ/date2.png)
and I wish converte it into a date value
I tried with this function but I not Know how found the mounth
- Code: Select all Expand view
- Function StringtoDate(dString)
Local dTemp
Local nPos:= At(",",dString)
Local cStringDate:= SubStr(dString,nPos+1)
Local dDay:= SubStr(cStringDate,At(" ",cStringDate)+1,2) //found the day
Local dMounth:= SubStr(cStringDate,At(dDay,cStringDate)+2) // found the mouth + year
Local dYear := Right(dMounth, 4) //found the year
? dday
? dMounth
? dYear
* ctod(day
RETURN dTemp
someone can Help me please