I am a newbie started learning S60 a few weeks ago, and now I need to build a very simple "algebra test" application by modifying the "helloworldbasic" application that comes with N97 SDK.
I'm not asking for someone to build the whole application for me - I just need some guides since I got stuck. My objective is to display a dialog showing a random statement (e.g. 2+4=?) containing two 1-digit numbers, ask for user input, then display on screen whether the answer is right or wrong.
I have read some Nokia API documents e.g. S60 application framework handbook etc., and I have figured out how to display a dialog and ask for numeric input. My problems are:
- How to generate random numbers to be displayed in the dialog? I know to use Math::Random() % 10 to make random 1-digit numbers, but I couldn't figure out a way to put the numbers into a string and display it on the dialog.
- Where should I put the declarations of the strings and numbers? The .rss, .rls, or in the HandleCommandL function in UI file?
- How can I display a string on the screen after user clicks "OK"? Where should I put the string, and which function should I call to display it on screen?
- Can someone help me by explaining how the resource files and the UI file (***appui.cpp) work together? I really don't understand how the variables defined in them are accessed by each other (I have been a Java programmer for many years, but this is totally new to me)
Any help on the points I mentioned is appreciated. Please note that this is supposed to be a very simple application, so make it simple :)