Matt,
I modified the OnClickedSleep function in the SleepTimer app to read as so:
LRESULT CSleepTimerCtrl::OnClickedSleep(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
{
IMJFilesAutomationPtr pMJFiles = m_pMJ->Search( (LPCTSTR)"" );
IMJFileAutomationPtr pMJFile;
if( pMJFiles != NULL )
{
long lTrackNumber;
long lTotal = 0;
long lEOL = pMJFiles->GetNumberFiles();
for( long lLoop1 = 0; lLoop1 < lEOL; lLoop1++ )
{
pMJFile = pMJFiles->GetFile( lLoop1 );
lTrackNumber = pMJFile->GetTracknumber();
if( lTrackNumber > 0 )
{
AtlTrace( "Track %06d = %03d", lLoop1, lTrackNumber );
++lTotal;
}
}
AtlTrace( "Found %ld out of %ld", lTotal, lEOL );
}
ToggleSleep();
return 0;
}
When I run it I get:
[384] Track 000113 = 001
[384] Track 000114 = 002
[384] Track 000124 = 001
[384] Track 000125 = 002
[384] Track 000126 = 003
[384] Track 000127 = 004
[384] Track 000128 = 005
[384] Track 000129 = 006
[384] Track 000130 = 007
[384] Track 000131 = 008
[384] Track 000132 = 009
[384] Track 000367 = 005
[384] Track 000968 = 001
[384] Track 001097 = 006
[384] Track 001454 = 001
[384] Track 001995 = 001
[384] Track 002360 = 001
[384] Track 002361 = 002
[384] Track 002362 = 003
[384] Track 002363 = 004
[384] Track 002364 = 005
[384] Track 002365 = 006
[384] Track 002366 = 007
[384] Track 002367 = 008
[384] Track 002368 = 009
[384] Track 002369 = 010
[384] Track 002370 = 011
[384] Track 002483 = 006
[384] Track 002578 = 032
[384] Track 002579 = 032
[384] Track 002580 = 032
[384] Track 002691 = 001
[384] Track 002692 = 002
[384] Track 002693 = 003
[384] Track 002694 = 004
[384] Track 002695 = 005
[384] Track 002696 = 006
[384] Track 002697 = 007
[384] Track 002698 = 008
[384] Track 002699 = 009
[384] Track 002700 = 010
[384] Track 002701 = 011
[384] Track 002702 = 012
[384] Track 002781 = 001
[384] Track 002782 = 006
[384] Track 002783 = 255
[384] Track 002784 = 012
[384] Track 004033 = 012
[384] Track 005430 = 001
[384] Found 49 out of 5530
Which is surprising since all of my tracks have track numbers.
I have confirmed with Helium2 that the track numbers are still intact within the MP3 files.
As a final test I wiped my library and regenerated it ... the problem still remains.
Also when I view my tracks with MJ it shows the track# as being blank .. but only for some of them ... 49.
The only thing I can see that links them all together is that the 49 tracks do not have an ID3v2 total tracks tag (the one where you can specify the total tracks within an album).
I think that's where you should be looking.
If you still can't find it let me know and I'll email you a couple of mp3's that should hilight the issue.