05 October, 2009

Done and Dusted!!!

Having handed in the two small assignments, the big Party Toonz assignment and sat the Chapter 11 test today (and spoiled my 100% record by not paying attention to what I was doing properly), I am over the moon to say that I have finished the programming section of the course - no offence Rachael - hooray!!

28 September, 2009

Party Toonz Assessment - Blog 3.

Yee hah!! Fingers crossed, that's this assignment put to bed for now - although the last little bit wasn't without its problems ...

A couple of days ago I wrote the Help file, made the About page and coded them both into the application. No worries. Then I had my first attempt at publishing, just like it said in the book - what a disaster! The Artwork and Music files were no longer able to be read for the exisiting data and I couldn't upload any new music - it gave me an error message about an unhandled exception or something like that. My database was connecting properly as I had changed the file path for the connection string, so I guessed I would have to do something similar with the Artwork and Music files too. I had stupidly assumed that they would be copied when the application was published.

Anyway, to cut a long story short, I changed all the Application.StartupPath & "\...\" paths for the Artwork, Music and Help files to have them being accessed from a PARTYTOONZ folder in the C: drive, just as I had done with the database, plus created matching folders for them coming from the C: drive obviously, and that seemed to work fine. It was a little bit of a pain because I forgot about the file paths feeding the picture boxes, but once I had changed those too it all seems to be working fine again. I just emailed Jake about this as he thinks there might be another way of doing this, but hopefully since I have burned both versions on to disc to hand in, Rachael will be happy with what I have done. I have made sure that the user knows that the file has to be run from the C: drive in the installation instructions.

So, for hopefully the last time, jobs done are:
• Help File
• About Information
• Application Published
• Disc Label
• Installation Instructions
• All 3 Blogs Written

Jobs still to be done:
• NONE!!

Signing off for the last time.

Deb.

25 September, 2009

Party Toonz Assessment – Blog 2 Footnote.

The next items on the jobs to do list were to create the classes for the Reader and Writer then code up the favourite’s buttons. Again I was surprised how reasonably smoothly this went, so much so that I had another one of my ‘brilliant’ ideas! Instead of the user having to click the favourite button to pass the track information to the current track panel and THEN having to click the play button of the media player, couldn't we just code it so that both things happened when they clicked the favourite’s button? Well apparently we could, and quite easily by just duplicating the If statement from the Play button, so this is exactly what we did! Hey presto!! A much simpler option for the user :o).

I also ended up coding another aspect of the favourites buttons in a slightly different way than the example we had been given, by having the track name appear in a label above the Favourite Button, so that I could have each favourite button display a message to the user about what they needed to do to play their favourite tracks. Then, after adding the appropriate coding regarding the Reader and Writer to the Load Event and Exit Event respectively, I tested each of the buttons and opened and closed the application a few times, and most of the bits and bobs seemed to be working well. Also the details from the favourites buttons were happily saved and restored as expected. I just needed to brush up on a couple of little errors I had made with regard to the various messages on the buttons, etc.

While I was doing this, Jake had wondered off on a tangent and started trying to code in complicated things that were way over my head (as he had been trying to do all along)! He did however find out how to do a couple of things that we had been talking about - locking the size of the form so that the user couldn't play with the layout, and hiding the controls at the top right corner of the screen so that the user would only be able to exit using the menu system - so that was really helpful.

By the end of the day my application seemed to be working smoothly, so all I now have left to do are the finishing touches which I can do at my own pace (but want to try and get out of the way asap). Poor Jake on the other hand still has some work to do on getting his extra complications all working well - I tried to help him out but I think I just confused him even more! In the end I just said my goodbyes and left him too it ... after beating him at pool again obviously ... as I knew he would be able to figure them out much more quickly without my 'help'.

So, as we stand now, further jobs done:
• Reader and Writer Classes
• Favourite Buttons

Jobs still to do:
• Help File
• About Information
• Publish

Signing off for the night again.

Deb.

Party Toonz Assessment – Blog 2.

Today’s work on the assignment started off with another of my ‘bright’ ideas. When adding a new track to the library, if the user didn't have an artwork image to match the track, I had initially asked them to pick any old picture to be displayed instead. However, upon reflection, I thought it might be better to give the user the option of just having the Party Toonz Logo displayed as a default. Putting the initial If statement into the Add New Track form was reasonably straight forward (with Jake’s help). However after testing we realised I also had to also add an If statement to the Delete button to make sure that the Party Toonz Logo was never deleted from the Artwork source folder.

Then we coded up the play button for the media player, which was actually easier than I thought it would be – hoorah! Rachael’s example looked really complicated because it included things like the OpenFileDialog and the Listbox but, seeing as these things were already taken care of with our existing interface, all we had to do was set up a variable to store the File Path for our previously selected track (from the GetTrack procedure). Done! The only “snag” of sorts was that we didn’t want the user to be able to use the existing buttons of the media player as they wouldn't be coded correctly, but this was easily fixed by covering the existing buttons with our newly coded buttons. Something else to tick off the list :o).

So, jobs done:
• Insert Media Player
• Create Play/Pause/Stop Buttons
• Create Volume Up/Down/Mute Buttons

Jobs still to do:
• Reader and Writer Classes
• Favourite Buttons
• Help File
• About Information
• Publish

Signing off from Blog 2.

