In SymbianProgramDuring development, many programmers may directly use "C: // resource/apps //***. A string such as MBM indicates the MBM file. The result is that the C drive can run normally only when the program is installed on the real machine, and the C drive cannot run normally after the program is installed on another drive letter. Therefore, a good practice is to dynamically obtain the MBM file name Based on the installation directory of the program.
BelowCode:
/* "***" Indicates your MBM name, the directory "// resource // apps //" corresponds to the relevant field */<br/> _ partition (kmbmfilename, "C: // resource // apps //***. MBM "); </P> <p> tbuf <64> mbmfile; <br/> mbmfile. copy (kmbmfilename); </P> <p> # ifndef _ wins __< br/>/* for a real machine */<br/> tfilename fullname = ceikonenv :: static ()-> eikappui ()-> application ()-> appfullname (); <br/> tint Pos = fullname. find (_ L (":"); <br/> mbmfile. replace (0, 1, fullname. left (POS); <br/> # endif