topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Tuesday November 11, 2025, 12:11 pm
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Recent Posts

Pages: prev1 ... 109 110 111 112 113 [114] 115 116 117 118 119 ... 145next
2826
Awesome website! - Just passed the link on to my sister-in-law who is starting a photography course when collage starts in September!

Might pass it onto my father-in-law who is an amature photographer also (even though hes goddamn awesome at this type of thing lol)
2827
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:11 PM »
DSC00701_2296x1528.jpg
DSC00702_2296x1528.jpg
DSC00703_2296x1528.jpg
DSC00704_2296x1528.jpg

Thats all I could be bothered uploading tonight lmao - There are around 820 more...didnt really think you all need them all :P
2828
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:10 PM »
DSC00690_2296x1528.jpg
DSC00691_2296x1528.jpg
DSC00692_2296x1528.jpg
DSC00693_2296x1528.jpg
DSC00695_2296x1528.jpg
DSC00696_2296x1528.jpg
DSC00697_2296x1528.jpg
DSC00698_2296x1528.jpg
DSC00699_2296x1528.jpg
DSC00700_2296x1528.jpg
2829
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:08 PM »
DSC00675_2296x1528.jpg
DSC00678_2296x1528.jpg
DSC00682_2296x1528.jpg
DSC00683_2296x1528.jpg
DSC00684_2296x1528.jpg
DSC00685_2296x1528.jpg
DSC00686_2296x1528.jpg
DSC00687_2296x1528.jpg
DSC00688_2296x1528.jpg
DSC00689_2296x1528.jpg
2830
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:03 PM »
DSC00665_2296x1528.jpg
DSC00666_2296x1528.jpg
DSC00667_2296x1528.jpg
DSC00668_2296x1528.jpg
DSC00669_2296x1528.jpg
DSC00670_2296x1528.jpg
DSC00671_2296x1528.jpg
DSC00672_2296x1528.jpg
DSC00673_2296x1528.jpg
DSC00674_2296x1528.jpg
2831
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:02 PM »
DSC00654_2296x1528.jpg
DSC00655_2296x1528.jpg
DSC00656_2296x1528.jpg
DSC00657_2296x1528.jpg
DSC00659_2296x1528.jpg
DSC00660_2296x1528.jpg
DSC00661_2296x1528.jpg
DSC00662_2296x1528.jpg
DSC00663_2296x1528.jpg
DSC00664_2296x1528.jpg
2832
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 05:00 PM »
DSC00643_2296x1528.jpg
DSC00644_2296x1528.jpg
DSC00645_2296x1528.jpg
DSC00646_2296x1528.jpg
DSC00647_2296x1528.jpg
DSC00648_2296x1528.jpg
DSC00650_2296x1528.jpg
DSC00651_2296x1528.jpg
DSC00652_2296x1528.jpg
DSC00653_2296x1528.jpg
2833
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 04:59 PM »
DSC00633_2296x1528.jpg
DSC00634_2296x1528.jpg
DSC00635_2296x1528.jpg
DSC00636_2296x1528.jpg
DSC00637_2296x1528.jpg
DSC00638_2296x1528.jpg
DSC00639_2296x1528.jpg
DSC00640_2296x1528.jpg
DSC00641_2296x1528.jpg
DSC00642_2296x1528.jpg
2834
Living Room / Re: Show us a photo of your mutt or other creatures..
« Last post by KynloStephen66515 on June 02, 2011, 04:58 PM »
Hey guys, I got bored today and decided to use the nice weather to sit in the garden taking a crap load of photos!

I would like to introduce you all to our newest addition 'Chewbacca' (Chewwy) and of cource, our first puppy, Munch!

