Share via


PointCardRW.BeginInsertion Method

2/27/2008

Starts point card processing.

Namespace: Microsoft.PointOfService
Assembly: Microsoft.PointOfService (in microsoft.pointofservice.dll)

Syntax

'Declaration
Public MustOverride Sub BeginInsertion ( _
    timeout As Integer _
)
public abstract void BeginInsertion (
    int timeout
)
public:
virtual void BeginInsertion (
    int timeout
) abstract
public abstract void BeginInsertion (
    int timeout
)
public abstract function BeginInsertion (
    timeout : int
)

Parameters

  • timeout
    The timeout parameter gives the number of milliseconds before failing the method. If zero, BeginInsertion tries to begin insertion mode, then returns the appropriate status immediately. If WaitForever, BeginInsertion tries to begin insertion mode, then waits as long as needed until the point card is inserted or an error occurs.

Remarks

When it is called, the point card reader/writer state is changed to allow the insertion of a point card and the point card insertion mode is entered. BeginInsertion is paired with the EndInsertion method for controlling point card insertion.

If the point card reader/writer device cannot be put into insertion mode, an error is returned to the application. Otherwise, the service object monitors point card insertion at one of the two occurrences:

  • The point card is successfully inserted. In this case, the service object returns a Success status.

  • The point card is not inserted before timeout milliseconds have elapsed, or an error is reported by the point card reader/writer device. In this case, the service object either returns Timeout or another error. The point card reader/writer device remains in point card insertion mode. This allows an application to perform some user interaction and reissue the BeginInsertion method without altering the point card handling mechanism.

BeginInsertion may throw a PosControlException exception with the following ErrorCodes:

Value

Meaning

Busy

This operation cannot be performed because asynchronous output is in progress.

Illegal

The point card reader/writer does not exist or an invalid timeout parameter was specified.

Timeout

The specified time has elapsed without the point card being suitably inserted.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread-safe. Any instance members are not guaranteed to be thread-safe.

See Also

Reference

PointCardRW Class
PointCardRW Members
Microsoft.PointOfService Namespace
EndInsertion
BeginRemoval
EndRemoval