INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Command Line IMPORT ... Help ?  (Read 995 times)

drosoph

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 661
  • TiVo-aholic
Command Line IMPORT ... Help ?
« on: September 23, 2002, 08:31:19 am »

I'm trying to run a command line file IMPORT to MJ Database ...
Running "C:\Program Files\J River\Media Jukebox\mjextman.exe" /Import C:/MP3/ causes MJ to startup (if closed) and then immediately close (or close any active session).  

Does the /Import command only work on individual files ?? Should I be making the statement say C:/MP3/*.* or something .. I want it to search all files/subdirectories/etc for files to import .. and I would ALSO like to be able to specify extensions.

KingSparta

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 20063
Re: Command Line IMPORT ... Help ?
« Reply #1 on: September 23, 2002, 10:03:44 am »

>> C:/MP3/
would you not get Dir Not Found Error

If This Can Be Done Should It Not Be "C:\MP3\"?

Logged
Retired Military, Airborne, Air Assault, And Flight Wings.
Model Trains, Internet, Ham Radio, Music
https://MyAAGrapevines.com
https://centercitybbs.com
Fayetteville, NC, USA

drosoph

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 661
  • TiVo-aholic
Re: Command Line IMPORT ... Help ?
« Reply #2 on: September 23, 2002, 12:10:47 pm »

Thanks, That fixed problem #1 ... it no longer loads/unloads MJ .... Now it loads MJ, and says IMPORTED 0 FILES ...


My files are organized in the Artist/Album sub-dir structure .. How do I get the /IMPORT flag to recurse sub-dir structure ?

drosoph

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 661
  • TiVo-aholic
Re: Command Line IMPORT ... Help ?
« Reply #3 on: September 23, 2002, 08:32:47 pm »

Alright ... Since I havent seen much of a response to my thread ...

Does anyone have a method of using the Media Scheduler for the purpose of importing files into the MJ Database ?

This would work something like the "watched Dir's" that other programs use ... you could just schedule it up to search scertain dirs once a day or so ....

Anybody?  Anybody ?

Mirko

  • Regular Member
  • Galactic Citizen
  • ****
  • Posts: 495
  • Coffee ready?
Re: Command Line IMPORT ... Help ?
« Reply #4 on: September 23, 2002, 09:13:52 pm »

What about this:

  • change to the parentdirectory
  • "dir /B/S > filelist.lst"
  • notepad filelist.lst
  • add the appropriate MJ-commandline parameter for addings files
  • voila


You could always use another way. Using a little qbasic pgm:


DIM sEntry AS STRING
OPEN "FILELIST.LST" FOR INPUT AS #1
OPEN "ADDFILES.BAT" FOR OUTPUT AS #2
DO WHILE NOT EOF(1)
 LINE INPUT #1, sEntry
 PRINT #2, "C:\Program Files\J River\Media Jukebox\mjextman.exe /Import " + CHR$(34) + sEntry + CHR$(34)
LOOP
CLOSE #2
CLOSE #1
SYSTEM


And this batchfile for doing it all automatically:


@echo off
dir /B/S > FILELIST.LST
qbasic /run convert.bas
addfiles
echo on


Maybe this helps. I'm not sure about the "Chr$(34)"-thing, maybe MJ doesn't need this...

HTH,
Mirko

Logged

drosoph

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 661
  • TiVo-aholic
Re: Command Line IMPORT ... Help ?
« Reply #5 on: September 24, 2002, 07:09:55 am »

THANKS !!! Had to change the exe path to C:\Progra~1\JRiver~1\MediaJ~1\mjextman.exe and everything worked fine ...

It was a little rough (considering it tried to import ~10,000 files (even though I only needed to add ~100) ... and it does them individually (took about 8 minutes).  

All in all it worked well.  Now if only I could perform an UPDATE or specify the extensions :) ... THAT would be SWEEET !
Pages: [1]   Go Up