Friday, January 24, 2014

Ideas for programming projects

One of the things I sometimes struggled with, is what should I do to keep programing going on. Even though I am a bit busy lately with studies, I always think what I could possibly do and I'll try to share some of my toughts with you.

One thing to mention though is that, you should always try to do something you CAN do. Meaning, if you are like me, more into HTML/CSS/JS/PHP etc. or it wouldn't make much sense if you would suddenly out of no where go "I'll do Raspbery Pi app!!"...right? I mean you can if you wish to venture into that but I do think you should choose something that you can use the skills you posses and try to build on them as much as you can.

idea



So here is something that you could try doing:


1. Website

As prevously mentioned, since I'm more web-browser oriented, I do like sometimes creating just a simple HTML/CSS page, which is something you could do too. I do so because it keeps me thinking of design aspect of the website but then the semantics of HTML and CSS to page be somewhat responsive and functionanly working. But you could try creating your own personal website or do one of the following:

 - personal/portfolio website
 - site for business
 - responsive website

At least this is something I keep it oriented to. However I always strive to pull out the maximum of the site so I check it on the mobile phone, add some photo galleries and so on.


2. Web Application

Even though I personaly like to put applications on to the Website, it is also a good practice to just try doing something like a timer or calculator. Or try to remake something that already exists on some of the other pages. In my case, as I said, I always try do add this somewhere on the Website I would be creating, so here is what you could try:

 - timer
 - calculator
 - checklist
 - login forms

You could think of it as a "tool" that will make user more interactive with the page, meaning that the "tool" will help them do some event.


3. E-commerce Page

I do think this kind of a pages are good, especially because of the use of DataBases. Because these are somehow connected with the Web Applications from my point of view and most of them are used using PHP. At least I had a project being done in PHP before. But more it also somehow forces you to present the products from the DataBase in some order therefore it forces you to do some JavaScript or something.

What you could do is, try seeing other E-commerce websites, and try to create the most important bits of it, such are: shopping cart, users log in, product check outs etc. This should really pull out a lot from the skills you posses.


4. Smart Phone Application

If you aren't into web-browsers but you wish to create applications for iPhone,iPad or Android that is good as well. However you might want to know for some of these phones something more specific as it is Object Oriented Programming or know Java language. I haven't really been into this kind of applications so I can't tell much about it.


That would be something I keep thinking in my head when it comes to making a project. Some people like to do as well Social Networking sites which is somewhat similar to E-commerce style of a site, because you'd need Databases, PHP, JavaScripts etc. so this is something you could take in concideration as well.

One last thing is that, if you don't have time to create a whole web-site just to create somethign to see how it would look on a web-site you could use CMS style of web-sites and still use just Databases or PHP to write code that user will interact with.

Tuesday, January 21, 2014

You want to start programming but have no clue where to begin?

I've been thinking of the time how I ventured first time into programming business, even though originaly I was more into graphic motion and design, and tought to give you some directions if you are starting or if you want to start but don't have clue where to begin.

Personaly, my first executed code was in MS-DOS. Now you probably won't need to use it as much as I did but if you think on going seriously into developing, sometimes you might just come across doing something on another server of some kind where you might have to switch from folders and opening files in that way. This is not really anything about programing its more how to create, open, delete etc. folders and files so just have it somewhere in your head if you need it at some point.


Programming Languages


My first REALL code that actualy did something was in Action Script. It was AS 2.0 but at the time I was doing those codes, now when I look at it, I basicly knew a lot of pre-made instructions that were connected with certain things. The actual place where I started to program something for reall, as in thinking how compailer works, how memory is using certain variables, the for-loops, if/else statments etc. was on my university for the C programming language.

I do think this is a good base because C++, C#, Java and Action Script 3.0 are all based on this...well more C++ and OOP(object oriented programming) but C should really help you understand how somethings work and you should be able just to build your skills from this point.

I did not try Python ever so I can't tell you how does it work. What other thing pop-up in my head though is ASP.NET. Because it is buliding web-pages with C# language. Therefore you should also take time in exploring HTML, CSS, JavaScript because these are most comonly used in web-developing. Even if you are not going for ASP.NET you would need HTML, CSS, JS for developing web-pages.

There is also PHP, and most logic you would go trough C, C++ or C# you will find similar in PHP, however it is not THAT similar because...well...somethings work differently there because of rules you must apply in order for them to work on a web-page.

You might wonder:"what?! how am I supposed to know all this and I just want to start!?" it was not my goal to tell you that you must know all of the languages I mention. All I wanted to explain is how languages are connected a lot and if you start from C I think that should be good start, however you can go just with what you feel the best. If you think C is not your level you are getting it to easy, then speed things up! Try other languages, experiment with stuff.

