Patent ID: 8851470

Claim:
A conveying device for conveying a recording medium along a conveying path, the conveying device comprising: a pair of first nipping rollers configured to be movable in a width direction while nipping the recording medium, and rotate to convey the recording medium; a pair of second nipping rollers configured to be movable in the width direction while nipping the recording medium, and rotate to convey the recording medium, the pair of second nipping rollers being arranged on an upstream side of the first nipping rollers in the conveying path; and a detecting unit configured to detect an amount of positional deviation in the width direction of the recording medium being conveyed in the conveying path, wherein the pair of first nipping rollers is moved in the width direction based on a detection result of the detecting unit while the pair of first nipping rollers nips the recording medium so that a positional deviation of the recording medium in the width direction is corrected, wherein if the recording medium is longer than a distance in the conveying path between the pair of second nipping rollers and the pair of first nipping rollers, the pair of first nipping rollers and the pair of second nipping rollers are moved in the width direction based on the detection result of the detecting unit while each of the pair of first nipping rollers and the pair of second nipping rollers nips the recording medium, so that the positional deviation of the recording medium in the width direction is corrected, and if the recording medium is shorter than the distance, the pair of first nipping rollers is moved in the width direction based on the detection result of the detecting unit while the pair of first nipping rollers nips the recording medium and the pair of second nipping rollers does not nip the recording medium, so that the positional deviation of the recording medium in the width direction is corrected.