PhoneFinder--寻找丢失的手机

   手机丢了怎么办?那就打电话给手机,如果运气好的话,捡到的好心人能够把手机还给你。如果手机是被偷的,那就没有办法了,即使手机开着,估计小偷也不会接电话。当然,我们继续下面讨论的前提就是:手机是掉了,而且被好心人捡到,但是他不知道怎么还;或者是手机处在silent状态,你打电话人家听不到。Googlepage上有这么一个类似的应用,也叫PhoneFinder,不过这个软件是要收钱的。在windows mobile 6 SDK自带的例子中,有一个PhoneFinder的应用,通过它,你可以在手机上设置一定的信息,如果你通过SMS,发送这个信息到手机上,手机就会弹出提示框,显示主人的信息,同时播放一段声音,以引起注意。

    开发这样的应用程序,我们首先需要了解一下几方面的内容:

1.State and Notifications Broker API

2.Pocket Outlook Object Model Application Development for Windows Mobile-based Devices

3.MessageInterceptor

    在应用程序的主界面上,我们可以让用户输入信息内容,并且设置应用是否允许。这样,在设备接收到含有预先设定的短信之后,就会做出相应的动作,如弹出提示框,播放声音等等。其中,开启短信拦截的关键代码段如下:

interceptor =newMessageInterceptor(InterceptionAction.NotifyAndDelete);

interceptor.MessageCondition =newMessageCondition();

interceptor.MessageCondition.CaseSensitive =true;

interceptor.MessageCondition.ComparisonType =MessagePropertyComparisonType.Equal;

interceptor.MessageCondition.ComparisonValue = pin.Text;

interceptor.MessageCondition.Property =MessageProperty.Body;

interceptor.EnableApplicationLauncher(ruleName);

    

播放声音使用PlaySound方法,通过PInvoke得到:

#regionPlaySound

[System.Runtime.InteropServices.DllImport("coredll.dll")]

staticexternintPlaySound(stringpszSound,IntPtrhMod,intfdwSound);

constintSND_FILENAME = 0x20000;

constintSND_SYNC = 0x0;

constintSND_ASYNC = 0x1;

constintSND_LOOP = 0x8;

#endregion

    主人信息通过SystemState获得:

stringowner =SystemState.OwnerName;

stringemail =SystemState.OwnerEmail;

stringphone =SystemState.OwnerPhoneNumber;

    测试这个应用程序我们可以使用Device EmulatorCellular Emulator。首先,打开设备模拟器和蜂窝模拟器,并将它们建立联系,具体步骤参考《Ring Tone Manager on Windows Mobile》。然后将程序部署到设备进行调试。调试时,应用程序的主界面如下图1所示:

1:应用程序主界面

    在Pintext中设置好相应的文字以后,点击“Enabled”,启动短信拦截,然后点击左下方的Exit退出界面。这时候,我们在蜂窝模拟器里面给设备模拟器发送字符串“1234”,如下图2所示:

2:蜂窝模拟器中的SMS发送界面

    这时候,我们就可以在设备模拟器中看到相应的消息框,并听到声音了。如下图3所示:

3:设备模拟器中看到的提示消息框

参考链接:

GooglePhoneFinder

MSDN

1.State and Notifications Broker API

2.Pocket Outlook Object Model Application Development for Windows Mobile-based Devices

3.MessageInterceptor

