Loading user information from Channel 9

Something went wrong getting user information from Channel 9

Latest Achievement:

Loading user information from MSDN

Something went wrong getting user information from MSDN

Visual Studio Achievements

Latest Achievement:

Loading Visual Studio Achievements

Something went wrong getting the Visual Studio Achievements

Day 3 Homework Solution

18 minutes, 14 seconds


Right click “Save as…”

Got stuck with the homework assignment?  No worries, simply watch enough of this solution video to get un-stuck, OR compare your solution with Bob's version. IMPORTANT: before you peek at this video, please—for your own sake—try to complete this homework assignment on your own. You'll only learn through practice, frustration, and exploration.

Download the source code in c#

Download the source code in VB.Net

Follow the discussion

  • Oops, something didn't work.

    Getting subscription
    Subscribe to this conversation
  • You mentioned in your instructions to catch / trap for the user clicking save, delete, edit button at the wrong time and didn't cover it is in the solution. I just went ahead and set the isEnabled for each of the buttons to prevent the user form clicking the wrong button in the first place...

    I did this with a method setIconButtons(bool edit, bool save, bool delete) and then in each icon button click I told it which icon buttons to turn on / off…

    Great lesson!





  • Marco ForteMarco Forte

    Hey theres actually an enumeration for Filemode called "Truncate" that will Completely wipe all data in the file without creating another.
    Love the Series Marco

  • I made a mess of mine. I did everything up to the save point. When trying to save it I was using the technique from the Tombstoning lesson, it didnt work Sad

  • Ahh, I've just finished the full thing and I did the delete function different, with fewer lines of code.

    I called the isolated storage and deleted the file, then set the textbox to "".

    3 lines of code is all it took Smiley

  • Jaguma GamesJaguma The only epicly awesome person to fail at succeeding to fail at succeeding.

    @Mintydog: Same Wink

    Oh yeah, GREAT TUTORIALS BOB Smiley

  • Jaguma GamesJaguma The only epicly awesome person to fail at succeeding to fail at succeeding.

    Also, to delete the file, couldn't you have just used - 

    private void delete_click(object sender, EventArgs e)
                string fileName = "My_Note.txt";
                IsolatedStorageFile storage = IsolatedStorageFile.GetUserStoreForApplication();
                outputBox.Text = "";
                inputBox.Text = "";
            } // Delete

Remove this comment

Remove this thread


Comments closed

Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation, please create a new thread in our Forums, or Contact Us and let us know.