Why am I unable to restore SMS backup?

net4uall

New member
Nov 27, 2014
4
0
0
Visit site
Unable to restore SMS backup

Hi,

I had Omega rom installed on my S4 i9500, which let me import/export SMS messages to a backup. Due to some issues I was having, I was going back to stock rom, and made a backup(exported messages to SD card in .xml format)

Now having installed the stockrom, the option to import/export messages is gone frome the context menu in SMS.

Tries with the app, SMS backup and restore, which also uses .xml, but the app says invalid file. Other apps have similar error's because the backup was not made by that app.

How can I get the import/export option back in the context menu?
or
Is there any other way to restore them from the .xml backup I made?
 

Rukbat

Retired Moderator
Feb 12, 2012
44,529
28
0
Visit site
Re: Unable to restore SMS backup

There is a way, but you're going to have to do a bit of work.

Use SMS Backup & Restore to make a backup of some messages to an xml file.

Now open that file in Notepad and open a copy of the file it won't import (never work on the original file, in case you damage something) in Notepad. Find the differences. Change the copy of the "bad" file to the format of the good file. Then SMS B & R should import the "fixed" old file copy.

(An xml file is text in a particular format. There's a header, then section names enclosed in <> that run to the end of the section, where the name in the <> is preceded by /. There can be many sections embedded within sections. A section can also be a single line with <, the name, the data and >, likew
<Name John Smith> would be the name of the contact.

<Contact>
<Name John Smith>
<Address
123 Any Street
Any City
State
USA
</Address>
</Contact>

would be a multiline entry.

There's either a difference in the order of the items between the two (the one that you just made and the one that won't import) files, a difference in the section names (<Addr> and <Address> are different) or a difference in the header (the part before the first contact, and there should be 5 or 6 lines (I took a quick look in a text editor on my phone and some of the lines take up many lines on the phone screen) before the first contact.

At least you'll learn how xml files are built and how to read them. (You can read all your contact information in the file, it's plain text.)
 

net4uall

New member
Nov 27, 2014
4
0
0
Visit site
Re: Unable to restore SMS backup

Got really optimistic in trying this, until I opened the side by side.
Differences are too great, and some things missing in the original xml file that i wouldn't be able to deduct for the xml intended for sms B&R.

Anyhow, I got some of the info I needed from the back, by copying it from note pad. So restoring it is not a priority.
Thank you very much for the help, it was certainly the most logic way to go.