hi,
I need to create a shortcut to a file or folder using eVC++ 4.0, anybody knows how to do this??
Thaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaanx alot
Mohammad
It's very easy:
Just create a file (with lnk extension)
and write to it:
10#"my_app.exe" -launch
this is what it means:
10 - length of the string after #. This value doesn't have to be accurate because it is usually ignored.
"my_app.exe" - path and name of the target of the shortcut.
-launch - command line parameters (if you have any)
You can also add: ?incon.exe,0 to take an icon from another exe / dll
Thaaaaaaaaaaaaaaank you very very much,
but I need a small thing, could you please provide me with a complex example so I can understand all features supported for shortcuts.
Thank you again,
Mohammad
Mo.
A number of us have posted about the structure of the .lnk file.
Search against my username for the word completeness.
V
now, I searched and got how the thing works, but I have a problem with coding this stuff:
When I attemp to write to shortcut file like this:
strData.Format(_T("%d#\"%s\""),strFilename.GetLength(), element.strPathname);
ShortcutFile.Write(strData,strData.GetLength()*2);
The file is not written correctly, what I get is the data I wrote in the file with a square charecter after each letter like this:
#□4□0□"□\□S□t□o□r□a□g□e□ □C□a□r□d□\□M□y□P□r□o□g□r□a□m□.□E□x□e□"□
so how can I solve this? and does it relate to unicode?
That's because you are trying to write it in UNICODE. This adds zero to every byte.
You must use fopen, fprintf, fclose functions or just create an array of char and use FileWrite to create an ASCII text file.
Thanks levenum,
but isn't windows ce file system unicode based? if so, how can I use ASCII format to write unicode filenames?
Thanks alot
Mohammad
#include <Oleauto.h>
......
char convertUshortToChar(unsigned short in)
{
char con='\0';
VarI1FromUI2(in,&con);
return con;
}
and add Oleaut32.lib to the list of object/library moduals in you project settings.
just call that for each unicode character that you want to be ascii and write the result to file.
Two things:
a) The file system may be UNICODE, but shortcuts are ASCII text. Also ASCII functions like fopen are supported.
b) There is a much easier way to convert UNICODE to ASCII:
mbstowcs(unicodeStrBuffer, asciiStrBuffer);
OK, I did it, but I think that there is a problem with Windows mobile, and it is a big problem.
Till now, I beleive that you cannot create a shortcut to a unicode-named file, I failed to do that, File explorer was not successful, Resco Explorer was not better.
Worse, they do not tell you that you cant create the shortcut, they create the shortcut for you and when you try to open it they conclude that the path was not found!!.
Very bad huh?
Mohammad
I thought that all file names are in unicode?? Use my shortcut creator in GSMbeam file open dialog to try and make a shortcut to a file named like you said. If that shortcut dose not work send me the file in question and I will try and see whats going on.
Ok, I downloaded your program and tried to create a shortcut for an arabic-named file, simply it did not work.
I know its not a bug in ur program, its a bug in Windows Mobile, it is mainly a bug in the design itself, how does Micro$oft design windows mobile to be unicode based while non-ascii characters are not supported in the shell links, its really a shame.
You can be sure that this will happen with asian characters along with Farsi, Hebrew, Arabic and all non-ascii characters.
Programmatically, what happens is as follows:
1. A program converts a filename from unicode to ASCII to save it in the .lnk file.
2. If the file name contains non-ASCII characters, those will be converted to NULL character.
3. When the shell tries to resolve the link target it does not recognise the filename because some characters are NULL.
Thats what I found out!!
Take this file name for example (Arabic): 2مرحبا.mp3
Try to solve the issue, and please inform us whatever happens with you..
Best Regards,
Mohammad
So the problem is how to get the shell to read unicode in lnk files. I re-wrote a lnk file in unicode to see if it would work but it would not. There are a lot of non english ppc users, surely this problem has come up before?
As an experiment I also made shortcut to a folder using utf-8, I think that contains arabic characters and also the ascii characters. After removing some garbage that my editor put at the front of the lnk file worked fine. Try making a shortcut in notepad and saving it as a utf-8 file then rename it on your device but make sure there is no extra characters.
أنا قادر على أكل الزجاج و هذا لا يؤلمني. -- I think those characters are arabic and they are copied of a utf-8 table site so if the shell can read a utf-8 lnk that contains english letters then maybe it can do the arabic too.
Actually, non English UNICODE characters are translated in to extended ASCII codes (128 - 255). When the system needs to translate these codes back to UNICODE it relies on code page definitions in the wince.nls file.
If your locale is properly set to Arabic and you have a valid nls installed (ether you have Arabic ROM or some sort of Arabic language support installed) you should be able to reference Arabic file names using ASCII links.
So, can I depend on string conversion functions we discussed before in this topic to convert characters according to my code page?
I have an arabic ROM installed on my Wizard, it is the i-mate rom on O2 device, so the arabizer doesnt work well, may be because the serial number of the O2 device.
Anyway, I should invistigate this issue on my friend's JamIn device, and we should come up with a workaround for this wiered problem.
Regards all,
Mohammad
OK,
I have tried creating a shortcut on my friend's arabic-enabled JamIn device, the shortcut refers to arabic-named file and it worked good.
levenum, you are right, it depends on the code page on each device, so your device will not be able to create a shortcut to an arabic named file.
Mohammad
Related
In www.qtek.fi there is some kind of script/program to change Universal's sym-button's character order. Unfortunately to download it you need Qtek 9000's IMEI (I have I-mate Jasjar).
Does someone here to know where these character arrays are stored and how to change the order so that 'ä' would be first character when 'sym' is pressed after 'a' (default is 4th press) and 'ö' first ch after 'o' (default is 5th press)?
Thanks in advance,
Antti R.
Hello araappa,
you have to edit the file "sym.txt" in your \windows folder. There you can change and/or add any character.
Greetings,
Hulzer
Thanks for your reply Hulzer,
After your answer it actually comes to my mind, that I earlierly did find that file, but I could not edit it since it's located in ROM. That makes the situation very same as in my other post concerning how to change voicbeep.wav file.
So the files are in \windows folder and are rom-files. But where are they, in extended or some other rom section (I'm not familiar with JJs memory structure), and which tool/unlocker I should use to get full access to these files?
Best regards, Antti
Hi,
I didn't change or unlock something with the ROM.
1. Copy the file to your desktop pc
2. Make your changes
3. Copy it back to your device
The file will be mirrored - you cannot overwrite it on your device directly. You have to copy it before. The origin file remains. But the new one will be stored in RAM. This one will be used.
For me it works fine!
Just try it like me.
character order
Hi!
I'm having the same problem although I've got a Samsung SGH-I750 with 2003SE.
I changed the sym.txt but nothing happened. I want to enter text with the phone's keypad but there is a lot of "unwanted" characters for example on button "2" like: à, å, æ, ç, ä
I've heard about changing the HKLM/T9InputMethod, but there is no directory like this.
Thanks for help
The trick is the sym.txt file in your device's windows folder. It defines the order how characters are changed when sym-button is pressed.
File is located in ROM, so you can not edit it directly. But you can first copy it to your PC, and edit there. You can change order, or add any new characters. I added for example euro symbol behind e letter. Use notepad for editing.
Then copy edited file back to device windows folder. Copy of the sym.txt file will actually be created to RAM memory, and after soft-reboot it picks up the edited one.
Cheers from Finland!
/Tuomo
Qtek 9100
Wow...great tip. I blog by e-mail and it has always bothered me that < and > required so many keypresses! Much better now.
Thanks.
Tattis,
I have nordic keyboard (and driver for our chars), but would like to update ROM so, this might be very handy.
Great tip! Glad I read your post even though I'm not scandinavian. It applies to all languages!
I've seen that many apps comes with AppName.0409.mui installed in the same folder of the app, usually \Windows.
For who don't have an english OS, usually miss app dialog box string.
I've seen that if u want to have back dialog box string u have to make a copy of AppName.0409.mui and reneme it into AppName.xxxx.mui where xxxx is your contry code (for me, italian, 0410).
But how to have dialog box string in native language?
I've tried with a recent app extracted from touch dual (Action Screen) which have a mui file with only one string. I've used Resource Hack, changed the string, compiled and saved. But... nothing.
In second instance i've changed not only the string but also the language code, compiled, saved and...
So can someone who is skilled make a tutorial for changing app strings?
Sorry for my bad english and thanks in advance for reply.
P.S.: i've read this http://forum.xda-developers.com/showthread.php?t=311078 and also this http://forum.xda-developers.com/showthread.php?t=307968 but talking about rom, not apps...
I do it like this:
1. Copy the program's executable file to pc.
2. Open the exe with Resource Tuner. I delete all other folders exept Menu, Dialog and String(in these are all the strings for translation) and save the file.
3. Then I open it with resource hacker and push action -> save all recources
4. I open the generated rc file with notepad and replace all the:
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US(or maybe this is another language)
lines to:
LANGUAGE LANG_GREEK, 0x1 (this is for greek language)
and save the file.
5. After that I open the rc file again, but now with resource builder and I push tools -> Create resource-only dll and I save the file as name_of_file.exe.0408.mui(for greek).
6. Finally I open this file with resource hacker and I translate it
I used to do it in this way cause I have all these three progrs(resource hacker, resource tuner and resource builder)
Maybe there are other progs or ways but this works fine for me until now. If someone knows easier and faster methods I also want to know.
First, thanks for reply.
I was trying to make an easier thing... but maybe i can try this way for my scope.
I've installed HTC Action Screen, you can found it at: http://forum.xda-developers.com/showthread.php?t=336587
It's a cool launcher, nothing more. After installation i can find in \Windows folder two files:
HTCActionScreen.exe
HTCActionScreen.exe.0409.mui
Well in the mui there's only one string that is the top of the launcher screen, that i don't see. I've renamed 0409 into 0410 and now i see the string, the original one in english (some like that "Dial phone number or select a task below:").
I'd like to change in italian, so, i've used resource hacker ONLY for translate the string (as in your 6.) but... i don't see anything once again!!!
Any suggestion?
Have i to start from exe as in your reply?
Thanks again.
This is happens because you cannot change the LANGUAGE line with resource hacker. For this I save the resources in a rc file and adit it with notepad. I had similar problems with some muis that cannot translated before use the method that I described above. You only need resource builder to recompile the rc file to mui again. I don't now in what must change the Language line for Italian, but I think you can find out if you open an italian mui file.
So, i describe my step:
1) open HTCActionScreen.exe.0409.mui with Resource Hacker and and push action -> save all recources
2) open the .rc just created with notepad and changed LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US into LANGUAGE LANG_ITALIAN, SUBLANG_ITALIAN
3) open this .rc with resource builder and push tools -> Create resource-only dll and I save the file as HTCActionScreen.exe.0410.mui
4) open this file with resource hacker and translate it
it doesn't work
Where's my fault?
Maybe have i to sign the file?
Hi, i´m translating WM6.1 to Spanish, and to get full translation i have read there´s needed to get mxip_lang.vol and wince.nls spanish version.
For WM6 it can be dumped from Emulator Image, but there´s no image for WM6.1 still. Will work the WM6 files for WM6.1?, can i edit this files to translate them with any tool?
There are another files within the .mui´s and registry i have to edit to get a full translation?.
Thanks.
up... nobody knows nothing about those files or how to translate Start Button in a WM6.1 ROM?
I have translate the initflashfiles.dat and the necesary registry keys, but when my ROM boot it hang up at last boot screen and shows only the upper program bar. why?
Thanks
you was forget to add what device you try to translate
if you don't have SDK wm 6.1, the best way is take language from other device
lazaj007 said:
you was forget to add what device you try to translate
if you don't have SDK wm 6.1, the best way is take language from other device
Click to expand...
Click to collapse
I´m trying to translate WM6.1 for Trinity, the mui´s is not a problem, i got it´s from others devices ROMs, but the problems comes when i translate programs files and startup folders in initflashfiles.dat.
Thanks.
With Sktools you can export metabases mxip_lang.vol into .xml files . Also AKtools has import function. But I don't understand how it is work. I tried insert some new rows in metabase but sktools say: 0 records imported. May be anybody know how to import new record in metabase with sktools? Please, help me!
I successfully translate mxip_lang.vol !!! I used Sktools for dump this file. After that I translated all english records in to russian ( text file in unicode format). Then I have put DevPrepSP.exe utility ( with its configuration .xml file) and my .txt file in \Storage\MUI\ folder on my Qtek8310. I have started the DevPrepSP.exe and have added records in to mxip_lang.vol. It has worked!!!
My txt file has such format of records:
\MetabaseLabels
0#19#1;1049#31#Размер сист. шрифта:;
0#19#2;1049#31#Время нажатия:;
0#19#3;1049#31#Макет начального экрана:;
.................................................. ... ;
Where to find that
olad said:
I successfully translate mxip_lang.vol !!! I used Sktools for dump this file. After that I translated all english records in to russian ( text file in unicode format). Then I have put DevPrepSP.exe utility ( with its configuration .xml file) and my .txt file in \Storage\MUI\ folder on my Qtek8310. I have started the DevPrepSP.exe and have added records in to mxip_lang.vol. It has worked!!!
My txt file has such format of records:
\MetabaseLabels
0#19#1;1049#31#Размер сист. шрифта:;
0#19#2;1049#31#Время нажатия:;
0#19#3;1049#31#Макет начального экрана:;
.................................................. ... ;
Click to expand...
Click to collapse
Hi there,
Where I can find Sktools?
With my regards,
I have created small utility Called VipRegExport.
Requirement : .netCF 2.0 higher
What Utility Do
It reads input ini file and create registry export per section for every values in that section. It saves registry in .reg file.
Sample ini file
# Secion name will file name to be export registry values in it
# this is how you can comments
[MyKeys]
F01=HKLM\Software\Microsoft\Shell\Keys
F02=HKCU\Software\Microsoft\Today\Keys
#Setting for all third party software
[MySoftware]
F03=HKCU\Software\HButton
F04=HKCU\Software\waku
F05=HKEY_CURRENT_USER\Software\TodayAgenda
F06=HKEY_CURRENT_USER\Software\pocketMax
F07=HKEY_CURRENT_USER\Software\AlenSoft
F08=HKCU\Software\Microsoft\Shell\TaskSwitch
F09=HKLM\Software\ThrottleLauncher
F10=HKEY_CURRENT_USER\Software\Parlingo
F11=HKEY_CURRENT_USER\Software\Mort
F12=HKEY_CURRENT_USER\Software\Ghisler
F13=HKEY_CURRENT_USER\Software\FdcSoft
F14=HKEY_CURRENT_USER\Software\CallCalendar2
F15=HKEY_LOCAL_MACHINE\SOFTWARE\SHEALD
F16=HKLM\Software\HTC\HTCHome\Weather\Settings
F17=HKEY_LOCAL_MACHINE\Software\Pointui
F18=HKEY_LOCAL_MACHINE\Software\WiFiFoFum
F19=HKLM\Software\Apps\VicSoft ClearTemp
F20=HKEY_LOCAL_MACHINE\Software\Saman
[MyExtention]
F21=HKEY_CLASSES_ROOT\.mscr
F22=HKEY_CLASSES_ROOT\.mortrun
F23=HKEY_CLASSES_ROOT\MortScript
F24=HKEY_CLASSES_ROOT\.mbi
F25=HKEY_CLASSES_ROOT\MortButtonInfo
F26=HKEY_CLASSES_ROOT\.reg
F27=HKEY_CLASSES_ROOT\regfile
F28=HKEY_CLASSES_ROOT\.pdf
F29=HKEY_CLASSES_ROOT\AdobeReaderLE.2
[MySetting]
S01=HKLM\Software\Softick\Card Export\RunTrayClientAtStartup
S02=HKLM\Software\HTC\PHONE\BatteryIconLevel
S03=HKLM\Software\HTC\PHONE\bShowBatteryIcon
S04=HKCU\Software\Microsoft\Internet Explorer\Main\Default storage location\All Files
S05=HKCR\SystemFileAssociations\image\shell\save\Save Location\Default
S06=HKCR\SystemFileAssociations\audio\shell\save\Save Location\Default
S07=HKCR\SystemFileAssociations\video\shell\save\Save Location\Default
S08=HKCU\Software\HTC\Camera\4.00\Strings\Save Location
S09=HKLM\Software\HTC\Camera\General\EnableDCIM
S10=HKLM\Software\HTC\SUPL AGPS\EnableAGPS\Assisted GPS
S11=HKLM\Software\HTC\SUPL AGPS\EnableAGPS
S12=HKCU\ControlPanel\Phone\ShowSIM
S13=HKEY_CURRENT_USER\ControlPanel\BackLight\QKeyLedTimeout
S14=HKLM\Software\OEM\Power\ShowMovingChargeBar
S15=HKCU\ControlPanel\Sounds\RingTone0\Sound
S16=HKCU\ControlPanel\Sounds\RingTone0\script
S17=HKCU\ControlPanel\Sounds\RingTone0\Category
S18=HKLM\Security\Policies\Policies\0000101a
S19=HKLM\Software\Microsoft\Shell\ShowTitleBarClock
S20=HKCU\Software\Microsoft\Today\Skin
S21=HKCU\ControlPanel\Keybd\DefaultKeyLock
S22=HKLM\Software\HTC\HTCHome\TabSetting
Click to expand...
Click to collapse
There are three command line arguments supported
argument 1 : <inifilename including path> if not given then default is VipRegExport.ini
argument 2 : <Output Folder name including path> If not given default Application Folder
argument 3 : <slient Option> Default is 'N'. If you want to run in slient option then pass third parameter as "Slient"
What is slient option : It will not display any error message like "Registry key does not exist to export" and exit application after export completes.
GUI also gives ability to select input file as well output Folder.
HKEY_LOCAL_MACHINE\Security\Policies\Policies\000010a will export just one key 0000101a in HKEY_LOCAL_MACHINE\Security\Policies\Policies
where as F03=HKEY_CURRENT_USER\Software\HButton will export all keys and subkeys under that registry.
Basically if you want to export full registry including all subkeys and values then put actual key name in value If you only want to just export single keyvalue in specific registry then put keyname\valuename.
It also support HKCU, HKLM, HKCR, HKUS formats as well.
Restriction : Currently export can not export some new registry type like reg_multi_size etc but so far none of my registry values that I needed to export are of those type they mostly String, int, and binary value they all are supported.
Above restriction is removed. Now utility support all types of Registry. Credit Goes to Elemris craetor Kheb. ELemris Thank for helping me out on and sharing your code.
Uploaded new version
Now you can export entire registry with below in INI file
[MyFULLRegistry]
F01=HKLM
F02=HKCU
F03=HKCR
Version 8.0
Fixed "\" in key reported in post # 10
Version 9.0
Quick Fixed "@" in key http://forum.xda-developers.com/showpost.php?p=8347552&postcount=10
If you like my work then please consider donating
FAQ:
Do we need to put F01, F02..... what's happening if I have 2 F01?
F01, F01, F03 is just key in ini File It is not used any where in Program but it is needed in ini file as they are part of ini like section , key and value
Posted Version 4.0
Posted Version 4.0
posted new version 6.0.
Completely working. no restriction any more.
Interesting, thanks.
just one question, then.
So using:
[MyKeys]
F01=HKLM
F02=HKCU
F03=HKCR
will make complete registry dump? in one file?
I wouldn't ask, but i just cannot test it at this moment..
Can not export all reg's at present but i will include in next version
pupakota said:
Interesting, thanks.
just one question, then.
So using:
[MyKeys]
F01=HKLM
F02=HKCU
F03=HKCR
will make complete registry dump? in one file?
I wouldn't ask, but i just cannot test it at this moment..
Click to expand...
Click to collapse
New version can export entire registry
Strange,
F50=HKEY_LOCAL_MACHINE\SOFTWARE\HTC\Manila\Configuration
returns an empty key
I have a question:
Do we need to put F01, F02..... what's happening if I have 2 F01?
F01, F01, F03 are basic part if inin and they are needed.
romualdrichard said:
Strange,
F50=HKEY_LOCAL_MACHINE\SOFTWARE\HTC\Manila\Configuration
returns an empty key
I have a question:
Do we need to put F01, F02..... what's happening if I have 2 F01?
Click to expand...
Click to collapse
F01, F01, F03 is just key in ini File It is not used any where in Program but it is needed in ini file as they are part of ini like section , key and value
F50=HKEY_LOCAL_MACHINE\SOFTWARE\HTC\Manila\Configu ration
Click to expand...
Click to collapse
notice that space between configu
and
ration
here.
Tipo here only. I found that it tries to write this key but I have:
[HKEY_LOCAL_MACHINE\SOFTWARE\HTC\Manila] instead and empty.
Maybe the key is locked or something like that.
\\ are not written correctly I think in name of keys?
I tried to backup F10=HKEY_CURRENT_USER\Software\FdcSoft (pimBackup settings) and found that the custom list (folders list) does not have \
I have "\Windows\Rings\*.*"=dword:00000001 in the backup reg
But after, in the reg I have WindowsRings*.*
Looks like, the import (from sktools) needs \\ to save \...
Actuly it was fixed in version 7.5 but i did not released it.
It is now fixed in new version 8.0
Hi,
May be a good option would be to have an information in the .ini to set the export directory when you load the ini.
romualdrichard said:
Hi,
May be a good option would be to have an information in the .ini to set the export directory when you load the ini.
Click to expand...
Click to collapse
I will add in next version. Right now planning to add WAP export e.g emails setting, wi-fi setting etc exported to xml
Hi v3patel,
stuff like this must be a sticky, because it helps us devs a little bit. Ok there are more other things, but not based on a ini file. With that and mort i have done now two tests and they look really good. I hope you will support it further. And when i read your last post (top on my one) then it is very interesting. Thank you for sharing with us...