Back

If your email is not recognized and you believe it should be, please contact us.

  • You must be logged in to reply to this topic.Login

How to add character styles to 2012 day by day calendar script

Return to Member Forum

  • Author
    Posts
    • #61063
      stormcp
      Member

      I need help with this script please;

      var days = [ “Saturday”, “Sunday”, “Monday”, “Tuesday”, “Wednesday”, “Thursday”, Friday ];
      var months = [ “January”, “February”, “March”, “April”, “May”, “June”, “July”, “August”, “September”, “October”, “November”, December ];
      var length = [ 31, 30, 31, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31 ];
      count = 0;
      day = 0;
      month = 0;
      weekday = 3;
      str = “”;
      while (count < 365)
      {
      count++;
      str += days[weekday]+”, “+months[month]+”, “+(day+1)+”r”;
      day++;
      if (day >= length[month])
      {
      day = 0;
      month++;
      if (month > 11)
      month = 0;
      }
      weekday = (weekday+1) % 7;
      }
      app.selection[0].contents = str;0000000000000000000000000000

      And I need to edit this so I can add character styles as per the image attached. The fonts i want to use is Din regular 10pt for the day and month and Din Bold 26pt for the date. The day is grey, month is black and the date is red.

      I have got an image but are not sure how to upload it here.

      I also need to combine Saturday and Sunday into one page so it reads as Sat/Sun.

      I'm new to adding scripts to InDesign so any help is welcome. I have a deadline for this Friday to have my first draft completed.

      Thanks

      Richard

Viewing 0 reply threads
  • You must be logged in to reply to this topic.
Forum Ads