DeleteBitmapValue Example for C++ 6.0 and later

   short nRet;

   m_pLEADDicomDS->EnableMethodErrors = FALSE;

   //move to the first image element
   nRet = m_pLEADDicomDS->FindFirstElement(TAG_PIXEL_DATA, FALSE);
   //get the first image
   nRet = m_pLEADDicomDS->GetBitmapValue(0, 0, ORDER_BGR, 0);
   m_LEADRasterView1.GetRaster().SetBitmap(m_pLEADDicomDS->GetBitmap());
   //flip the image
   ILEADRasterProcessPtr pRasterProcess=NULL;
   CoCreateInstance(CLSID_LEADRasterProcess,
                    NULL,
                    CLSCTX_ALL,
                    IID_ILEADRasterProcess,
                    (void**)&pRasterProcess);
   pRasterProcess->EnableMethodErrors = FALSE;
   pRasterProcess->Flip(m_LEADRasterView1.GetRaster());

   //delete the first image from the dataset
   nRet = m_pLEADDicomDS->DeleteBitmapValue(0, 1);

   //now update the list with the flipped image
   nRet = m_pLEADDicomDS->InsertBitmapValue(m_LEADRasterView1.GetRaster().GetBitmap(),
                                            0, DICOM_IMAGE_COMPRESSION_NONE,
                                            DICOM_IMAGE_PHOTOMETRIC_RGB, 0, 0, 0);