Blog

  • My best design thinking is in the shower

    I came up with this idea in the shower, and just realized while in the shower this morning that saving the Entry ID is silly — would work find if this was desktop only or mobile phone only application, but since both can write Tasks in the end, I need to do a search on the subject line.

  • Using ID with Microsoft Objects

    Just a quick note to remind me where this article is.  I’ve been looking at http://support.microsoft.com/kb/293152/ which I think will help me mark my tasks complete.

  • Update on my project

    Didn’t get to spend much time on the project, today.  I got appointments to create on my older Gateway tablet, but couldn’t get them to work on my new Lenovo, which is where I have working on this.  The weird part is that I couldn’t Add an Reference to the Microsoft Office PIAs, but when I transferred the program to the other computer using my network, added the code to create a task, and then moved it back, the PIA reference was there. Weirdness.

     

    I’ve decided to add a "reminder time" to the project, and with a little research found I can use the DateTimePicker to get my time. 

     

    And now I’m fighting with the notebook again.  The district installed Groupwise which is getting into the way.  I am deleting the Groupwise account now, but am probably going to have to uninstall Groupwise.

  • Documentation can be SO irritating!

    I decided I wanted to do the regular Windows to Outlook side of the project first.  It makes sense having both, as I often change my sets in the morning, in front of my desktop computers.

     

    So I wanted to figure out how to create an Outlook item.  I started with this article:

     

    http://support.microsoft.com/kb/313787

     

    Lovely article but I couldn’t get it to compile.  I started doing research on the error message and kept running into references to PIA’s.  I found them, and I had to install them.

     

    http://www.microsoft.com/downloads/thankyou.aspx?familyId=59daebaa-bed4-4282-a28c-b864d8bfa513&displayLang=en

     

    I also found this article which was helpful too:

     

    http://msdn.microsoft.com/en-us/library/bb226711.aspx#officeoutlook2007whatsnewdeveloperspart1__intro

     

    So here is what I had to do to create an Outlook Calendar entry (which does work).

     

    I had to add an reference to the PIAs:

     

    Add a reference to the PIAs. To do this, follow these steps:

    a. On the Project menu, click Add Reference.
    b. Click the NET tab, locate Microsoft.Outlook.Interop.Outlook, and then click Select.
    c. In the Add References dialog box, click OK

     

    The next thing I had to do was to add the following statement to the top of the program:

     

    It now looks like:

     

    Imports System.Reflection
    Imports outlook = Microsoft.Office.Interop.Outlook

     

    Module Module1

     

    Sub Main()
    ‘ Create an Outlook application.
    Dim oApp As Outlook.Application = New Outlook.Application()

     

    ‘ Get NameSpace and Logon.
    Dim oNS As Outlook.NameSpace = oApp.GetNamespace("mapi")
    oNS.Logon("YourValidProfile", Missing.Value, False, True) ‘ TODO:

     

    ‘ Create a new AppointmentItem.
    Dim oAppt As Outlook.AppointmentItem = oApp.CreateItem(Outlook.OlItemType.olAppointmentItem)
    ‘oAppt.Display(true) ‘Modal

     

    ‘ Set some common properties.
    oAppt.Subject = "Created using OOM in C#"
    oAppt.Body = "Hello World"
    oAppt.Location = "Samm E"

     

    oAppt.Start = Convert.ToDateTime("11/30/2001 9:00:00 AM")
    oAppt.End = Convert.ToDateTime("11/30/2001 1:00:00 PM")

     

    oAppt.ReminderSet = True
    oAppt.ReminderMinutesBeforeStart = 5
    oAppt.BusyStatus = Outlook.OlBusyStatus.olBusy ‘ olBusy
    oAppt.IsOnlineMeeting = False

     

    ‘ Save to Calendar.
    oAppt.Save()

     

    ‘ Display.
    ‘oAppt.Display(true)

     

    ‘ Logoff.
    oNS.Logoff()

     

    ‘ Clean up.
    oApp = Nothing
    oNS = Nothing
    oAppt = Nothing
    End Sub

     

    End Module

     

     

     

     

  • First permutation of the project

    I’ve created a simple Windows — not Windows Mobile yet — application that shows the date of the next infusion change if the user has put in the number of days, or has put in the Total number of units and the average daily total. The application does several things I haven’t done before:

    1. Add days to the current date value — super easy — Date.Today.AddDays(intTDDDays) where the arguments is the number of days to add.
    2. Set values in the registry — again easy — SaveSetting("InfusionSetHelper", "Settings", "TDD", strTDD)
    3. Retrieve values in the registry — again easy — Me.txtTotal.Text = GetSetting("InfusionSetHelper", "Settings", "Total", "")

     

    So the next decision to be made, is do I make this a Windows program that updates outlook, so should I got straight to the Windows Mobile application.  I think having it both places might be useful.

  • Rough Design of Windows Mobile Application

    I’ve been giving this a lot of thought and at the moment, this is what I think I need:

    • It should be a Today PlugIn.
    • Store TDD (but make it optional since it is not an issue for everyone)
    • Store number of days, with a default of 3 – use a Combo box
    • Store information on the open task so it can be marked completed
    • When the user clicks on the plug give the option to chose day or use given date, or ignore.
      • When selected the current open task is marked complete (but stays so that it can be tracked or deleted manually — though this could be an option.)
      • A new task is created based on TDD and number of days, which ever results in smallest day.  However, TDD may be ignored.
  • How To Access Pocket Outlook Objects from VBCE

    Here’s the bloody details, so the research end is going well.

    How To Access Pocket Outlook Objects from VBCE

    How To Access Pocket Outlook Objects from VBCE

  • Pocket Outlook Object Model (POOM)

    This looks like the main part of my program.  It handles all the outlook data.

    The Pocket Outlook Object Model (POOM) mirrors the Microsoft Office Outlook Object Model, but its scope of functionality is reduced to accommodate the practical constraints of mobile devices.

    Pocket Outlook Object Model (POOM)

  • More on the potential Windows Mobile Application

    I’m researching how to write the Windows Mobile application, and it dawned on me, that the application would be even more useful if it were a Today Screen plugin.  Options can be set and changed from there, and the user could just click on the plug-in to tell the program they had changed sets, so I’ve downloaded a Today Screen plug-in.