DSC00618_2296x1528.jpg
DSC00619_2296x1528.jpg
DSC00620_2296x1528.jpg
DSC00621_2296x1528.jpg
DSC00622_2296x1528.jpg
DSC00623_2296x1528.jpg
DSC00624_2296x1528.jpg
DSC00625_2296x1528.jpg
DSC00628_2296x1528.jpg
DSC00629_2296x1528.jpg
2835
Living Room / Re: Microsoft unveils new UI prototype - Windows 8?
« Last post by KynloStephen66515 on June 01, 2011, 09:13 PM »
Wow, looks beautiful...but would NOT want to code on that lol

Gimme a keyboard over a touchscreen any day!
2836
mahesh2k I think he wants to keep SMF in its current state because of how highly configured DC's installation is.  Imagine how hard it would be to transfer the obscene amount of data available on this forum, over to another peice of software...and THEN transfering the user database, and THEN having to mess with google to try get re-indexed (AGAIN) lol.

Im in agreement with keeping SMF in its current state as the back end of DonationCoder and a nice looking, well organised CMS for the front  :D
2837
Developer's Corner / Re: Code Samples from Microsoft
« Last post by KynloStephen66515 on May 28, 2011, 08:22 PM »
nom nom nom
* Stephen66515 downloads

*edit* - ^^^^ wtf... /me automatically did the tags lmao - didn't know that was a BBCode on here
2838
Welcome To Part 3:

I'm sure that if you have completed Parts 1 & 2 then you are keen to continue with your project, so lets get cracking with that File Menu!

For this, you are going to need to add the following items:

  • openFileDialog
  • saveFileDialog
  • printDialog
  • printDocument
1.png
2.png

To add these to your project, click and drag them onto the bottom menu bar

3.png

Now you have added them all you will have something that looks like this:

5.png

Brilliant!

Now...Remembering what you learned in Part 2 you need to go ahead and click the "File" button and then double click the "Open" button

Add:

Code: C# [Select]
  1. string OFile = "";
  2.  
  3.             openFileDialog1.InitialDirectory = "C:";
  4.             openFileDialog1.Title = "Open a Text File";
  5.             openFileDialog1.FileName = "";
  6.             openFileDialog1.Filter = "Text Files|*.txt|Word Documents|*.doc";
  7.             if (openFileDialog1.ShowDialog() != DialogResult.Cancel)
  8.             {
  9.                 OFile = openFileDialog1.FileName;
  10.                 richTextBox1.LoadFile(OFile, RichTextBoxStreamType.PlainText);
  11.             }
Which should give you:

 
Code: C# [Select]
  1. private void openToolStripMenuItem_Click(object sender, EventArgs e)
  2.         {
  3.             string OFile = "";
  4.  
  5.             openFileDialog1.InitialDirectory = "C:";
  6.             openFileDialog1.Title = "Open a Text File";
  7.             openFileDialog1.FileName = "";
  8.             openFileDialog1.Filter = "Text Files|*.txt|Word Documents|*.doc";
  9.             if (openFileDialog1.ShowDialog() != DialogResult.Cancel)
  10.             {
  11.                 OFile = openFileDialog1.FileName;
  12.                 richTextBox1.LoadFile(OFile, RichTextBoxStreamType.PlainText);
  13.             }
  14.         }

Now you want to go back and double click "Save"

Add:

Code: C# [Select]
  1. string SFile = "";
  2.  
  3.             openFileDialog1.InitialDirectory = "C:";
  4.             openFileDialog1.Title = "Save Your Notes!";
  5.             openFileDialog1.FileName = "";
  6.             openFileDialog1.Filter = "Text Files|*.txt|Word Documents|*.doc";
  7.             if (openFileDialog1.ShowDialog() != DialogResult.Cancel)
  8.             {
  9.                 SFile = saveFileDialog1.FileName;
  10.                 richTextBox1.SaveFile(SFile, RichTextBoxStreamType.PlainText);
  11.             }

Which gives you:

Code: C# [Select]
  1. private void saveToolStripMenuItem_Click(object sender, EventArgs e)
  2.         {
  3.             string SFile = "";
  4.  
  5.             openFileDialog1.InitialDirectory = "C:";
  6.             openFileDialog1.Title = "Save Your Notes!";
  7.             openFileDialog1.FileName = "";
  8.             openFileDialog1.Filter = "Text Files|*.txt|Word Documents|*.doc";
  9.             if (openFileDialog1.ShowDialog() != DialogResult.Cancel)
  10.             {
  11.                 SFile = saveFileDialog1.FileName;
  12.                 richTextBox1.SaveFile(SFile, RichTextBoxStreamType.PlainText);
  13.             }
  14.         }

Now for the "Print" option:

Add:

Code: C# [Select]
  1. printDialog1.Document = printDocument1;
  2.             if (printDialog1.ShowDialog() == DialogResult.OK)
  3.             {
  4.                 printDocument1.Print();
  5.             }

Which gives you:

Code: C# [Select]
  1. private void printToolStripMenuItem_Click(object sender, EventArgs e)
  2.         {
  3.             printDialog1.Document = printDocument1;
  4.             if (printDialog1.ShowDialog() == DialogResult.OK)
  5.             {
  6.                 printDocument1.Print();
  7.             }
  8.         }


Now we are going to extend our "Exit" button.  Go to the designer, click "File", double click "Exit" and delete 'Application.Exit();'

Add the following code in its place:

Code: C# [Select]
  1. if (MessageBox.Show("Are you sure you want to quit?", "Exit", MessageBoxButtons.OKCancel) == DialogResult.OK)
  2.             {
  3.                 Application.Exit();
  4.             }

Which gives you the following:

Code: C# [Select]
  1. private void exitToolStripMenuItem_Click(object sender, EventArgs e)
  2.         {
  3.             if (MessageBox.Show("Are you sure you want to quit?", "Exit", MessageBoxButtons.OKCancel) == DialogResult.OK)
  4.             {
  5.                 Application.Exit();
  6.             }
  7.         }

Awesome!!!!!

Save your project and go play with it!  You can even run a print from it if you own a printer!!!



Thats all for this tutorial.

In the next we will add code for "Save As" and "Print Preview".

We will also make a start with our Tools Menu!  Even adding things like Fonts and Colours!!!
2839
Welcome Back!

Can't be bothered with long winded introductions so lets get cracking:

Recap:

In the last lesson we learned the following:

  • Where to Download Visual C# 2010 Express
  • How to setup your workspace
  • How to add MenuStrip with all the standard controls
  • How to add a RichTextBox and dock it to fit the entire screen
  • How to test your application

In this lesson we will learn the following:


  • Coding some of the File Menu Functions
1.png
  • Coding some of the Edit Menu Functions
2.png
  • Change the name of your Main Form
3.png


Firstly, lets deal with the easy part - Which is changing the name of your form.

To get the required property list up, you will need to click at the top of your form:

4.png

Now you need to look at the bottom right of your workspace and find the following screen.  Change the text where I have typed "Change Me"

5.png

OK, now thats done, lets get some coding done!

What you now need to do is click "File" (On your form - not on Visual C#) and double click "New"

1.png

Wow, the screen changed and now theres confusing text everywhere!

6.png

Don't Panic and Take a Deep Breath!

Your cursor should have been automatically placed where it needs to be:

7.png

Now you need to type the following code into the area your cursor is:

richTextBox1.Clear();

Which should now look like this:

8.png

Now you have done that you can click the play button (which we learned in the previous tutorial).  Type some stuff into the notepad window when it opens, then try your brand spanking new "New" button.

Awesome! you can now type stuff, and delete it all...not much use but we are getting somewhere!

Right, now back to coding! - Close the application you have made and go back to the Visual C# Window.

We are still on the coding window and need to go back to the visual designer, to do this you simply click on the Form1.cs [Design] button at the top:

9.png

Right, now we need the application to quit when you tell it to, without having to click the X in the top right.

Click "File" and double click "Exit"

Same as before, your cursor will have been placed in the correct position:

        private void exitToolStripMenuItem_Click(object sender, EventArgs e)
        {
            | <--- There
        }


Simply add:

Application.Exit();

So we have:

        private void exitToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }


Brilliant, now we have working "New" and "Exit" buttons

In the next tutorial we will learn how to code the rest of the file menu.  I am not covering those in this one because they require a little more adanced coding and a few extra things adding...so lets not get into that now :)

Lets get onto the "Edit" Menu now!

Same as before, go back to the visual designer, but this time you need to click "Edit"  then double click "Undo"

       private void undoToolStripMenuItem_Click(object sender, EventArgs e)
        {
            |
        }


Add:

richTextBox1.Undo();

You should now have:

       private void undoToolStripMenuItem_Click(object sender, EventArgs e)
        {
           richTextBox1.Undo();
        }


Back to the designer, click "Edit" then "Redo":

       private void redoToolStripMenuItem_Click(object sender, EventArgs e)
        {
             |
        }


Add This Again (Ill explain why later):

richTextBox1.Undo();

And now we have:

       private void redoToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Undo();
        }


Go back to the designer click "Edit" and double click "Cut"

Add:

richTextBox1.Cut();

Go back to the designer click "Edit" and double click "Copy"

Add:

richTextBox1.Copy();

Go back to the designer click "Edit" and double click "Paste"

Add:

richTextBox1.Paste();

You should now have:

        private void cutToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Cut();
        }

        private void copyToolStripMenuItem_Click(object sender, EventArgs e)
        {
           richTextBox1.Copy();
        }

        private void pasteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Paste();
        }


Now go and click "Edit" then double click "Select All"

Add:

richTextBox1.SelectAll();

Which should now be:

       private void selectAllToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.SelectAll();
        }


OK, now in your coding window you should have, in total, the following code:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;


namespace Notepad_Application
{
   public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void newToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Clear();
        }

        private void exitToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void undoToolStripMenuItem_Click(object sender, EventArgs e)
        {
           richTextBox1.Undo();
        }

        private void redoToolStripMenuItem_Click(object sender, EventArgs e)
        {
           richTextBox1.Undo();
        }

        private void cutToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Cut();
        }

        private void copyToolStripMenuItem_Click(object sender, EventArgs e)
        {
           richTextBox1.Copy();
        }

        private void pasteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.Paste();
        }

        private void selectAllToolStripMenuItem_Click(object sender, EventArgs e)
        {
            richTextBox1.SelectAll();
        }
        
    }
}


Awesome! - Now you want to save your project and go and play with it!



No homework this time except to try do all this without looking at the tutorial!

Have fun and Part 3 will be done within the next 24 hours!

2840
What should there be more of on DonationCoder?  You may only select up to 10 options.

What's the point of writing that anyway?


Boredom does strange things lol
2841
Hey Guys,

I'm kinda bored this weekend, so I have decided to write a tutorial for c# beginners.

Instead of using the usual "Hello World", We are going to be creating a notepad style application.

We will start with the basics then gradually add more and more function :)

Here Goes:




First things first:

Download Visual C# 2010 Express Here

Run the installation and add any extras you want. (If you don't know how to download/install software then this tutorial really isn't for you)

Once installation has completed, Launch Visual C# 2010 Express: (Note: First time being launched it takes a few minutes for the software to setup, dont worry, this is normal)

1.png

OK, now its loaded you should see the following screen:

2.png
(Click To Enlarge)

If you see that screen, then we are on track!

OK, now start a new project:

3.png

Now Select Windows Form Application, Choose A Name, and hit OK!:

4.png
(Click To Enlarge)

Now comes the fun part.  You should see the main screen!

5.png
(Click To Enlarge)

Now, for those of you who are completely new to Visual C#, this may all look a little bit daunting, but don't worry, this part is actually very very simple.

