mortscripts tut??? - Windows Mobile

i have heard lots of about mortscripts use,,
but plz can someone elaborate how??
like how can i add new taskbar icons??
how to create flder?
and finally where the hell to put it??
sorry..
if someone already know then plz give the link..

hi, mortscript is a scripting language
you can build a file with extension .mscr and when you double click it instructions will be executed. you can do anything with mortscript: write/read to registry/files, run programs, send commands to the operating systems, send events to the queue...
mortscript is a simple language so you can be up and running in little time. there is no GUI so it is a language very descriptive.
the program can be downloaded at the author's page. There is a complete and concise pdf manual.
in xda there is are two reference threads: mortscript examples acumulation and mortscript source compendium.
rather than ask for that or that code, learn by doing...the machine will do what you want to.

cruiserrr said:
hi, mortscript is a scripting language
you can build a file with extension .mscr and when you double click it instructions will be executed. You can do anything with mortscript: Write/read to registry/files, run programs, send commands to the operating systems, send events to the queue...
Mortscript is a simple language so you can be up and running in little time. There is no gui so it is a language very descriptive.
The program can be downloaded at the author's page. There is a complete and concise pdf manual.
In xda there is are two reference threads: Mortscript examples acumulation and mortscript source compendium.
Rather than ask for that or that code, learn by doing...the machine will do what you want to.
Click to expand...
Click to collapse
can i cook them??
Like wher i have to put them to execute???ext folder??shared folder or in folder with mname zzzz

Here's a mortscript package. Just put it in your EXT directory. As for the scripts themselves, do whatever you want. I use them during customization (unzipping; creating my start menu..), so you need to put the commands into an add2config.txt file. I also have a few that I use for backing up/restoring files, or exporting reg keys. I just have links to them in my start menu.

you can cook both the app (as says previous post) and the scripts you create or reuse. you can use scripts that build (or copy) the shortcuts at boot time or do anything you want. this is not a quick shot, I recommend you take some reading on mortscript, there is a lot here at xda.

thank u thank u all of u..

There is a WIKI with some examples too. See my Sig

RoryB said:
There is a WIKI with some examples too. See my Sig
Click to expand...
Click to collapse
and RoryB is another mortscript WIKI himself !!

Related

n00b question about adding my own programs

