views:

499

answers:

4

I have developed a few Delphi Win32 (currently using D2007) applications, which revolve around note-taking and idea development. I'd like to be able to pull the notes written on the iPhone's little "notes" app into these apps (which store their data in a database). One-way importing would be fine for now. Is this possible? If so, what would be the best approach for doing it?

Please note: I'm not, at this point, looking to write a fully-fledged iPhone app unless it's required to accomplish what I'm specifying here -- I'm only looking to import the data. Also, third-party components are fine -- I'd be happy to pay money for this in order to save time / learning curve delays. Lastly, I have and occasionally use RemObjects Hydra (.NET / Win32 plug-in/interop framework), if that turns out to be relevant.

Lastly, I have ZERO iPhone development experience -- so please don't worry about speaking at too "fundamental" a level! : )

Thanks in advance for any and all help / pointers / direction.

+3  A: 

According to this post, the 'Notes' data isn't accessible via API. (or wasn't as of 2 months ago)

https://devforums.apple.com/message/64154#64154

But if you wrote your own notes app, you could sync it with a web server via XML or JSON, then import the data into your Delphi app.

John
+1  A: 

I believe the secret to this would involve cracking the format used to backup the device. The problem with this approach is that the backup file is most definitely encrypted, and currently undocumented.

Because each app on the IPhone/ITouch runs in its own sandbox, you can't write another app on the device to get this information. Your only real option would be to develop your own "notes" application where you can control how it is written, and from there develop the means to communicate with the desktop. There are quite a few examples floating around that do some of the basics...you just have to put the pieces together.

One of the common methods of communicating with a "desktop" application is to embed a HTTP server in the app on the iphone, and then respond to specific commands sent from the desktop client.

skamradt
Didn't know that re: sandbox, etc -- thanks for pointing it out.
Jamo
As far as I'm aware iPhone backups aren't encrypted unless specified in iTunes (the option for this came in iTunes 8.1 and iPhone OS 3.0).
Pauk
+1  A: 

Don't try to talk to the iPhone Notes app, talk to wherever it's already syncing to. On Windows I believe Notes syncs to Outlook, which of course has an extensive API.

Brent Royal-Gordon
+1  A: 

It may be simpler to write an interface to an existing web-synced iPhone note application.

Several todo and note iPhone apps sync to Toodledo(www.toodledo.com), they have a developer API so your user could use one of these apps on the iPhone and your PC app could get the note data from Toodledo. (Toodeldo can also sync to Outlook).

bcleland