Silica Calendar - Incorrect

Monday, March 28, 2005 by Stephen Penrose | Discussion: DesktopX

The calendar appears to be programmed incorrectly - Monday 28th March (today) is definitely not a Saturday as the calendar shows - I think the wrong year has been put in - don't know how else to report the problem.
First Previous Page 1 of 2 Next Last
JavaScout
Reply #1 Tuesday, March 29, 2005 1:05 AM
Chaging line 133 in the dateMotnhText script fixed it for me

Was
ulFirstDay = DatePart("w", pFirstDay, 0)

Changed to
ulFirstDay = DatePart("w", pFirstDay, 7)

0 uses the NLS setting whereas I think the scripts assumes Saturday (7)

Hope this helps
Stephen Penrose
Reply #2 Tuesday, March 29, 2005 5:10 PM
Many thanks for the advice but how the hell to I get at the dateMonthText script I need to edit. I've tried everything I can think of - I've found a script file with the line you mention (but no 136) - every time I change it and save, it eventually reverts back to previous when I try to use the widget again. 1.5 hrs spent so far - please help.
JavaScout
Reply #3 Tuesday, March 29, 2005 5:39 PM
You have to open DesktopX builder.
Import the widget.
List objects.
Click on the dateMontText object.
Edit script.
Close script window
Save.
Test.
If it is fixed you then need to export Calendar object as a widget.
You can then run this widget from your end-user DesktopX.
lilstarfish
Reply #4 Tuesday, March 29, 2005 6:30 PM
Finally someone who know something! w00t!

Hi JavaScout!

You say "List objects".

??

Where and how do I do that?

DX is so userunfriendly that I'm sitting crying in the corner here =~(

Stephen, it's the days at the top that are at fault.
They start with Saturday when they should start with Sunday.
If the weeks start with Sunday the dates will be correct.

I've reported this error earlier but no one has cared to answer.
Hopefully JavaScout can help out
lilstarfish
Reply #5 Tuesday, March 29, 2005 7:08 PM
Stephen!

I've found a way to get to that script.

Updated!

Here's how...

1. Start DesktopX

2. Press "Create" to start the Builder

3. In the popup window press the Desktop tab.

4. Under "Objects" click the "Import.." Button

5. In the popup window that appears select the Widgets radiobox

6. Scroll down to the Silica Calendar widget and double click it.

7. With the calendar showing on the desktop press the "List" button
in the DesktopX Builder window.

8. In the new popup window called "Object Navigator" you will
find the dateMontText object.

9. Well, I've tried to edit the script but it won't stay saved with the widget
when you close the widget, no matter what I do =\

But there you go, that's how you find the scripts.

Hopefully JavaScout can help with the rest
JavaScout
Reply #6 Tuesday, March 29, 2005 10:16 PM
Good step by step instructions lilstarfish.

Once you have edited the script close the script window down (File/Exit) then press apply on the dateMonthText - Properties. Then click ok.
You should now have a corrected calendar.

If everything is ok go back to the Object Navigator window whichstill should be up.
Select the cal_back object id from the list.
Right click and select export.

In the dialog box that come up make sure Export as widget(exe) is selected and that
Selected and Related is checked.

Click next.
File in the entries and click next again.
Set the file name of the widget (Something like MyCalendar.exe)
Click Finished.

You should get a confirmation dialog that the exe was created.

Close the Object Navigator Window.

Unload Desktop X builder by right clicking on the Sytray entry and choosing unload.
Start Desktop X up.
If you have the calendar still in Desktop X remove it by right clicking the object and selecting remove.
Open the DesktopX panel (You should get some icons for Widgets/Objects/Settings etc)
Click on widgets and select your widget (MyCalendar.exe)
You should now be running your corrected calendar widget.
Stephen Penrose
Reply #7 Wednesday, March 30, 2005 3:05 AM
Many thanks to both of you - I have done as instructed and all looks good at first sight - UNFORTUNATELY - the months following and preceeding do not follow on correctly i.e. last day of May is THURSDAY 31st (which is correct) but April seems to then start on WEDNESDAY 1st! Do both of yours do this or is it just a problem at my end?
lilstarfish
Reply #8 Wednesday, March 30, 2005 7:14 AM
Many thanks JavaScout for your kindness!

The calendar now shows the correct information here!

Stephen:

Did you make sure you checked the radio button named "Selected and Related",
when exporting the new calendar?

Also, after making the new widget you need to make sure that
the old calendar is not loaded when DesktopX starts.

So as JavaScout suggests;

1. Unload Desktop X builder by right clicking on the Sytray entry and choosing unload.

2. Start Desktop X up.

3. In the DesktopX Welcome screen select Load Widgets

4. In the DesktopX Widget popup window, check that
there is no calendar listed in the "Loaded Widgets" area.
(if there is, just select the calendar and press the "Unload" button)

5. Now, just press the "Load Widgets..." button and navigate
to your previously exported and newly named calendar widget.

That should be it! =D

Let us know how it goes

Big thanks again to JavaScout for helping out and for doing
so in a way that was easy to follow, you rock! =D
Stephen Penrose
Reply #9 Wednesday, March 30, 2005 4:44 PM
Lilstarfish & JavaScout - thank you both for all the time effort and advice you've put in. I've tried uninstalling and re-installing Desktop X which downloaded me a fresh copy of the calendar - even on the 'new' copy the following month starts 2 days early even before I've made any changes so I guess it might be something to do with UK windows config. I've tried trailing through the script and experimented with my best guesses but nothing seems to help so unless JavaScout or someone who understands the inner meanings of these scripts can help I'll have to use another calendar - shame
JavaScout
Reply #10 Wednesday, March 30, 2005 5:17 PM
I will take a look at it when I get home in a couple of hours.
Hang in there.