One last thing, a good programmer is the one who can find solution for a specific problem. Not the one who makes a thousands of codes, because he/she saw it in a movie and it looks cool, just to make 2 + 2 give you a result of 4. Figruatively saying.



Sunday, January 19, 2014

These are one of the things I have in mind for the days to come

So I'll be having next two weeks a hell to pass 4 subjects. I've finished up 3 diffrent essays and now I am hoping for the best. But mean-while I have set up some plan in my head to do with this blog of mine.

I'll be creating a fictional Pizza shop. It means I'll try to create a web-site, including design and developing, using data bases and what not. Basicly my goal is to create a fully functional information system. Right now I am thinking of doing as well app that will serve for payment processing, meaning that people who work at the point where they have to charge you and give you bill, they use this app for this purpose so that the database has an information of what necessary regents are missing at what point the amount of sold portions and other things.

However I'll see how I'll manage time with that as I'll also be sort of working with freind from USA at Digital North he is just starting up and I've been talking with him to wait for my subjects to be done so we'll see...

Friday, January 17, 2014

Latest Design

So I have been sorting out things on my PC cleaning up some junk, sorting out the plans for the future and whatnot and I've came up to an Design I've been doing like 8 months ago or so. It was for my personal portfolio that I couldn't maintain but when I look at the design I think its pretty neat!

Dusan Acimovic Old Portfolio
Dusan's Old Portfolio

I do think it could have a bit more details on the picture in the background now when I think of it. Also I like it because I had this sort of spaceish/technologish wanna be look in my head that I wanted to execute into a reall looking piece but hey...its kinda probably my first "serious" design I have done. If nothing I hope you like to watch graphics as I do!

Have fun.

Sunday, January 12, 2014

Simple LogIn form using C# WPF Application

Right, so...I tought to give some small work done, but I wanted to see more if I forgot completely the C# and WPF at all since I used it last year, but it wasn't the case really. So as the title says, I'll show you a
simple login form being done in WPF. This is just going to be a demonstration of login form and you should have some basic idea where to go on from there if you really want to use it for some  project of your own. So lets start!


You can download my final app and how it works here: Simple Login App
If it tells you that is from unknown user and it might put your PC at risk, its becase I've created it...so you can just choose "run it anway" It won't do any harm. You can trust me, but I know its not realistic to expect that. Choice is on you.

I am using Visual Studio 2012 as that is the latest I got from my university however I don't think the options
should be much diffrent in previous versions or newer, if there is one, I haven't really check. So open up a
new project and choose Visual C# from Templates list and then choose C# WPF Application and give it the name whatever you wish I gave mine SimpleLogInApp.









Once you have done that, you should see on the left of Visual Studio interface a "Toolbox" tab. You will find
in this tab the following tools you need to place on the Main Window Frame. Such are: TextBox, Passwordbox, Labels and a Button. Make sure you have one PASSWORDBOX, if you want to have those ***** symbols to hide up the text for when you are typing password. You can then position however you like input (text/pass) boxes.






Once you have positioned the main tools on your Main Window Frame we should give the name of each of the input boxes as well as button and the label that will show us information as user clicks on the button. We are doing so in the Properties pannel in the bottom-right portion of the screen like shown on the picture.





Also if you wish to your input boxes start without text inside of them just make "Text" atribute in Properties
tab empty. In the same way you can change the Text on the Button so it shows "LogIn" as it shows on mine.







Once you've placed all of this you should double-click the Button and this should lead you into C# code section where you created an event for that Button. Also there are few other things that you should know what are for.

First there is code showing as this:

 public MainWindow()
{
    IntializeComponent();
}


This is basicly the part that intializes the specific code upon launch of application.
We will first add one integer variable to control the button's LogIn and LogOut switch. It is probably good to use switch sequence at this point but I just went with If,else statments.

int ctrl = 0;


So once a user succesfuly logs in, this variable will become 1. Once he log's out it will become 0. Just so it
can do two diffrent parts of the code after loged in and when loging in.Then inside of a Button_Click event you created previously by double-clicking on it we will add following code:

if (ctrl == 0)
{

}
else
{
 
}


So basicly this is for the LogIn, Logout part. Now inside the If statment we will add following code:

if (ctrl == 0)
{
   if(username_tbox.Text == "Admin" && pass_box.Password == "admin123")
     {
        Info_label.Content = "Loged in!";
        username_tbox.IsEnabled = false;
        pass_box.IsEnabled = false;
        btn_log.Content = "LogOut?";
        ctrl = 1;
       
     }
    else
    {
       Info_label.Content = "You've entered \nwrong Information.\nTry again."
    }

}
else
{

   Info_label.Content = "Loged out!";
   username_tbox.IsEnabled = true;
   pass_box.IsEnabled = true;
   username_tbox.Text = "";
   pass_box.Password = "";
   btn_log.Content = "LogIn";
   ctrl = 0;
 
}

As we can see we added an if,else statment inside the first if statment. Reason for this is because we are telling the compiler to do next. If the variable ctrl is equal to 0, execute the code inside the if. Since the
variable ctrl is already set to 0 this is going to be the first thing that is going to happen once user clicks
on a button. After that it continues into the if,else statment we placed inside the first if statment. And its
doing the following:

If the text entered in the Username textbox (username_tbox.Text) is equal to "Admin" and text inserted in the Passwordbox (pass_box.Password) is equal to "admin123" execute the code inside that If statment. And it is doing following:

- Sets the Info label placed on the Main Window Frame to inform user that he succesfuly loged in if he typed the "Admin" and "admin123" username and password.
- Disables the username textbox so that we can't use it anymore since we are loged in already.
- Disables the passwordbox so that we can't use it anymore since we already entered the right password.
- Sets the name for the button to be called "LogedOut?" asking the user to log out now when he is loged in.
- Changes the control variable to 1. Indicating that user is now loged in.

Now the trick thing is that once we will press Button again, after we are loged in, it will check the first if,else statment and since now ctrl variable is 1 it will jump to the else statment and it will set the objects on a stage to look like the user is loged out. Such is:

- Set the Info label to inform user that he succesfuly loged out once he clicked, this time LogOut button.
- Enables username textbox so that the user can log in again.
- Enables the passwordbox so that user can enter password in order to log in again.
- Changes the content of a button to "LogIn" so that user can log in again
- And ofcourse sets the variable ctrl back to 0. So that once user clicks LogIn, it will start the whole cycle again.

So this is it!! A simple login form using WPF and C#. In reallity you would want to create a Register button as well, but that is something that probably will have to do with DataBases, not necesseraly though. You should have some basic knowledge now about how some things work for the C# and WPF. If you have any question of how something works do not hasitate to ask I'll answer as soon as I am able, it shouldn't be longer then 24h.

If you like this tutorial do follow me on Facebook, Twitter and Google+, I'll be posting some more in the future!! Stay tooned.

Saturday, January 11, 2014

Top 5 programs I must have as developer

I've been thinking lately about the programms or applications I must have when I think about developing a software application or a web-page. I know many people are using diffrent things and also I think that comes in with the taste and for some people its emotional factor (do not ask...) but here are some I just must have wherever I am using computer.



1. Google Drive - This is probably the most needed application for me because every programm I write or application, I make them saved on a folder in a Google Drive, because I am offten going to university and back and I just can not think if I carried an USB memory stick with me, will my sister answer me if she is at home to send me what I need or whatever other reasons you could think off. Like this I just know I'll have everything I saved last on my home's PC wherever I log into G-mail account.

2. Microsoft WebMatrix - I prefer this one mostly because of its interface. Probably because I've been using MS Office since forever too but most of my HTML,CSS, JavaSCript and PHP codes are much clearer to visualy see and control using this. Also the Console for Logs/Error Lists, is much more like Visual Studio as I've been doing C# most of the time trough out my studies. However I don't use WebMatrix for ASP.NET just because I am used to Visual Studio as that is where I first time started using it.

3. Visual Studio 2012 - This was like main program troughout my studies where I've been using C, C#, Windows Forms Application, WPF Applications, Object Oriented Programming with use of SQL Data Servers and Bases and as previously mentioned ASP.NET. I've been doing projects for uni as well in this languages and templates so I just can not imagine doing any of this somewhere else.

4. Microsoft Visio - I just have to use this when I'm building larger project that will include Use Case scenario diagrams, Data diagrams and other diagrams that help me plan the whole process of using a specific programm or system. I can not imagine doing this way of a project starting purely from coding.

5. NetBeans - I use this purely for Java. It took also the larger part of my studies which include also Java's Object Oriented Programing and using DataBases with it. I know some people are using Eclipse? if I'm not wrong but I'll just stick with what I have.

This is basically the 5 programs or applications I must have wherever I go. I do have Adobe's Flash installed too just because Action Script was my first programing language so I do like to, from time to time, experiment with it and its components. Mostly to do some rich graphic animations.