Once you have the name of a printer, to print on a network use the CopyFile function or the CreateFile and WriteFile functions.
CopyFile has the following syntax:
CopyFile (szSrcFile, szUNCPrinterShare, FALSE);
The file to print is szSrcFile. The network printer to use is szUNCPrinterShare, which can accept a UNC name returned by the WNetEnumResource function.