DateSLE showing a blank calendar? How is this possible?

Public support forum for peer to peer support with related to the Visual Objects and Vulcan.NET products
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

Any suggestions? It must be local to this persons' new laptop, but it looks OK to me.
Does Willie's calendar rely on any Windows functions to display the dates? The C++ redistributable pack wasn't installed so I was hoping installing that would solve it, but no.

Hi guys,
I use Willie Moore's DateSLE on a couple of forms in my old VO2.7b application - it works perfectly100% and has done for many years on many different systems, OS and users, and I love it.

Today I have one user suffering from a blank calendar when they open the date field (i.e. click on the calendar icon)
There are no "days" showing in the grid when the box opens, and the user can't click on any of the empty areas. (I had a look using teamviewer)

Their IT guy synchronised this PC's date/time for them just before they noticed this problem, so I suspect it is related, but no idea why.
I have not seen this happen in 20 years of using that control. (I am using the Jan 2001 version.)

The user is on a new laptop, Win 10, nothing special, and it was working fine for the last few days before the date / time synchronisation that their IT guy did

Any ideas why the calendar is suddenly blank? it's got to be a Windows thing...

Thanks, Jonathan
Attachments
DateSLEBlank.JPG
DateSLEBlank.JPG (15.78 KiB) Viewed 837 times
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

Hi all... Any wild suggestions I could try? It is obviously local to this persons' new laptop.
Does Willie's calendar rely on any Windows functions to display the dates? The C++ redistributable pack wasn't installed so I was hoping installing that would solve it, but it didn't help - is there anything else the calendar display might require?.
Jamal
Posts: 315
Joined: Mon Jul 03, 2017 7:02 pm

DateSLE showing a blank calendar? How is this possible?

Post by Jamal »

Hi Johathan,

Does the included example which is in the DateSLE aef work on your client's machine?

Create a small sample reproducible program and post here and include all required code.

What's your programming environment?
What is clients environment, graphics card, type of monitor and resolution?

Jamal
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

Thanks Jamal,

I am using Visual Objects (Version 2.7. Build 2.2735), Version 2.7b
The client is using a new Lenovo laptop, Win 10 Pro, build 19044.1826, with a dock that runs 2 external monitors

Graphics card Internal - Intel Iris Xe Graphics, External Trigger 6 external graphics
Monitor PHL 272V8, 1920 x 1080, 50hz
User reports that the calendar malfunctions on both the external monitors and when she tested it with the laptop screen open and the Trigger 6 disconnected.
Intel 11 Gen, I5 1135G7 @ 2.40GHz, 64bit
16GB Ram

I created a standard VO 2.7b application with only the RightSLE library as suggested and runs fine everywhere except on the clients' laptop.
Good news is that it threw an error this time on her laptop, but runs perfectly on all the other PC's, so there is a clue now, although it didn't help me solve it as the line number reported in the error is not right.

So, does the below give any useful clues?

***********************ERROR********************************
Visual Objects (Version 2.7. Build 2.2735), Version 2.7b
29/07/2022 04:21:08 pm
Application: H:Application.EXE

Error message:
--------------
Error Code: 4 [ NUMERIC OVERFLOW ]
Subsystem: VO-CODE
CallStack:
PECALENDAR:CASTDATE2COLUMN (Line: 3)
PECALENDAR:DRAWDAYS (Line: 113)
PECALENDAR:EXPOSE (Line: 13)
PECALENDAR:DISPATCH (Line: 61)
RIGHTSLE:SHOWCALENDAR (Line: 41)

Error Object created:
--------------------
SubSystem :VO-CODE
SubCode :0
GenCode :Numeric overflow
OsCode :0
ArgType :NIL
FuncPtr :0x00000000
ArgNum :0
FuncSym :
Severity :2
CanDefault :.T.
CanRetry :.F.
CanSubstitute :.F.
Operation :
Description :
FileName :
Tries :0
FileHandle :0
SubCodeText :
Arg :
ArgTypeReq :NIL
MaxSize :0
SubstituteType :NIL
CallFuncSym :
--------------------

I've attached the test AEF and the version of RightSLE I'm using.

Thanks!
Jonathan
Attachments

[The extension aef has been deactivated and can no longer be displayed.]

[The extension aef has been deactivated and can no longer be displayed.]

User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

DateSLE showing a blank calendar? How is this possible?

Post by Chris »

Hi Jonathan,

Most likely this is caused by a setting in the Regional Settings of this PC that isn't expected by the code in the calendar (and is different to the setting in all other PCs). My bet is that it's the "First day of the week" setting, which must be different (Settings->Time & Language->Region->First day of week setting in Windows 10).

So you cat either tell them to adjust this setting, or debug the problem in the code and fix it. I see this code in the CastDate2Column() method:

nReturnVal := INT(_CAST,(DoW(dDate) - ( SELF:dwFirstDayoftheWeek -1 )))

I would make the app show some output before it executes this line and show the values of DoW(dDate) and SELF:dwFirstDayoftheWeek. Maybe for some reason DoW(dDate) returns zero?

.
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

Thank you very much.
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

The issue was exactly as Chris suggested - First Day of Week was set to Wednesday so it is now corrected and working nicely.
Thank you for taking a look!
User avatar
TimothyS
Posts: 62
Joined: Thu Dec 15, 2016 3:39 pm
Location: Australia

DateSLE showing a blank calendar? How is this possible?

Post by TimothyS »

Hi Jonathan,
An interesting problem and thanks for posting it. Haven't run into it yet, but having the answer sure beats all the depression and anxiety involved when something like this happens out of the blue.
It is wonderful having the wisdom of Chris in moments like this.

Regards,
Tim
jonhn
Posts: 86
Joined: Thu Feb 01, 2018 8:04 am
Location: New Zealand

DateSLE showing a blank calendar? How is this possible?

Post by jonhn »

Yep! There is a team of extremely clever people behind X# and among the other contributors involved here- it is humbling when they freely share their knowledge and help out on such mundane queries. in this (rare) case it wasn't something I had screwed up! haha.
I for one am very grateful, and hope to be able to buy them a beer in person sometime.
Jamal
Posts: 315
Joined: Mon Jul 03, 2017 7:02 pm

DateSLE showing a blank calendar? How is this possible?

Post by Jamal »

Johnathan,

I am glad Chris was able to point you to the solution based on the sample you posted.

Jamal
Post Reply