Deb.

24 September, 2009

Party Toonz Assessment - Blog 1 Footnote.

As mentioned in the first post, seeing as our reason for packing up early had disappeared, Jake and I decided to bash on with the project and try and get the four Select/Edit/Delete/New buttons finished. The code for the Select button itself was mercifully short and sweet, and the code for the GetTrack procedure was also reasonably straight forward, thanks partly to our increased understanding after working through the steps for the delete button, but also in no small part thanks to Rachael's very detailed examples.

The Edit button started off quite well ... until some silly person (ok, I think it was me) suggested that if the user would be able to edit the Track Name and Artist Name, shouldn't they be able to edit the Album Name and Artwork as well? Hmmmmm. Adding in the Album Name was pretty straight forward, and the creation of the Edit form went pretty well (or so we thought) until we tested it out. Everything went fine until we tried to update a record without selecting a new picture. When we did that, instead of the original picture remaining associated with the record, no image would be displayed at all. It also didn't help matters that Jake and I had decided to approach this part of the project in a slightly different way to each other. To cut a long story short, after much head scratching and playing around with various bits of code, Jake managed to get his working and between us we also managed to figure out a line of code that would get mine working too, so at about 6.30pm we called it a day ... sorry night. That left just enough time for Jake to get his revenge at pool of course!!

However once back home, and refreshed after dinner, I thought I would spend a little time making my Add New Track and Edit Track forms look pretty - how long could that possibly take I thought ... Well, once I got over my OCD tendancies of not having to have EVERYTHING perfectly aligned, not that long as it turned out. They are not the most fantastic looking interfaces in the world, but hopefully they are reasonably user friendly and I like the gimic of having the logo I "created" in the background of each form.

Having done that, and seeing there was nothing on TV, I thought I would then wind Jake up by making a start on the Media Player :o). At this stage I was still unsure as to whether the Media Player should be in a form of its own or not, however I personally would prefer it do be on the main form if possible so I spent a little time arranging my original interface to fit it in. I then added the Stop/Pause and Volume Buttons and coded them up, although I will be leaving the rest of the coding til tomorrow when I am heading back to Jake's so that we can work on as much of the rest of the assignment as possible again.

So, to sum up, the list of jobs done can now include:
• Select Button
• Get Track Procedure
• Edit Button and Form
• Windows Media Player (majority of buttons)

Jobs we hope to complete tomorrow:
• The rest if the Windows Player buttons
• The 4 Favourite buttons, etc.
It sounds so easy ...

Ok, definitely signing off for the night now.

Deb.

Party Toonz Assessment – Blog 1.

Having completed the two smaller assessment items ourselves and found them to be reasonably straight forward, Jake and I decided we should try and tackle the Party Toonz assessment together as it looked a lot more difficult - two minds and all that! As we were due to get together on Thursday the 24th, I spent a couple of hours the day before reading through the assignment, creating a basic interface, creating the splash screen, downloading the Windows Media Player object, and creating the database. Jake did the same thing so that we could pretty much start programming from the get go.

We started by creating the main connection string to the database and writing the Load List Box procedure so that we had some data to work with. We then quickly added the menu strip so that we could at least tick something off the list! Then we attempted something a bit harder – coding the New Track button and creating the form to go with it! This took a reasonable length of time as we were still trying to get our heads round the requirements of the project, but it was really useful to have older projects to look back on – for example the Cats and Dogs project so that we could remember how to list more than one file extension for the OpenFileDialog - as well as the latest examples form Rachael.

After some serious cheering and fist pumping when that worked (and a quick trip to Hungry Jacks for lunch!) our next task was to tackle the delete button – well our sample data was a bit silly. Having already used the Connection Object and Command Object sections of code in the Add New Track form, this all started to make more sense, and so coding the Delete button was not too painful, apart from the fact that we couldn’t test it out as we hadn’t coded up the Select button yet. However, the lack of blue squiggly lines made us think we must be on the right track!! Who said ignorance is bliss again??

At this point we were due to stop (as I had to go to a tutoring lesson) so we decided to sum up our efforts for the day and write this blog … then, while I was in the process of beating Jake at pool (sorry Jake), I got a phone call cancelling my session so we decided to bash on regardless. However, having already started these blogs posts, we thought that we would finish them first.

So, all joking aside, this is where we are now (although we are about to do a little more) …

Jobs done:
• Main Interface
• Splash Screen
• Database
• Menu Strip
• New Track Form
• Delete Button (hopefully)

Jobs we hope to finish today:
• Select Button and Get Track procedure (so we can check the delete button is working)
• Edit Button and Form

Signing off from Blog 1.

Deb.

23 September, 2009

File Handling and System IO task.

I have commented these questions on Rachael's blog, but just in case someone else reads this first and knows the answers ...

Hi Rachael.
Just a quick question about the "File Handling and System IO" task.
For Activity 8 we are asked to place five button controls on the interface (btnOpenFile, btnSaveFileAs, btnOpenLog, btnSaveLog and btnDeleteFile) but we are only given code to include for the first three. Is there some code missing from the assessment sheet or are those extra two buttons not required?
We are however given code for a button called btnClearTextbox which we have not yet added to the interface. Is this a new button or the code for one of the other buttons which we can just rename?
Hope this makes sense and that you are having a nice break.
Deb.