def return_id_status
      lambda do |api, id=0, cmd, &block|
        raise ArgumentError, 'No callback block' unless block
        callback = callback 'IIPPPPPP', 'L', &block

        status = api.call(id = [id].pack('L'), callback, cmd, 0)
        id = status == 0 ? id.unpack('L').first : nil
        [id, status]
      end
    end
def return_id_status
      lambda do |api, id=0, cmd, &block|
        raise ArgumentError, 'No callback block' unless block
        callback = callback 'IIPPPPPP', 'L', &block

        status = api.call(id = [id].pack('L'), callback, cmd, 0)
        id = status == 0 ? id.unpack('L').first : nil
        [id, status]
      end
    end
Procedure that calls (DdeInitialize) function expecting a DdeCallback. Runtime block is converted
 into Dde callback and registered with DdeInitialize. Returns DDE init status and DDE instance id.

 TODO: Pushed into this module since RubyMine (wrongly) reports error on lambda args