• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Help Image numbering after camera reset

So, there is a problem. I have taken 140 images and 10 videos with my HTC Desire camera. Then, after little camera setting experiment I had to reset the settings of camera.

And now any new picture is numbered like a IMG 0001 and so on. Is it possible to take a picture and see the correct number of it, like 141 etc. ?

Thank you.
 
  • Like
Reactions: cortega619
I have run into the same problem since installing HTC's Gingerbread on my Desire. It reset the phone and now I am back to IMAG0001 after getting to IMAG1305. The problem this causes is I will eventually catch up with images with the same name and it will try to replace them when I move them from the phone to my external hard drive.

I was hoping there was some way you could set the starting name and then it would carry on from there. You could do this on an old Casio camera I had by simply changing the filename and then the camera carried on from there, which was useful.
 
Upvote 0
I haven't tried this possible fix but it might just work. Remove everything from your /DCIM/Camera folder (or whichever folder your photos usually end up in). Now take a picture, exit the camera app, run your favourite file manager app and rename the photo file to whatever number you want. With any luck, next time you take a photo (which you can check straight away) the numbering will start with the next available number after your number.
 
Upvote 0
I'm rooted, and this solution worked for me:

1. In Root Explorer (or any root file manager), browse to "/data/data/com.android.camera/shared_prefs".
2. Open "com.android.camera_preferences.xml" with a text editor.
3. Toward the end of the file, find this line (where "9" is the index number of the last picture taken):
<string name="counter_image">9</string>
4. Change the "9" (or whatever it is) to the number you want. (Personally, I changed it to "209", and later I manually renumbered the 9 images I had already taken as 0201, 0202, etc.)
5. Save changes and exit.
6. REBOOT THE PHONE.
7. Try taking a picture. It should start at the new number and go sequentially from there.
 
Upvote 0
I tried the image rename method and it doesn't work. It simply skips past that name and uses the next one, then it retains this start point, so you would need to take X photos until you reach the name you want to actually continue from.

For example, if you factory reset your phone, take a picture (IMAG0001) and rename it IMAG0999 the next photo will not be IMAG1000, it will be IMAG0002. But if you rename IMAG0002 to IMAG0003 and take a photo, the next one will be IMAG0004.

I am not rooted, but can't locate any of the files, or equivalents, that thenestor refers to to even see how my phone stores this data.

This image naming thing is really starting to annoy me, especially when lots of other past and present devices have a mechanism to deal with this.

The only way around it I can think of without rooting is to create a blank JPG multiplied by the amount you need and then ensure they are named sequentially up to the start point you want and copy them to the relevant camera folder on the phone. Based on my aforementioned test, I reckon it would then skip all these file names and use the next one. I might see if I can do this with one image and script or a batch file to automate the file replication and sequential naming.
 
Upvote 0
I've sorted my Desire photo naming issue by creating blank JPG images named IMAG0001.jpg through to IMAG9999.jpg and copying the range where I want the camera to continue from into the default photo folder, so for my scenario I copied IMAG0001.jpg-IMAG1400.jpg into the \sdcard\DCIM\100MEDIA folder, then took a picture and the camera has continued from IMAG1401.jpg. You can delete the blank JPGs once you've done this.

I've attached a ZIP file containing blank images IMAG0001.jpg-IMAG9999.jpg for your convenience.
 

Attachments

  • IMAG0001-IMAG9999.zip
    3 MB · Views: 444
Upvote 0
@mjpartyboy
Filling the \sdcard\DCIM\100MEDIA folder with your fake files until the desired number did the trick.

Thx for saving me from having to rename files for hours, getting confused, screwing it up, accidently overwriting the wifes favourite pictures of the kids, uselessly trying blaming HTC, getting divorced, having to sell the house, being homeless, having my phone stolen while sleeping on the street and then living happily ever after while not having to spend every hour awake (and some at sleep) trying to find workarounds for all the flaws in my Android phone.
 
Upvote 0
Just found another quick and simple way to fast forward image counter to where it was on my unrooted HTC Desire HD.
So you've reset your camera, now:
1. make sure the last image/video you want to restart your numbering from is in /sdcard/DCIM/100MEDIA folder ie. IMAG1233.JPG
2. take a photo
2. note new photo/video number ie. IMAG0003.JPG
3. now rename the photo/video you just taken ie. IMAG0003.JPG -> IMAG0004.JPG
4. take another shot
now the camera will find the file name it wanted to use already exists and instead of overwriting it it will automatically skip to the last count number
5. go and check that second photo already is IMAG1234.JPG

hope it works for you all cause renaming is just too hard work :smokingsomb:
 
  • Like
Reactions: ninjy and trachl
Upvote 0
Old thread I know, but hopefully a 'bump' will help others find this when googling for the problem...

I just did this same trick on my new HTC 10 in Sep 2017, and the guide from me_how 2 posts above worked perfectly for me!

So if you're trying to make sure your photo auto numbering starts where you want it either after resetting or with a new HTC phone, good to know this still works.

Thanks!
 
Upvote 0
An old thread from three years ago, but the problem still remains with the Android system camera app not having a way either to manually set the next IMAGxxxx.jpg or VIDEOxxxx.mp4 numbers, or even intelligently set the next number itself by observing what is already held in storage. The app just blindly starts from number 0001 for example after a reset, or in my case I moved my SD card with all my most recent images and videos into an identical new HTC U11 handset, but despite these files being there the next pic and video taken start at number 0001 again.

I'm pleased to confirm that me_how's neat little trick still works fine on Android Pie (9):

1. make sure the last image/video you want to restart your numbering from is in /sdcard/DCIM/100MEDIA folder ie. IMAG1233.JPG
2. take a photo
2. note new photo/video number ie. IMAG0003.JPG
3. now rename the photo/video you just taken ie. IMAG0003.JPG -> IMAG0004.JPG
4. take another shot
now the camera will find the file name it wanted to use next (IMAG0004) already exists and instead of overwriting it, it will automatically skip not to the next sequence number but all the way to the last image number + 1
5. go and check that second photo already is IMAG1234.JPG :)

You can obviously do the same trick for VIDEO1234.MP4.

What a simple solution! But what a shame that the camera app needs this little nudge to get its act together!!
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones