This project has moved and is read-only. For the latest updates, please go here.

Missing reference

Topics: Documentation, Getting Started
Sep 17, 2014 at 3:51 PM
I am making a program to edit the lyrics in a KAR file. Since KAR is the same structure as MID, I have been using the code from the MIDI.NET samples. I took a look at MidiFilePlayer and was able to readily adapt it into my application. Now I am trying to use the code from MidiRecordToFile to write out the changes. In the file MidiFileSerializer.cs there is a base class called DisposableBase and a type called DisposeObjectKind - neither can be found. I have checked all the 'using xxx' and references, but I can't see where these should come from. Google search came up empty, so I suspect they are something from CannedBytes. Can you shed some light on this?

Sep 17, 2014 at 4:15 PM
Yes correct, that reference is from the CannedBytes assembly.

The MIDI.NET solution depends on several CannedBytes library assemblies. The DispasableBase class (and the DisposeObjectKind enum) lives in CannedBytes.dll. They should be present in the MIDI.NET binary release .zip.

Make sure you have the CannedBytes.dll (also IO and Media) on your system. You can also try to delete the reference from your project file and redo it by hand, sometimes that works when VS cannot find the assembly files based on the hints in the project files...

Let me know if it all works out for you.

Hope it helps,
Sep 17, 2014 at 5:59 PM
Problem solved. I had taken some of your sample code and put it all in one project file - and I used a NAMESPACE of MidiHelperFiles. When I changed the namespace to CannedBytes.MidiHelperFiles, the types were found.