1. A barcode recognition method, applicable to a data processing apparatus, wherein the data processing apparatus at least comprises a control module, a touch-control display module, an image capture module, a data storage device, and an input unit, and the method includes the following steps: loading and initializing a barcode recognition program from the data storage device by the control module; switching the barcode recognition program to background execution by the control module; continuously monitoring whether a trigger event occurs to the data processing apparatus by the control module; when the trigger event occurs, switching the barcode recognition program to foreground execution by the control module; capturing at least one image frame by the image capture module, and transmitting the captured image frame to the control module; recognizing the captured image by the control module, so as to determine a position of a barcode in the image frame and derive barcode information to obtain a recognition result; by the control module, outputting the recognition result by simulating keystrokes; and switching the barcode recognition program to background execution by the control module.