InvalidCastException when using a SequenceHiLoGenerator that returns an Int32

Description

this is the offending line, in Generate: long hival = ( ( long ) base.Generate( session, obj ) );

possible fix: long hival = (long)Convert.ChangeType(base.Generate( session, obj ), typeof(System.Int64));

cause: the call to base.Generate returns a boxed Int32, which cannot be directly cast to an unboxed Int64.

Environment

XP SP1, Framework 1.1 SP1

Activity

Show:

MikeM 
February 25, 2005 at 4:27 PM

0.7 was released

MikeM 
February 21, 2005 at 11:53 AM

code was committed to cvs.

Fixed

Details

Assignee

Reporter

Components

Fix versions

Priority

Who's Looking?

Open Who's Looking?
Created February 18, 2005 at 9:40 AM
Updated February 25, 2005 at 4:27 PM
Resolved February 21, 2005 at 11:53 AM
Who's Looking?