lilstarfish
Reply #11 Wednesday, March 30, 2005 5:26 PM
Hi Stephen and JavaScout!

The easiest thing would, in my lil mind, be to change
the days order. So it will start with Sunday instead of Saturday.

That is the order in the originating calendar widget, "Core Calendar.exe",
so I believe that changing the day order back to that things will make
the Silica Calendar work correctly.

I have no idea how to go about that kinda feat, so I guess
that JavaScout is the only one who can help out with that.
JavaScout
Reply #12 Wednesday, March 30, 2005 7:54 PM
You are right lilstarfish. The problem is actually with the titles. (dateDay1 through dateDay7)

dateDay7 is actually positioned to be first instead of last.

Making the changes is not hard just a little involved.

Basically you have to reposition dateDay1 through dateDay7.

I will try re-doing the steps and write them down but that will have to be later.
JavaScout
Reply #13 Wednesday, March 30, 2005 7:58 PM
You are right lilstarfish. The problem is actually with the titles. (dateDay1 through dateDay7)

dateDay7 is actually positioned to be first instead of last.

Making the changes is not hard just a little involved.

Basically you have to reposition dateDay1 through dateDay7.

I will try re-doing the steps and write them down but that will have to be later.
_Martin_
Reply #14 Thursday, March 31, 2005 2:29 AM
Guys - why not look at my calendar (http://martin.wincustomize.com/viewskin.aspx?skinid=131&libid=34&comments=1&SID=37)

I think the Silica Calendar was based on this but missed some items. See if mine works and then look at copying the differences.
laurentfr
Reply #15 Saturday, April 2, 2005 4:29 PM
both Core calendar and Silica calendar are wrong.

Martin's Calendar are ok.
lilstarfish
Reply #16 Saturday, April 2, 2005 10:49 PM
What's the problem with Core Calendar?
Skryme
Reply #17 Sunday, April 3, 2005 1:42 AM
It`s same problem as Silica cal!But can you advise how to change first day of week?It is now Sun,but I like to use Mon!
lilstarfish
Reply #18 Sunday, April 3, 2005 9:37 AM
Hmm...this is strange...now Core Calendar doesn't work at all here.

Before it worked ok though, correct dates and days.
Then it started but was stuck on september 2000 I believe, couldn't see the year.
But now it won't even start. I've shut down the ghost version it creates a couple of times with Windows Task Manager but it won't start at all.

I even uninstalled DesktopX and reinstalled it but no go...

Very strange..


Update:

I imported the Core Calendar widget into builder and exported it as a new Core Calendar.

Now that copy works.
I wonder why the original widget suddenly wouldn't work.
laurentfr
Reply #19 Sunday, April 3, 2005 12:34 PM
tried this trick.

not working any better.
JavaScout
Reply #20 Tuesday, April 5, 2005 9:12 PM
Ok.

Here are the fixes to the calendars.

For silica Calendar.
The only problem with the silica calendar is that the dateDay1 through dateDay7 are in the wrong positions.
This is causing the day to be incorrect.

Instructions.
Start Desktopx builder
Import the Silica Calendar
From the systray right click on the desktop x builder and click on List Objects
Click on the Object ID column to sort by object id.
Scroll down to the dateDay1 object.
Click on the object and bring up the properties.
Chnage to the summary screen.
Change the alignment on the first alignment button to Align right.
Click ok.
Go Back at the List Objects
Scroll down to the dateDay7 object.
Click on the object and bring up the properties.
Chnage to the summary screen.
Change the alignment on the first alignment button to center.
Click ok.
Go back to the object list and change the X value of the following objects
dateDay1 - 20
dateDay2 - 33
dateDay3 - 52
dateDay4 - 72
dateDay5 - 92
dateDay6 - 111
dateDay7 - 129

Check the calendar to make sure it is working correctly.
Once it is you can go ahead and export the widget.


For the core calendar.
The only problem with this calendar is if you have international setting where the first day of the week is not a Sunday.
There are two possible fixes.
One is to change line 132 on the dateMonthText script as follows which will ignore the NLS and always start the week on a sunday
ulFirstDay = DatePart("w", pFirstDay, 1)

The other solution is to set the week day heading and re-arrange the dateDay1 through 7 obects
The following would be added to the dateMonthText script at the end of the OnEnter function
(line 21)
For ulIndex = 1 To 7
'get the name of the object
szCurObject = "dateDay" & ulIndex

'hide the object if valid
If DesktopX.IsObject(szCurObject) = True Then
DesktopX.Object(szCurObject).text = UCase(Left(WeekdayName(ulIndex,False,0),1)) & mid(WeekdayName(ulIndex,False,0),2,1)
End If
Next

You then would need to re arrange the dateDay1 through 7 ojbects as in the instructions for the silica calendar except with different values of x (You still need to change the align of dayDate1 and dayDate7)

dateDay1 - 27
dateDay2 - 43
dateDay3 - 71
dateDay4 - 96
dateDay5 - 121
dateDay6 - 146
dateDay7 - 170

Hope this helps. Let me know how you get on.


Please login to comment and/or vote for this skin.

Welcome Guest! Please take the time to register with us.
There are many great features available to you once you register, including:

  • Richer content, access to many features that are disabled for guests like commenting on the forums and downloading skins.
  • Access to a great community, with a massive database of many, many areas of interest.
  • Access to contests & subscription offers like exclusive emails.
  • It's simple, and FREE!



web-wc01