on Wed, 16 Jun 2004 [EMAIL PROTECTED] wrote: > Hi, > I have a Problem ... for school i have to write a > little program wich > translates a normal text into a text written with > the morse codes !
Interesting assignment! I'm a teacher too. Is this part of a high school computer programming course using MetaCard or a general course on computers? I'll to read the webpages of your teacher about this course! Could you post a web address? > I have started but i am stuck at the point that > metacard only translates one single > letter .... it's really frustrating i have beening > trying out everything for > about 5 days now.... ! (i am using MetaCard for 4 > weeks now!) I think that you must download the MetaTalk Programming course: http://www.metacard.com/pi6.html > I think i have > to make some sort of repeat loop so that metacard > checks every word and then Here is the error, you must be checking every character, not every word... > puts the morse cord in for each word and doesn'T > just put in the code for > the last letter...PLEASE help me !! I am loosing > hope that its even possible > ....here's my Script sofar ... (only got the letters > a;b;c cause no �onit of > doing every letter if the first three ain'T working > ! > > on mouseUp > put empty into field "morsetext" > put empty into field "standardtext" > ask "What would you like to translate?? Was h�tten > Sie gern �bersetzt ??" change to: answer file "What text file would you like to translate? > if it is not empty then > set the cursor to watch > put it into field "standardtext" > put "it" into field "morsetext" delete this line: put "it" into field "morsetext" > put it into filecontent > repeat for each word w in filecontent Change to: repeat for each char w in filecontent > if "a" is in field "standardtext" then change to: if w = "a" then put ".- /" after field "morsetext" Notice, this is only one line, not three lines. Repeat this line for every letter or character that you want to translate to morse. > put ".- /" into field "morsetext" > end if > if "b" is in field "standardtext" then > put "-... /" into field "morsetext" > end if > if "c" is in field "standardtext" then > put "-.-. /" into field "morsetext" > end if > end repeat > answer "There you go! Bitte Sch�n!" > end if > end mouseUp > > Thank You alot ...greets theo !! You are welcome! al ===== Visit my site: http://www.geocities.com/capellan2000/ Search the mail list: http://mindlube.com/cgi-bin/search-use-rev.cgi __________________________________ Do you Yahoo!? Yahoo! Mail is new and improved - Check it out! http://promotions.yahoo.com/new_mail _______________________________________________ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