Okay I understand you have to use mkrom and Linux (or cygwin on Windows) to roll your own ROM my question is regarding how one could say remove one program from the SE ROM and include something else, for instance take off the byte counter and put another different counter on or such, would you just copy the necessary files (.exe and dll's) to the files1 or files2 folder and that's it ? What more is involved? Thanks in advance!
for simple programs, that is all there is to it.
some might need more research, as to which registry settings need to be tweaked to get te program to run from the windows directory. and what settings it needs to run at all.
You copy the files to either files1 or files2. Both sets of files end up in the \Windows subdir. So if you do not want to copy the files to RAM (see below), you should make sure the program is set to run from \Windows. Then you add any necessary registry keys to "default.reg", and any file-copy or directory creation commands to initobj.txt. Then run "mkrom <ROMfile>" and hey-presto.
Thanks so much for all your guys awesome work!!
entropy1980 said:
ok sounds good, what would one need to do to mod the registry for the programs (By that I mean prior to booting) I don't want to be mucking around with a reg editor after the device boots just to get the progs to work...
Click to expand...
Click to collapse
Not sure I understand the question. Default.reg just holds the entire registry as present after a cold restart. So if you put something in there, this will be in the registry when the device wakes up.
I think we wrote at the same time , so you answered my question before I posted it !!! What you said made complete sense! Thanks!
entropy1980 said:
[...]so you answered my question before I posted it !!! [...]
Click to expand...
Click to collapse
I installed the phpBB telepathy mod a couple of days ago, so I guess it's working.
Hey I knew you were going to say that.... :lol: :lol:
hi,
i want to add the skelmir java virtual machine (thats default installed in windows\ceej) and copy the swingall.jar in the windows\ceej map.
I have the cab file of the virtual machine but i can't find out which files are in it (when i open it with cabextract is shows .001 files and not the files that i find back in the device)
please help me
Using Special Edition ROM, Tthe CabInst tool will run CAB files on the device if you move it there manually and double-tap it. It allows to set a new directory to install in.
Also the System Snapshot tool will write a file in the root of the device which holds a list of the entire filesystem and registry contents, so you can compare and see what changed. UltraEdit for the desktop has a compare function.
Good luck...
hi,
i installed it to a seperate directory and zipped the files. i also took a snapshot when the xda was fresh and after install. i only can't find where the xda's gets is files from in:
43 <! [\Windows\AppMgr]
8544 <! 31/12/2002 12:31 1632 FC0E9EE1 Skelmir CEEJ Virtual Machine.DAT
8576 <! 16/02/2003 23:10 27 AEBB1DF3 CEEJ.lnk
8587 <! 16/02/2003 23:10 40 1EAF4EB3 CEEJ Examples.lnk
8588 <! 16/02/2003 23:10 27 AEBB1DF3 CEEJ.lnk
because these are not in the map where i extracted the cab file too. maybe you can take a look for me and tell me what i have to change in mkrom to have ceej by default installed
the extraced cab map:
http://www.devosjansen.nl/xda/java installed.rar
the snapfiles:
http://www.devosjansen.nl/xda/xda snapshots files.rar
thanks in advance
laurens0619 said:
hi,
i installed it to a seperate directory and zipped the files. i also took a snapshot when the xda was fresh and after install. i only can't find where the xda's gets is files from in:
43 <! [\Windows\AppMgr]
Click to expand...
Click to collapse
These files are generated during the install process, and contain uninstall information. You do not need to write them if you install in ROM, since you don't need/want your programs to show up the in the 'Add/Remove Programs' dialogue.
ah i understand,
so i just put the files in the files1 or files2 directory and add this reg files to the default.reg? i dony really understand the readme file
ah little kick,
isn't also good for the next SE rom? because you have finally a java virtual machine on the xda and the app is freeware (got it from www.skelmir.com)
laurens0619 said:
isn't also good for the next SE rom?
Click to expand...
Click to collapse
Noted...
nice but can you please help me out for the moment? i dont know which part i must add to the default.reg file
laurens0619 said:
I dont know which part i must add to the default.reg file
Click to expand...
Click to collapse
default.reg holds the registry that is present when the system wakes up from cold-boot. So any registry entries your installer (or first run of the app) has made that you would like to have present should go in there. Clear enough?
almost
so i just copy paste the **** at the end of the reg file? and the files in the files 2 map
but how will the rom know where to put the files??
sorry if i'm stupid but i don't want to f*ck my rom so i can use me xda's as a frisbee
Yes, the registry entries can be pasted at the end of default.reg. It doesn't matter if there's earlier entries with the same values, since the latter ones override.
All files in files1 and files2 will end up in \Windows, and if you want them somewhere else, (where they'll take up RAM), you must manually copy them (or pre-made links pointing to them) by issueing commands in initobj.txt.
Take a real close look at initobj.txt, and you'll get the picture.

A tutor to write simple 'batch' script (cab)?

Hello,
I am going to write a simple script, which I am going to launch on my smartphone. This script will do some easy operations:
- copy some files from card to phone (even with 'hidden' attribute)
- modify some keys/variables in registry
- add spme keys/variables into registry
Would you tell me please where I can find a tutor to make such cab files?
Thanks in advance
best greetings!
RA
Mortscript
Looks nice, but...
joemanb said:
Mortscript
Click to expand...
Click to collapse
Thanks for your answer! But please tell me, is it the tool with they make all 'cab' files with '_setup.xml' inside? How they do such cab-s?
RA

Developing a WM 6.5 titanium plugin

I've looked far and wide for a plugin that allows me to control Coreplayer like you can with WMP in the titanium homescreen. Well, I've given up and decided to make one by myself. What do you use to make plugins like this? What language?
I would also like to know about this
Im not a master on the rules, but shouldnt this be in Q&A?
Anyway, you want:
Plugin Installer
Tool to create the plg files for the above
(I havent tried them myself, but i understand its the easiest way)
That will modify the "cpr file" (an xml file that the chome reads for the layout) for you. Then, you just need to modify the relevant registry entries, like HKLM\Software\Microsoft\CHome\YOURPLUGIN\Page 1\TEXT1 = "Now playing: ..."
Thus, you can use any language for this: Mortscript, c#, basic4ppc, etc.
Yes - in Q&A -you will also find a sticky thread: http://forum.xda-developers.com/showthread.php?t=504324 - which will help you - especially the link to http://forum.xda-developers.com/showpost.php?p=3601164&postcount=2 is a good place to start (you must know what the GUID for custom plugins is)
And therefore, that you don't need long scripts - I would take MortScript - only if you need Processes, I would take C++ or so
I will download your Plugin - looking forward to
Micha

[HELP] How to register a dll?

I try to create a program which consists of
.asx files (to show online tv channels),
.lnk files (shorcuts to the .asx files) and
a .dll file which contains only some .ico files (icons of the tv channels).
I added all these files to a cab using WinCE Cab Manager and tried to install it on my ppc. So far so good. The problem occurred when the message “The program can not be installed. Choose another location” appeared during installation, just after the process bar was filled.
Although I have no idea about computer programming, I have created many cab’s with WinCE Cab Manager for skins I have created for several programs. Anyway, I realized that the problem occurred due to the .dll file, since this is the first time I add such a file in a .cab.
I created my .dll file using a .dll from another program which had only icons in it, as well. I deleted them using Restorator 2007 and I had an “empty” .dll sized 4KB. Then I added my icon files using XN Resource Editor.
I searched the Internet to see what might be the problem with the .dll and I found out that I have to “register” my .dll file. I really have no idea what this means but it needs to be done. I also found an option in WinCE Cab Manager for “self-registering” file, but it didn’t work either.
So, the question to you dev guys is how can I register my .dll file, or should I create it from the beginning with another way?
Please help! Thanks in advance!
sorry to repost but it seems that posts keep coming in this forum and this thread is already in the second page and I'm afraid that noone will see it and reply to it. By the way, is there any special sub-forum for such questions?
This may help. I use his instructions to edit existing DLL's
http://www.modaco.com/content/i9x0-...88904/lisbian-taskbars-for-i910/#entry1023568
It will unsign the dll which will probably fail on your custom dll but it should sign it when you are done editing.
NilsP
Many thanks for your suggestion but unfortunately it didn't work for me.
As you said, this is mainly for resigning already signed .dll files.
Any other help will be appreciated. I can attach it here if anypne is willing to help. Or just tell me the way. Thanks!
I deploy a few dll's with my app, without any problem. If the installer complains about the location, what did you specify where it should go?
There are 2 approaches to solve this problem:
1.) If you have a private key to match a certificate in the device's certificate store, sign the .dll and .cab with this private key and it will be installed with elevated privledges, and be successful. To facilitate this you can install the "SDK Certificates" - and sign with the matching private key (you should be able to find these on a search, term "SDKCerts" or similar)
2.) Look for an "Application Unlocker" or other security reduction tool, run it, and you should be able to install the cab. On this note, if you check here, it will give you a more technical overview of the security policies. You want to change 4101 / 0x1005 to "SECROLE_MANAGER" (8) - which tells the system to install it with elevated privledges. Also make sure 4102 / 0x1006 is set to 1 to allow unsigned applications.
6Fg8
I don't believe that is the location I specified that causes the problem because when I deleted the .dll file from the .cab, it was installed properly. How do you create your dll files? With programming or you just edit existing files? If I send you my .ico files, will you be able to create the .dll file for me?
Da_G
Thanks but both approaches seem very complicated for me!
So, will I need Visual Basic in order to do this or is there any easier way? Can anyone sign the dll for me?
angelos_cy said:
6Fg8
How do you create your dll files? With programming or you just edit existing files? If I send you my .ico files, will you be able to create the .dll file for me?
Click to expand...
Click to collapse
Yes with programming, C++ or .net. Never had any issue with signing. I can try to make a dll if you send me the icons (or post them here if they aren't too secret ).
6Fg8 said:
I can try to make a dll if you send me the icons (or post them here if they aren't too secret ).
Click to expand...
Click to collapse
I have sent them to you by pm. They are not secret at all but I will create a "program" (wannabe ) with that dll and I want that program to be a surprise for users of the forum where I'll post it. I may post it on xda too, but it's nothing important.
Many thanks!
angelos_cy said:
The problem occurred when the message “The program can not be installed. Choose another location” appeared during installation, just after the process bar was filled.
Click to expand...
Click to collapse
This happens because you've changed resources in signed file, which changed file checksum and invalidated it's signature, and Windows installer refuses to install file with invalid signature. But it won't refuse to install this file WITHOUT signature at all - so use unsigner (search for it on XDA) to remove signature completely; if you encounter error, try to remove signature from original (unmodified) file, and then change resources in it...
6Fg8
the_ozyrys
Thanks to both of you!
6Fg8 has created and signed the dll for me and it finally worked, but I also tried the_ozyrys' method and it also worked.
So thanks to baniaczek too, since he created the unsigner.exe.
Everything worked fine with the dll. Now the cab is installed properly.
However, I have another problem. Just after the installation of the cab on my ppc, it seems that the device freezes for about a minute. This is propably because my cab contains a lot of shortcuts (.lnk files) that go under Programs folder.
So, I would like to ask for another favour, if it's possible. As I said I intend to give this cab to others too. Since this delay can make them believe that my program has freezed their device, I would like to make the cab restart the device just after installation and after uninstallation as well. I think this is made with the "Setup.dll" which I don't know how to create.
If anyone knows how to do this and has the time for it, could you please create this setup.dll for me. If the cab is needed to do this, just tell me to send it to you.
Thanks in advance!
Anyone? Plzzzzzzz!
If you want to sign .dll or .exe u can use the apps posted in the two posts below
http://forum.xda-developers.com/showthread.php?t=432041
or
http://forum.xda-developers.com/showpost.php?p=3530246&postcount=18
raykisi
Thanks for your answer but 6Fg8 and the_ozyrys already helped me on that.
My question now is how to create a setup.dll in order to make my .cab to prompt the user to restart the device after installation and uninstallation. If anyone can do it for me, I can send you the .cab which I alreday created and you can add the setup.dll with those functions.

[UDL] Make NotePad++ MortScript ready

Created an user defined language (UDL) for NotePad++, my favorite editor, thus MortScript-scripts are synthax conformally shown. Uploaded the UDL here. Enjoy.
already exist a Mortscript UDL with autocompletition file for mortscript...
Does your version will be better ?
Re
@lesscro,
already exist a Mortscript UDL with autocompletition file for mortscript...
Click to expand...
Click to collapse
Do not know of such an UDL, also such one is not listet here.
Does your version will be better ?
Click to expand...
Click to collapse
Try it out.
I had found two files for use with MortScript in Notepad++ and tweaked them a little for myself. One goes in the Notepad++ folder and is the user defined language file. The other goes in Notepad++\plugins\APIs and is the function and description file.
RoryB said:
I had found two files for use with MortScript in Notepad++ and tweaked them a little for myself. One goes in the Notepad++ folder and is the user defined language file. The other goes in Notepad++\plugins\APIs and is the function and description file.
Click to expand...
Click to collapse
Excellent, thanks!
thx a lot.
long live, WM!
Code dictionaries
Hiyas.
btw, I did previously post a Notepad++ dictionary from Sir.John in the Mortscript Source Compendium.
I will update with a link back to your thread also.
Link broken - file not found
Thanks for taking the time to do this, and so many of your other projects
Any chance you can re-post the UDL for Mortscript again?
Cheers from Australia
Spin35

Categories

Resources