Download:
AIR Application:
Class File:
Step 1:
First click the “New Project” button. We are building a new project right?
Step 2:
Add languages you will use in your Flex/AIR/Flash project.
Step 3 – 1:
After you added the languages, start to add items.
Step 3 – 2:
ID is very important. It is a unique name for your items. You will use it in your Flex/AIR/Flash projects to get items. (example: class.getItemByID(”home”);)
Step 4:
Ok you added your items. Now save your language file. You will see .mlsp format has a green book icon.
Step 5:
Move your language file to your source files of your project. Or save it to there directly. Now we are ready. With 5 steps we’ve created language file for our project. Now we need to use it in project.
First we need to import MLSP class and set some values:
var languages:MLSP = new MLSP("demolangfile.mlsp",onComplete);
MLSP has two parameters. First one is language file url(example: “langfile.mlsp”, “lang/langfile.mlsp”) and the second one is loaded function. When language file is loaded your loaded function is called. Let’s continue:
trace("Language File Loaded");
setLanguage()
}
function setLanguage():void {
trace(languages.getItemByID("home","EN"));
trace(languages.getItemByID("home","TR"));
}
When language file is loaded setLanguage function is called. MLSP has only one method. It is getItemByID(). It has two parameters. First one is the id of your item and the second one is language you use.
This is it! Yeah I know this is so simple and not for a complex projects. Or maybe there is more powerful tools for this. Anyway I want to share
Also this a sample flex project which uses MLSP:
Source Files






Thanks Yagiz. This is awesome project!
Thank you Lee
Kutlarım yağız sağlam proje =)
Sagolasin Ozgun
Yağız keşke “save as” yapsaydın nereye kaydediyor bulmak için epeyce tırmaladım yahu
ama ellerine kollarına sağlık dostum
Onumuzdeki gunlerde belki yeni versiyonunu cikaririm. Ozaman Save As secenegini de eklerim
teşekkürler gayet başarılı Yağız
Tebrikler, güzel bir çalışma olmuş.
@gökhan, @Berkay Ünal: Teşekkürler.
Congratulations for you’ve been selected as an Iphone application developer. We hope to see you in higher ranks, flash master.