35 Comments so far

  1. Hey. Speak when you are angry--and you will make the best speech you'll ever regret.

    I am from Congo and , too, and now am writing in English, give please true I wrote the following sentence: "Lamisil jock itch generic terbinafine product."



    Thanks :-). Watson.
  2. Hello. Go through your phone book, call people and ask them to drive you to the airport. The ones who will drive you are your true friends. The rest aren't bad people; they're just acquaintances.

    I am from Micronesia and , too, and now am writing in English, tell me right I wrote the following sentence: "Each flea that is on any one of your pets."



    With best wishes 8-), Ritter.
  3. Hi! RIJQcWWh
  4. Hi! uAtwPRcT http://nmjrzn.com/ <a href="http://cqhbfg.com/ ">VERjpVfX</a> VERjpVfX
  5. utzZwuVB <a href="http://www.telltalegames.com/forums/member.php?u=45643#5898 ">Cheap Xanax</a> <a href="http://community.xat.com/member.php?u=38942#5898 ">Cheap Phentermine</a> <a href="http://community.xat.com/member.php?u=38942#5898 ">Phentermine</a> <a href="http://community.xat.com/member.php?u=38946#5898 ">Diazepam</a> <a href="http://www.telltalegames.com/forums/member.php?u=45646#5898 ">Cheap Ativan</a>
  6. CtYePm <a href="http://www.qmsystems.com/tramadol.html#3416 ">Tramadol</a> <a href="http://www.carmafl.org/ambien.html#3416 ">Ambien</a> <a href="http://www.qmsystems.com/ambien.html#3416 ">Zolpidem</a> <a href="http://www.carmafl.org/ambien.html#3416 ">Cheap Ambien</a> <a href="http://www.carmafl.org/phentermine.html#3416 ">Buy Phentermine</a>
  7. eyurWL <a href="http://www.jaia-interactive.com/tamiflu.html#5063 ">Buy Tamiflu</a> <a href="http://www.jaia-interactive.com/tramadol.html#5063 ">Tramadol</a> <a href="http://www.jaia-interactive.com/ativan.html#5063 ">Buy Ativan</a> <a href="http://www.jaia-interactive.com/ativan.html#5063 ">Ativan</a> <a href="http://www.jaia-interactive.com/cialis.html#5063 ">Cialis</a>
  8. mlTjvl <a href="http://www.solidphp.com/forum/member.php?u=17163#6814 ">Diazepam</a> <a href="http://www.solidphp.com/forum/member.php?u=17166#6814 ">Cigarettes</a> <a href="http://www.ecometro.com/Community/members/RobertSmith.aspx#6814 ">Rolex Watches</a> <a href="http://www.solidphp.com/forum/member.php?u=17159#6814 ">Adipex</a> <a href="http://www.solidphp.com/forum/member.php?u=17159#6814 ">Buy Phentermine</a>
  9. PoZWwdZg <a href="http://www.ecometro.com/Community/members/PaulRandall.aspx#2296 ">Cheap Ambien</a> <a href="http://www.ecometro.com/Community/members/PaulClark.aspx#2296 ">Ativan</a> <a href="http://www.solidphp.com/forum/member.php?u=17164#2296 ">Ambien</a> <a href="http://www.ecometro.com/Community/members/JoseCope.aspx#2296 ">Xanax</a> <a href="http://www.solidphp.com/forum/member.php?u=17164#2296 ">Ambien</a>
  10. xXwtQFsB <a href="http://forums.caranddriver.com/member.php?u=30384#6506 ">Cigarettes</a> <a href="http://forums.caranddriver.com/member.php?u=30383#6506 ">Lorazepam</a> <a href="http://forums.caranddriver.com/member.php?u=30377#6506 ">Phentermine</a> <a href="http://forums.caranddriver.com/member.php?u=30379#6506 ">Tramadol</a> <a href="http://forums.caranddriver.com/member.php?u=30378#6506 ">Cialis</a>
  11. eNBrkLt <a href="http://jerryshamblin.com/valium.html#2669 ">Valium</a> <a href="http://jerryshamblin.com/ambien.html#2669 ">Buy Ambien</a> <a href="http://jerryshamblin.com/ambien.html#2669 ">Buy Ambien</a> <a href="http://jerryshamblin.com/tamiflu.html#2669 ">Cheap Tamiflu</a> <a href="http://jerryshamblin.com/xanax.html#2669 ">Xanax</a>
  12. QrAaQOwH <a href="http://www.intlgymnast.com/forum/member.php?u=4742#8888 ">Buy Cialis</a> <a href="http://gbxforums.gearboxsoftware.com/member.php?u=44500#8888 ">Xanax</a> <a href="http://gbxforums.gearboxsoftware.com/member.php?u=44503#8888 ">Ativan</a> <a href="http://www.intlgymnast.com/forum/member.php?u=4748#8888 ">Cigarettes</a> <a href="http://www.intlgymnast.com/forum/member.php?u=4746#8888 ">Zolpidem</a>
  13. dUmQoamq <a href="http://www.popdarlings.com/klonopin.html#2319 ">Cheap Klonopin</a> <a href="http://www.popdarlings.com/xanax.html#2319 ">Cheap Xanax</a> <a href="http://www.popdarlings.com/cialis.html#2319 ">Buy Cialis</a> <a href="http://www.popdarlings.com/klonopin.html#2319 ">Klonopin</a> <a href="http://www.popdarlings.com/xanax.html#2319 ">Alprazolam</a>
  14. rPSlqvrd <a href="http://forums.deskpro.com/member.php?u=2987#1188 ">Marlboro Cigarettes</a> <a href="http://forums.deskpro.com/member.php?u=2984#1188 ">Buy Valium</a> <a href="http://www.expertlaw.com/forums/member.php?u=104126#1188 ">Cialis</a> <a href="http://www.expertlaw.com/forums/member.php?u=104131#1188 ">Cheap Ambien</a> <a href="http://www.expertlaw.com/forums/member.php?u=104130#1188 ">Buy Valium</a>
  15. oCwEQs <a href="http://www.popdarlings.com/phentermine.html#4893 ">Adipex</a> <a href="http://www.popdarlings.com/ambien.html#4893 ">Ambien</a> <a href="http://www.popdarlings.com/cialis.html#4893 ">Buy Cialis</a> <a href="http://www.popdarlings.com/viagra.html#4893 ">Viagra</a> <a href="http://www.popdarlings.com/ambien.html#4893 ">Ambien</a>
  16. EOagWRn <a href="http://www.elysiumcache.com/ambien.html#9228 ">Buy Ambien</a> <a href="http://www.elysiumcache.com/xanax.html#9228 ">Xanax</a> <a href="http://www.elysiumcache.com/ativan.html#9228 ">Ativan</a> <a href="http://www.elysiumcache.com/#9228 ">Cheap Phentermine</a> <a href="http://www.elysiumcache.com/valium.html#9228 ">Valium</a> <a href="http://www.elysiumcache.com/tramadol.html#9228 ">Tramadol</a>
  17. qxuprBI <a href="http://www.etopautos.com/viagra.html#3321 ">Cheap viagra</a> <a href="http://www.johnuseed.com/#3321 ">Buy Viagra</a> <a href="http://www.etopautos.com/cialis.html#3321 ">Cialis</a> <a href="http://www.etopautos.com/#3321 ">Viagra</a> <a href="http://www.janefinchchurchcoalition.com/#3321 ">Buy Cialis Online</a>
  18. iTlNhA <a href="http://desertvista.org/valium.html#6264 ">Valium</a> <a href="http://www.sherrys50thbirthday.com/#6264 ">Viagra</a> <a href="http://desertvista.org/phentermine.html#6264 ">Phentermine</a> <a href="http://desertvista.org/ativan.html#6264 ">Ativan</a> <a href="http://desertvista.org/ambien.html#6264 ">Ambien</a> <a href="http://desertvista.org/#6264 ">Buy Xanax</a>
  19. DIIMIQ <a href="http://desertvista.org/ambien.html#9943 ">Cheap Ambien</a> <a href="http://desertvista.org/phentermine.html#9943 ">Cheap Phentermine</a> <a href="http://www.sherrys50thbirthday.com/#9943 ">Viagra</a> <a href="http://desertvista.org/valium.html#9943 ">Valium</a> <a href="http://desertvista.org/#9943 ">Xanax</a> <a href="http://desertvista.org/ativan.html#9943 ">Ativan</a>
  20. hmfjkVKh <a href="http://www.integration-worx.com/xanax.html#0520 ">Xanax</a> <a href="http://www.integration-worx.com/phentermine.html#0520 ">Buy Phentermine</a> <a href="http://www.casalomaliving.com/#0520 ">Buy Cialis Online</a> <a href="http://www.integration-worx.com/#0520 ">Ambien</a> <a href="http://www.integration-worx.com/valium.html#0520 ">Valium</a> <a href="http://www.integration-worx.com/ativan.html#0520 ">Cheap Ativan</a>
  21. YRvQjFK <a href="http://www.woodsidecahomes.com/ambien.html#1972 ">Ambien</a> <a href="http://www.neilemichaudcampground.com/#1972 ">Cheap viagra</a> <a href="http://www.woodsidecahomes.com/xanax.html#1972 ">Cheap Xanax</a> <a href="http://www.woodsidecahomes.com/#1972 ">Cheap Ativan</a> <a href="http://www.woodsidecahomes.com/valium.html#1972 ">Valium</a> <a href="http://www.woodsidecahomes.com/phentermine.html#1972 ">Phentermine</a>
  22. ztuiWv <a href="http://www.stoughtontheatre.com/cialis.html#4862 ">Cialis</a> <a href="http://www.batonrouge2007.org/#4862 ">Buy Viagra</a> <a href="http://www.sweetbleeders.com/#4862 ">Phentermine</a> <a href="http://www.pinkpineapplefl.com/#4862 ">Buy Cialis Online</a> <a href="http://www.stoughtontheatre.com/viagra.html#4862 ">Viagra</a> <a href="http://www.stoughtontheatre.com/#4862 ">Viagra</a>
  23. vyrjdcX <a href="http://www.radiokingproductions.com/b_xanax.html#1596 ">Cheap Xanax</a> <a href="http://www.radiokingproductions.com/b_viagra.html#1596 ">Viagra</a> <a href="http://www.radiokingproductions.com/b_ativan.html#1596 ">Ativan</a> <a href="http://www.radiokingproductions.com/ambien.html#1596 ">Ambien</a> <a href="http://www.radiokingproductions.com/b_valium.html#1596 ">Valium</a>
  24. sROtqGo <a href="http://www.rebeccaotero.com/klonopin.html#2152 ">Klonopin</a> <a href="http://www.rebeccaotero.com/ativan.html#2152 ">Buy Ativan</a> <a href="http://www.rebeccaotero.com/viagra.html#2152 ">Buy Viagra online</a> <a href="http://www.rebeccaotero.com/tramadol.html#2152 ">Tramadol</a> <a href="http://www.rebeccaotero.com/xanax.html#2152 ">Xanax</a>
  25. gHtvUgk <a href="http://www.rebeccaotero.com/klonopin.html#3913 ">Klonopin</a> <a href="http://www.rebeccaotero.com/valium.html#3913 ">Valium</a> <a href="http://www.rebeccaotero.com/xanax.html#3913 ">Cheap Xanax</a> <a href="http://www.rebeccaotero.com/tramadol.html#3913 ">Buy Tramadol</a> <a href="http://www.rebeccaotero.com/cialis.html#3913 ">Cheapest Cialis</a>
  26. YwddYtr <a href="http://www.kleinbrothaus.com/#2116 ">Cheap viagra</a> <a href="http://www.27thscvi.org/#2116 ">Cialis</a> <a href="http://www.anthonyblea.com/#2116 ">Cheap Ambien</a> <a href="http://www.aristagraphics.com/#2116 ">Xanax</a> <a href="http://www.charitydaw.com/#2116 ">Cheap Ativan</a> <a href="http://www.leapfroginstitute.org/#2116 ">Phentermine</a>
  27. KcthbGs <a href="http://www.pso-world.com/forums/member.php?u=62575#5196 ">Buy Valium</a> <a href="http://www.pso-world.com/forums/member.php?u=62570#5196 ">Viagra</a> <a href="http://www.pso-world.com/forums/member.php?u=62571#5196 ">Phentermine</a> <a href="http://www.pso-world.com/forums/member.php?u=62573#5196 ">Tramadol</a> <a href="http://www.pso-world.com/forums/member.php?u=62572#5196 ">Cialis</a>
  28. ZZWimU <a href="http://www.findmyhosting.com/forum/member.php?u=31#4986 ">Xanax</a> <a href="http://www.findmyhosting.com/forum/member.php?u=33#4986 ">Buy Ambien</a> <a href="http://www.findmyhosting.com/forum/member.php?u=28#4986 ">Buy Phentermine</a> <a href="http://www.findmyhosting.com/forum/member.php?u=27#4986 ">Buy Viagra online</a> <a href="http://www.findmyhosting.com/forum/member.php?u=30#4986 ">Tramadol</a>
  29. ObBnaHH <a href="http://djtechtools.com/forum/member.php?u=10989#7438 ">Buy Tramadol</a> <a href="http://djtechtools.com/forum/member.php?u=10991#7438 ">Xanax</a> <a href="http://djtechtools.com/forum/member.php?u=10985#7438 ">Buy Viagra</a> <a href="http://djtechtools.com/forum/member.php?u=10998#7438 ">Tag Heuer Watches</a> <a href="http://djtechtools.com/forum/member.php?u=10986#7438 ">Cheap Phentermine</a> <a href="http://djtechtools.com/forum/member.php?u=10996#7438 ">Cheap Ativan</a>
  30. YKPWxe <a href="http://samuelrutledge.com/valium.html#5980 ">Cheap Valium</a> <a href="http://samuelrutledge.com/#5980 ">Phentermine</a> <a href="http://samuelrutledge.com/xanax.html#5980 ">Cheap Xanax</a> <a href="http://samuelrutledge.com/ambien.html#5980 ">Buy Ambien</a> <a href="http://andnowforthegoodnews.com/#5980 ">Cialis</a> <a href="http://uufws.net/#5980 ">Cigarettes</a>
  31. FJNbNmt <a href="http://aidamexico.com/ambien.html#5577 ">Ambien</a> <a href="http://aidamexico.com/phentermine.html#5577 ">Phentermine</a> <a href="http://aidamexico.com/ativan.html#5577 ">Buy Ativan</a> <a href="http://aidamexico.com/valium.html#5577 ">Valium</a> <a href="http://accurate-metal.com/#5577 ">Viagra</a> <a href="http://aidamexico.com/#5577 ">Xanax</a>
  32. GlsxAjkI <a href="http://unioncountyvoice.com/phentermine.html#0020 ">Buy Phentermine</a> <a href="http://unioncountyvoice.com/xanax.html#0020 ">Cheap Xanax</a> <a href="http://unioncountyvoice.com/ambien.html#0020 ">Ambien</a> <a href="http://unioncountyvoice.com/tramadol.html#0020 ">Cheap Tramadol</a> <a href="http://whitleybaysite.info/#0020 ">Cialis</a> <a href="http://unioncountyvoice.com/#0020 ">Valium</a>
  33. Nmaadc <a href="http://taksimoldcity.com/#6666 ">Cheap Ambien</a> <a href="http://taksimoldcity.com/phentermine.html#6666 ">Cheap Phentermine</a> <a href="http://taksimoldcity.com/xanax.html#6666 ">Cheap Xanax</a> <a href="http://taksimoldcity.com/ativan.html#6666 ">Buy Ativan</a> <a href="http://throopuu.org/#6666 ">Cheap viagra</a> <a href="http://taksimoldcity.com/valium.html#6666 ">Cheap Valium</a>
  34. eofhbSp <a href="http://siggipalma.com/#8088 ">Cialis</a> <a href="http://ranario.com/tramadol.html#8088 ">Buy Tramadol</a> <a href="http://ranario.com/ambien.html#8088 ">Ambien</a> <a href="http://ranario.com/valium.html#8088 ">Cheap Valium</a> <a href="http://ranario.com/xanax.html#8088 ">Xanax</a> <a href="http://ranario.com/#8088 ">Phentermine</a>
  35. KjLVBH <a href="http://rok-kosmac.com/#7419 ">Cheap Xanax</a> <a href="http://ogretmenlisesi.com/#7419 ">Cialis</a> <a href="http://rok-kosmac.com/ativan.html#7419 ">Buy Ativan</a> <a href="http://rok-kosmac.com/ambien.html#7419 ">Cheap Ambien</a> <a href="http://rok-kosmac.com/valium.html#7419 ">Cheap Valium</a> <a href="http://rok-kosmac.com/phentermine.html#7419 ">Cheap Phentermine</a>

leave a reply

All fields marked with " * " are required.