Hack Forums
[.NET] Simple Calculator! (My First Project) - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [.NET] Simple Calculator! (My First Project) (/showthread.php?tid=4550129)



Simple Calculator! (My First Project) - Achievement Hunter - Nov 22, 2014

Considering this is my first project I wanted to share this in hopes you would give me feedback and if I should improve on anything.
I do like when I get received feedback weather it be good or bad.

Virus Scan: https://www.virustotal.com/en/file/b55da315474d98e1ccf781ec1243dbfbe1e099ec5d2dfb8c09142b760f2ae2f2/analysis/

The Download(Executable): http://ge.tt/5pjj4452
The Source: http://ge.tt/5v6O7452/v/0
Screenshot:
Spoiler (Click to View)



* - Dialog - Nov 22, 2014

You're asking for feedback and only post an executable without code? Lol.

I'm not going to waste my time decompiling it, so I can give you the feedback you want.

Haven't downloaded, but;
Try finding out what the NumericUpDown control is for. Make sure you always check for valid input to prevent crashes, like I demonstrated in your other thread.


* - Achievement Hunter - Nov 22, 2014

(Nov 22, 2014 05:31 PM)Dialog Wrote:  You're asking for feedback and only post an executable without code? Lol.

I'm not going to waste my time decompiling it, so I can give you the feedback you want.

Haven't downloaded, but;
Try finding out what the NumericUpDown control is for. Make sure you always check for valid input to prevent crashes, like I demonstrated in your other thread.

Sorry dude XD
Here is the source:
http://ge.tt/5v6O7452/v/0


* - Rhyno - Nov 22, 2014

Downloading now. Gonna see what its like. are you okay with me adding this to a compilation I am currently making?


* - Achievement Hunter - Nov 22, 2014

All good rhyno
I'm fine with that xD


* - ByteCapone™ - Nov 22, 2014

Try actually naming your textboxes, radio buttons, labels etc.
The code gets confusing pretty quickly when making larger applications if you don't.
It's a good habit to get into.


* - Rhyno - Nov 22, 2014

(Nov 22, 2014 06:22 PM)Achievement Hunter Wrote:  All good rhyno
I'm fine with that xD

Alright. Keep looking out for it, It should be done tonight.


* - Heisenberg℠ - Nov 22, 2014

I suggest using the Hungarian Notation naming method which works like this for a button- "btnName"

Also you can assign x and y at the beginning for the data from the text boxes and then reuse them for each operator.

If you want to be able to use decimals then I suggest using the double data type and then format your .ToString as .ToString("N2") which means number to two decimal places.


* - Dialog - Nov 23, 2014

(Nov 22, 2014 06:40 PM)Heisenberg℠ Wrote:  I suggest using the Hungarian Notation naming method which works like this for a button- "btnName"

Also you can assign x and y at the beginning for the data from the text boxes and then reuse them for each operator.

If you want to be able to use decimals then I suggest using the double data type and then format your .ToString as .ToString("N2") which means number to two decimal places.

Although I agree controls should always be renamed, Hungarian notation is old and usage is discouraged by Microsoft's latest conventions.
I add a suffix to my identifiers for controls by convention, e.g. "registerButton" or "usernameTextBox".

See http://msdn.microsoft.com/en-us/library/ms229045%28v=vs.110%29.aspx