Quick guide to installing Django framework on Windows

djangoDjango is a dev framework for building web apps that uses Python. It has many great features (db api, auto admin interface, templates, cache framework, etc.). Installing the framework on Windows take a few steps to get going and has a few prerequisites. The below steps assume you don’t have Python or Django currently installed. This guide was created on Windows 7 (64 bit). Now let’s get to it:

  1. Download Python: http://www.python.org/download/releases/3.3.3/
  2. Install Python (to c:\python)
  3. Go to the pip download area: http://www.pip-installer.org/en/latest/installing.html#using-the-installer
  4. Right click, download / save ez_setup.py to c:\python
  5. In cmd prompt: cd\python
  6. Run: python.exe ez_setup.py
  7. From the same link, download get-pip.py
  8. In the cmd prompt, run python.exe get-pip.py
  9. When finished, in cmd, navigate to: \python\scripts  (where pip lives now)
  10. Now run pip install Django
  11. To see if Django was installed correctly, at a cmd prompt run:
    python -c “import django; print(django.get_version())”
    This should return 1.6.1 (or similar).
  12. Add c:\python\scripts to your windows environment path
  13. Close / reopen a cmd prompt (to reflect the addition to your PATH variable)
  14. Now you can navigate to any folder (ie: c:\projects) and run:
    django-admin.py startproject thenextbigidea
  15. Your project was created! To test:
  16. Navigate to c:\projects\thenextbigidea and run:
    python manage.py runserver
  17. In your browser, visit: http://localhost:8000/

So that’s just the start. Visit https://docs.djangoproject.com to continue your journey!

Quick guide to installing Django framework on Windows

Adding attachments to an email using Exchange Web Services

In a previous article on sending email with Exchange Web Services (EWS) we showed how easy it was to integrate with Exchange and send email. If you’ve ever wanted to attach a file to an email that your sending, it’s super easy (much faster than the System.Net.Mail method):

//Create an email message and identify the Exchange service
EmailMessage message = new EmailMessage(service);

//Attach a file - THE MAGIC
message.Attachments.AddFileAttachment(@"c:\temp\somefile.jpg");

//Send the email message and save a copy
message.SendAndSaveCopy();

That’s it! If you want to see all of the code needed for sending, see Retrieving and Sending Email using Exchange Web Services Managed API 2.0 (c#)

Adding attachments to an email using Exchange Web Services

Twilio SMS Messages In Non-web .net Application with Twilio REST API (c#)

cell-phoneTwilio is a great SMS (text message) gateway to use for sending and receiving SMS messages. The process is super simple and flexible to get started using (the Twilio REST API helper library is great). However, in my case, I wanted to access the API through a “windows form” application, but the API needs a little something extra to get this to function. In my experience, a proxy. Below are the steps from start to finish to retrieve messages from your Twilio account: Continue reading “Twilio SMS Messages In Non-web .net Application with Twilio REST API (c#)”

Twilio SMS Messages In Non-web .net Application with Twilio REST API (c#)

Update – More Details: Retrieving Email using Exchange Web Services Managed API 2.0 (c#)

email-orange-512x512So maybe you have started to use the Exchange Web Services Managed API to get email from inboxes and wanted to get a few additional details. Below are two of the most popular issues: Continue reading “Update – More Details: Retrieving Email using Exchange Web Services Managed API 2.0 (c#)”

Update – More Details: Retrieving Email using Exchange Web Services Managed API 2.0 (c#)