Exemplo n.º 1
0
        /// <summary>
        /// The constructor for the record.
        /// </summary>
        /// <param name="biff">The GenericBiff record that should contain the correct type and data for the RK record.</param>
        /// <exception cref="InvalidRecordIdException">
        /// An InvalidRecordIdException is thrown if biff contains an invalid type or invalid data.
        /// </exception>
        public RkRecord(GenericBiff biff)
        {
            if (biff.Id == (ushort)RecordType.Rk)
            {
                BinaryReader reader = new BinaryReader(biff.GetDataStream());

                ReadRowColXf(reader);
                _value = new RkValue(reader.ReadInt32());
            }
            else
            {
                throw new InvalidRecordIdException(biff.Id, RecordType.Rk);
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// Constructor for the formatted RK value.
 /// </summary>
 /// <param name="xf">The index in the format table for the RK value.</param>
 /// <param name="rk">The RK value.</param>
 public RkRec(ushort xf, int rk)
 {
     _xf    = xf;
     _value = new RkValue(rk);
 }