In image processing, one of the most fundamental technique is edge detection. It is a process to detect edges from images by identifying discontinuities in brightness. In this research, we present an enhanced Canny edge detection technique. This method integrates local morphological contrast enhancement and Canny edge detection. Furthermore, the proposed edge detection technique was also applied for pneumonia and COVID-19 detection in digital x-ray images by utilising convolutional neural networks. Results show that this enhanced Canny edge detection technique is better than the traditional Canny technique. Also, we were able to produce classifiers that can classify edge x-ray images into COVID-19, normal, and pneumonia classes with high accuracy, sensitivity, and specificity