A computer-readable storage medium which stores a program to cause a data processing apparatus which can transmit data including image data to be recorded, to an image recording apparatus capable of connecting with a sheet processing apparatus having plural storage units capable of storing sheets, to execute:
- a generation step of generating first data based on an operator's instruction for instructing to distribute the sheets to the storage units belonging to which of plural groups of the grouped storage units;
- and
- a transmission step of correlating the first data with the image data and transmitting the correlated data to the image recording apparatus.