Fun Stuff – Dynamics Xmas Greeting

H!

I wish you all a Merry Christmas!

In the spirit of the upcoming holidays I have been playing around with Dynamics Navision.
The result was a Dynamics Xmas Greeting 🙂


Source code for the Dynamics Xmas Greeting:

OBJECT Form 60002 DynamicsXmas
{
  OBJECT-PROPERTIES
  {
    Date=15-12-09;
    Time=00:06:15;
    Modified=Yes;
    Version List=;
  }
  PROPERTIES
  {
    Width=15070;
    Height=9350;
    BackColor=16777215;
    TimerInterval=10;
    OnOpenForm=BEGIN

                 timeNo := 0;
               END;

    OnTimer=BEGIN

              IF (CurrForm.XPOS-10000) > CurrForm.santapic.XPOS THEN
                CurrForm.santapic.XPOS := CurrForm.XPOS + CurrForm.WIDTH
              ELSE
                CurrForm.santapic.XPOS := CurrForm.santapic.XPOS - 100;

              JingleBells(timeNo);
              timeNo += 1;
            END;

  }
  CONTROLS
  {
    { 1000000000;Label  ;3080 ;330  ;8800 ;2420 ;HorzAlign=General;
                                                 ForeColor=255;
                                                 FontName=Freehand521 BT;
                                                 FontSize=30;
                                                 FontBold=Yes;
                                                 LeaderDots=No;
                                                 CaptionML=DAN=Merry Christmas }
    { 1000000003;TextBox;3190 ;2970 ;8470 ;770  ;Name=song;
                                                 Focusable=No;
                                                 HorzAlign=Left;
                                                 VertAlign=Top;
                                                 BackTransparent=Yes;
                                                 Border=No;
                                                 FontSize=12;
                                                 FontBold=Yes;
                                                 MultiLine=Yes;
                                                 SourceExpr=SongText }
    { 1000000004;TextBox;3190 ;3850 ;8470 ;660  ;Name=song1;
                                                 Focusable=No;
                                                 HorzAlign=Left;
                                                 VertAlign=Top;
                                                 ForeColor=0;
                                                 BackTransparent=Yes;
                                                 Border=No;
                                                 FontSize=12;
                                                 FontBold=Yes;
                                                 MultiLine=Yes;
                                                 SourceExpr=SongText1 }
    { 1000000002;Image  ;9790 ;4730 ;4840 ;4400 ;Name=santapic;
                                                 Bitmap=c:\work\santa081.bmp }
    { 1000000001;Image  ;11770;330  ;3080 ;4400 ;Bitmap=c:\work\Christmastree2.bmp }
    { 1000000005;Image  ;0    ;330  ;3080 ;4400 ;Bitmap=c:\work\Christmastree2.bmp }
  }
  CODE
  {
    VAR
      SongText@1000000000 : Text[1024];
      SongText1@1000000002 : Text[1024];
      timeNo@1000000003 : Integer;

    PROCEDURE JingleBells@1000000019(no@1000000000 : Integer);
    BEGIN

      CASE no OF
        1: BEGIN
              SongText := 'Jingle Bells, Jingle Bells';
              SongText1 := 'Jingle all the way!';
              CurrForm.song.UPDATE;
              CurrForm.song1.UPDATE;

              BEEP(659,250);
            END;
        2:  BEEP(659,250);
        3:  BEEP(659,500);
        4:  BEEP(659,250);
        5:  BEEP(659,250);
        6:  BEEP(659,500);
        7:  BEEP(659,250);
        8:  BEEP(783,250);
        9:  BEEP(523,375);
        10: BEEP(587,125);
        11: BEEP(659,1000);
        12: BEGIN
              SongText := 'Oh what fun it is to ride';
              SongText1 := 'In a one horse open sleigh! Hey';
              CurrForm.song.UPDATE;
              CurrForm.song1.UPDATE;

              BEEP(698,250);
            END;
        13: BEEP(698,250);
        14: BEEP(698,375);
        15: BEEP(698,125);
        16: BEEP(698,250);
        17: BEEP(659,250);
        18: BEEP(659,250);
        19: BEEP(659,250);
        20: BEEP(659,250);
        21: BEEP(587,250);
        22: BEEP(587,250);
        23: BEEP(659,250);
        24: BEEP(587,500);
        25: BEEP(783,500);
        26: BEGIN
              SongText := 'Jingle Bells, Jingle Bells';
              SongText1 := 'Jingle all the way!';
              CurrForm.song.UPDATE;
              CurrForm.song1.UPDATE;

              BEEP(659,250);
            END;
        27: BEEP(659,250);
        28: BEEP(659,500);
        29: BEEP(659,250);
        30: BEEP(659,250);
        31: BEEP(659,500);
        32: BEEP(659,250);
        33: BEEP(783,250);
        34: BEEP(523,375);
        35: BEEP(587,125);
        36: BEEP(659,1000);
        37: BEGIN
              SongText := 'Oh what fun it is to ride';
              SongText1 := 'In a one horse open sleigh!';
              CurrForm.song.UPDATE;
              CurrForm.song1.UPDATE;

              BEEP(698,250);
            END;
        38: BEEP(698,250);
        39: BEEP(698,375);
        40: BEEP(698,125);
        41: BEEP(698,250);
        42: BEEP(659,250);
        43: BEEP(659,250);
        44: BEEP(659,250);
        45: BEEP(783,250);
        46: BEEP(783,250);
        47: BEEP(698,250);
        48: BEEP(587,250);
        49: BEEP(523,1000);
      END;
    END;

    BEGIN
    END.
  }
}

.

4 Comments

  1. Top marks. I was going to do something like this but you beat me to it 🙂 Bah! Humbug!

    p.s. Don’t listen to Jesper 🙂

  2. En julenørd 🙂 Pas på drenge….
    .. en dag tager Bylle & Strudsen revance

    God Jul… måske med lidt sne på 🙂

Leave a Reply

Your email address will not be published.


*


This site uses Akismet to reduce spam. Learn how your comment data is processed.