You may want to expand your form area a little bit so you have more space.  Don't worry to much, it doesn't really matter how big it is, just give yourself enough space to work :)

6.png

Now, Add a RichTextBox into the form area (Click and drag)

7.png

And now add a MenuStrip (Click and Drag Again)

8.png

Right Click the MenuStrip and click "Add Standard Items" - We will add the code for these later.

9.png

Now, you want to dock the RichTextBox we added earlier into its parent container (Click the text box in the main form window and click the little > arrow that can be found at top right of the highlighted box):

10.png

OK, now lets take a look at your software.  It cant do anything other than allow you to enter text, but its functional none-the-less :) - To exit your software and return to the programming console click the red X in the top right corner of the Notepad Application.

To load the software you will have to click the green arrow that looks like a play button:

11.png

OK, now you have seen your software in action.

Usually, Tutorials like this have you try to do everything in one session, but instead, what I am going to do is ask you to save your project (we are going to add to it in the next session. which will be uploaded in around 12 hours time (1-2pm GMT)).

Now your project is saved, close it, and attempt to do everything discussed in this tutorial without reading it again.  If you get stuck, take another peek, but don't go rushing ahead and add anything else to the project otherwise you will end up losing track and forgetting what you are learning here.  Be patient and you will be surprised how quickly things will come together!


-------------------


Homework (Yes, we have homework!):

  • Take a look at other notepad applications (Windows Standard) and others like Notepad++
  • Take notes of what features each notepad applications have and jot down anything you would like to add in yours

Let me know any features you find in other notepad applications that you would like to add, and would like me to go into further details about.


2842
This isn't an official poll, I'm just wondering what people think there should be more of on here :)

2843
Did you try right click and copy/paste rather than using shortcut keys (Worth a shot)
2844
Developer's Corner / Re: Thoughts on HTML5?
« Last post by KynloStephen66515 on May 27, 2011, 09:04 AM »
Personally, I dont really see the point in HTML5 yet...Its kinda like Flash...everybody wanted it, but nobody loved it enough to add full support in the browsers for it at the beginning of its life.
2845
DC Member Programs and Projects / Release: MegaNumbers v4 (Game)
« Last post by KynloStephen66515 on May 26, 2011, 12:29 PM »
Hey guys,

Here is MegaNumbers v4 -

Its nothing special but I figured I would release it here so it didn't go to waste lol

MN.png


Its a simple Guess The Number Game, nothing major, and nothing it doesn't need :)

------------------------

If anyone finds any problems or bugs with it, just post on here.  I have no real intention of updating this game beyond what it already does but I am happy to fix any errors :)


------------------------


Download:

2846
Living Room / Re: Dot Whatever You Like...
« Last post by KynloStephen66515 on May 26, 2011, 08:13 AM »
I smell a DC fundraiser for .dy then the domain could be www.co.dy - either that or .te for www.dona.te
2847
Living Room / Re: Man vs. Mississippi
« Last post by KynloStephen66515 on May 26, 2011, 08:10 AM »
Artilce in Popular Science magazine about DIY protection from the recent flooding:
http://www.popsci.co...pi-river-who-winning

from boingbong

Another Topic successfully saved by MOUSER!  :huh:

lol
2848
Its Awesome... :D

Ya might wanna fix the link though...its donationcoder, not donationcoders lol (Pretty much every link says https://www.donation...are/Other/mobysaurus

2849
Living Room / Re: Show us the View Outside Your Window
« Last post by KynloStephen66515 on May 23, 2011, 07:14 PM »
cba getting my camera...but this is almost exactly what i can see (except its different houses and shops from these)

scaffolding4L.jpg
2850
Living Room / Re: NSFW: Train Station Offers Sex Advice
« Last post by KynloStephen66515 on May 23, 2011, 07:11 PM »
Nice! :)

Who said Asia has the market cornered on messed up English? :)

haha ^5
Pages: prev1 ... 109 110 111 112 113 [114] 115 116 117 118 119 ... 145next