Monday, June 21, 2010

My simple batch file tutorial [Part 7]

This is the final part of our tutorial where today I going to teach you how to spruce up your batch files menu and also how to create multiple level directory in a batch file.

Let us build a whole new programs such as Karaoke setup programs (Recently, I  just went to holiday trip to found this incredible ideas) . . . . .

Before we program anything , we must had a plan on imagining how it works and how is the structure of the programs.

For example, the "Love Story by Taylor Swift" is quite a nice songs so we need to have a select songs by its titles and since it is so nice, we can also select what other hits by the Taylor Swift.
So, we have it we can have options of selecting a songs based on their titles and their artist.
So, what we have next ? Turning keys to either ♭ (low) or  (high) , just add them up. and finally the play buttons to start karaoke sessions. 


So in our program outline, we can imagine our programs will had something like this.

Karaoke Machines Box
1. Select Songs
2. Select Titles
3. Keys
4. Play
5. Exit

In theory, you want the the menu looks something like this , if you want to decorate it.

But if you refer back to earliest part of tutorial, if you followed to the tiniest details , you might remember that I say batch is ANSI supported but it is not known to support Unicode. :) But I found a workaround around the ANSI stuffs to include the Unicode which provides more stuffs. 




Tadaa ... This is one of the way you can do it. :) 

Now , I show you how you how to implement the Unicode in Vista some more ... . 
Damn MS support, I can't find anything there. Computer Engineering Rulez .... 

In Vista.
1. Select Control Panel -> Regional and Language Options
2. Select Administrative tabs
3. Select English (United States)
4. Restart the PC and close and save any programs before you do so.



Later, we open up our notepad to change our console settings

Click Format tab -> Font . . . 
Select Lucida Sans Unicode ( You may try others but believe me, this is one of working fonts)



Okay , now we need to enable the Num Lock , we need to to type ALT buttons to the numbers that we want to use to produce the code. To use the Unicode, we need to use the ALT methods. 




When using ALT-Num is means that you will press (hold) ALT and type this desired number using these blur highlighted numbers at the same time. (M -> 0 ; J -> 1 , K-> 2 , .... )

Such as you want the symbols number 123   , you hold Alt buttons and type letters J, K ,L at the same time
(P.S : May differ with different laptop model.)





Since this part is taking up much of the time, I decided the directory leveling will be continued to next part. See you on the next part  . :) 

UPDATE : For the directory level to worked correctly , Select songs must come after Select Artist

E.G 

1. Select Artist
2. Select Songs

Sorry for any mistakes that I had made, thanks to my friends pointing this mistakes out . :P 

No comments:

Another random post to read ? Come !

Related Posts with Thumbnails