An information processing apparatus capable of communicating with a device, comprising: installation means configured to install a driver corresponding to the device; a first generation means configured to generate an icon corresponding to the driver installed by the installation means and corresponding to a first type, wherein a port of a first port type is generated when the icon corresponding to the first type is generated; a second generation means configured to generate an icon corresponding to the driver installed by the installation means and corresponding to a second type; characterized by a port determination means for determining whether or not a port of the first type is to be generated; an acquisition means for acquiring (51301, S1305), in a case (S1201:YES) where the port determination means has determined that a port of the first type is to be generated, the number of ports registered in the information processing apparatus before and after an icon generation process is executed by the first generation means; control means configured to determine that the icon generation process executed by the first generation means has failed if the number of ports acquired by the acquisition means has not increased as compared to before the execution of the icon generation process (S1306:NO), and generate, if it has determined (S1203:NO) that the icon generation process executed by the first generation means has failed, by the second generation means, an icon corresponding to the driver installed by the installation means and corresponding to the second type. installation means configured to install a driver corresponding to the device; a first generation means configured to generate an icon corresponding to the driver installed by the installation means and corresponding to a first type, wherein a port of a first port type is generated when the icon corresponding to the first type is generated; a second generation means configured to generate an icon corresponding to the driver installed by the installation means and corresponding to a second type; characterized by a port determination means for determining whether or not a port of the first type is to be generated; an acquisition means for acquiring (51301, S1305), in a case (S1201:YES) where the port determination means has determined that a port of the first type is to be generated, the number of ports registered in the information processing apparatus before and after an icon generation process is executed by the first generation means; control means configured to determine that the icon generation process executed by the first generation means has failed if the number of ports acquired by the acquisition means has not increased as compared to before the execution of the icon generation process (S1306:NO), and generate, if it has determined (S1203:NO) that the icon generation process executed by the first generation means has failed, by the second generation means, an icon corresponding to the driver installed by the installation means and corresponding to the second type. determine that the icon generation process executed by the first generation means has failed if the number of ports acquired by the acquisition means has not increased as compared to before the execution of the icon generation process (S1306:NO), and generate, if it has determined (S1203:NO) that the icon generation process executed by the first generation means has failed, by the second generation means, an icon corresponding to the driver installed by the installation means and corresponding to the second type.