Fax print drivers work well through Microsoft SDK

When you use printer drivers Fax and Microsoft SDK to print a file in WIN7 or WIN SERVER 2008 R2 txt, open the tif generated with windows photo Viewer, it displays error "Windows Photo Viewer can't open this picture because the file seems corrupted, altered, or is too large. We note that, a little more than two pages, the issue can be reproduced.

And then, we reproduce the WIN8 question with the same code, it works well.

So, we think that the Fax driver may be a bug in WIN7 and WIN SERVER 2008 R2.

Here is the code:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Drawing.Printing;
using System.IO;
using System.Text;
using System.Windows.Forms;
using System.Linq;

namespace FaxPrinter
{
partial class Form1: Form
{
private button printButton;
private PrintDocument printDocument1 = new PrintDocument;
private string stringToPrint;

public Form1()
{
InitializeComponent();
this.printButton = new System.Windows.Forms.Button ();
this.printButton.Location = new System.Drawing.Point (12, 51);
this.printButton.Size = new System.Drawing.Size (75, 23);
this.printButton.Text = 'Print ';
this.printButton.Click += new System.EventHandler (this.printButton_Click);
This. ClientSize = new System.Drawing.Size (292, 266);
This. Controls.Add (this.printButton);

Associate the PrintPage event handler for the PrintPage event.
printDocument1.PrintPage +=
new PrintInkEditForm (printDocument1_PrintPage);

}

private void button1_Click (object sender, EventArgs e)
{
ReadFile();
printDocument1.Print ();

}
Private Sub ReadFile()
{
String Nomdoc = "1";
String docPath = "C:\\reports\\";
printDocument1.DocumentName = docName;
using (FileStream ^ stream = gcnew FileStream (docPath + docName, FileMode.Open))
using (StreamReader reader = new StreamReader (stream))
{
stringToPrint = reader. ReadToEnd();
}
}

Private Sub printDocument1_PrintPage (ByVal sender As Object, e of PrintPageEventArgs)
{
int charactersOnPage = 0;
int linesPerPage = 0;

Sets the value of charactersOnPage to the number of characters
of stringToPrint that fits within the page.
e.Graphics.MeasureString (stringToPrint, this.) Fonts,
e.MarginBounds.Size, StringFormat.GenericTypographic,
of charactersOnPage, linesPerPage of);

Draws the string within the page
e.Graphics.DrawString (stringToPrint, this.) Do, Brushes.Black,
e.MarginBounds, StringFormat.GenericTypographic);

Remove the part of the string that was printed.
stringToPrint = stringToPrint.Substring (charactersOnPage);

Check if several pages are printed.
e.HasMorePages = (stringToPrint.Length > 0);
}
' Private Sub printButton_Click (object sender, EventArgs e)
{
ReadFile();
printDocument1.Print ();
}

}
}

This issue is beyond the scope of this site and must be placed on Technet or MSDN

http://social.msdn.Microsoft.com/forums/en-us/home

Tags: Windows

Similar Questions

  • Scan HP PSC 1410 all in one printer works well, does not work with Win XP SP3

    I am well satisfied with my computer HP 2006, Win XP SP3; However when I had to reformat the HP PSC all-in-one printer that works well will analyze any more.  Microsoft says that it does not recognize the drivers for the scanner.

    Try to download software and software updates of the HP Web site.  See if that helps.

  • Drivers works fine, but I cannot listen to or hear any sound (when starting, I hear windows start sound / tone)

    I ve realtek speakers. The symbol of the speaker does not have a cross. I hear the windows starting sound/music, when starting. I looked in the playback options and drivers who are working very well. Only problem is the computer is not detecting my headphones or speakers, I m using Windows Vista Home premium. My speakers are on and was running at full volume, but when I go in the playback devices it says that speakers are not connected. The drivers work well, but I cannot listen to or hear any sound.
    Please help me about this

    Somehow, the speaker jack is disabled on your machine.

    1. Open its in control Panel.
    2. On the read tab, highlight the icon speakers
    3. Click on the Properties button
    4. The box of the use of the device can be set to "disable this device.

    Otherwise, I disable it, apply and activate, apply the setting.

    Messages rating helps other users

    Mark L. Ferguson MS - MVP

  • just installed wireless com-cast, printer works well, but now I can not fax.

    just installed wireless com-cast, printer works well, but now I can not fax. When I do a fax of the SEZ of reading test, "no phone" I tried the direct link 'wall of fax' (or printer) I lose my phone connection?

    Tuesday, October 9, 2012 17:30:39 + 0000, Dimas_888 wrote:

    just installed wireless com-cast, printer works well, but now I can not fax. When I do a fax of the SEZ of reading test, "no phone" I tried the direct link 'wall of fax' (or printer) I lose my phone connection?

    You must connect to the terrestrial telephone line - outlet. But
    You can buy cheaply something that fits into the wall
    taking current and made the two simple output Sockets.

    Ken Blake, Microsoft MVP

  • After the installation of hp wireless printer does not work my mouse microsoft mobile wireless have updated drivers etc, but still does not work

    After installing the printer wireless Hp, my mobile Microsoft Wireless Mouse 1000 will not work. I'm running Vista 32 bit on HP Compac Presio. Have you tried various options such as uninstalling/reinstalling, running Microsoft Fix It that says changes to the hardware detected but it tell me how to solve this problem, and MFI does not generate a report for help.   All USB ports working.  Can someone help me?

    Hello

    I suggest you follow the troubleshooting steps form the article and check if it helps.

    Troubleshoot the incidents of the response to the mouse or wireless keyboard

    http://support.Microsoft.com/kb/838398

  • Printer tests very well and worked before; but now I can't seem to print

    Original title: problem with the wireless printer.

    I have a HP photo printer c309 all-in-one. When I run the printer tests in order to check if it is wireless, it passes all the tests. On my computer, the printer icon said he's ready. It has worked before. Now it does not work. Did not work for some time. I tried everything I know. If I plug in, it works. It not scan from windows and scan fax either and he used also. I don't know if something has changed regarding the settings on my computer or what. Very frustrating. I use verizon for my internet connection. Can you please help?

    Hello

    1. who is the operating system installed on your computer?

    2 have you made changes on the computer before this problem?

    3. you receive error messages when you try to print?

    4. What are the troubleshooting that you tried?

    I suggest you to follow the methods mentioned below and check.

    Method 1: Temporarily disable the security software and then try to print.
    Disable the anti-virus software

    http://Windows.Microsoft.com/en-us/Windows7/disable-antivirus-software
    Note: Antivirus software can help protect your computer against viruses and other security threats. In most cases, you should not disable your antivirus software. If you do not disable temporarily to install other software, you must reactivate as soon as you are finished. If you are connected to the Internet or a network during the time that your antivirus software is disabled, your computer is vulnerable to attacks.

     Method 2: Follow the steps in the article.

     Why can I not print?
    http://Windows.Microsoft.com/en-us/Windows7/why-cant-I-print


    Printer in Windows problems
    http://Windows.Microsoft.com/en-us/Windows/help/printer-problems-in-Windows

    Method 3: Try to update the printer drivers and check if that helps.

    Check out the link for additional assistance mentioned in the update drivers below:
    http://Windows.Microsoft.com/en-us/Windows7/update-a-driver-for-hardware-that-isn ' t-work correctly

    Thank you

  • installed a HP Officejet 8600 + and I can't install print drivers, fax, etc.

    I just installed an Officejet HP 8600 + and I can't install print drivers, fax, etc.

    I tried to download the drivers, but couldn't do it. I have not signed on Microsoft technical support at the time. Someone had this problem and what did you do to solve the problem?
    Thank you.

    Moved to windows

    DC

    Since it is an HP printer, your best bet is to contact them regarding the drivers etc.

  • HP5610 All in One Printer and for some reason any fax does not work

    * - Original title - the printer does not properly

    I have a HP5610 All in One Printer and for some reason any fax does not work.  What could be the problem?  I don't have the CD installation disc.

    Hello

    To provide a proper resolution, I would need more information on your side.

    1. what operating system is installed?

    2. don't you make changes to the computer before this problem?

    We can refer to this article and check if that helps.

    Unable to send or receive Fax: http://h10025.www1.hp.com/ewfrf/wc/document?cc=us&lc=en&docname=c01670485

    You can also ask your question in the Forums of HP Support (scanning, fax and copy): http://h30434.www3.hp.com/t5/Scanning-Faxing-and-Copying/bd-p/Scan

    Thank you.

  • 5210 kodak printer, when I print the document runs through the printer, but nothing prints, suggestions. worked fine until today after a move

    everything looks ok, but when I print the paper passes through the printer but nothing prints, suggestions. worked fine until today after a move

    Check with Kodak support or website to see if there's a test or a diagnostic process that you can run to identify the problem with the printer.  It is not likely to be a problem of Windows at this point.

  • BlackBerry smartphones can HP fax/printer "dial out" through 7130 or model later?

    I own a Blackberry 7130 and have no phone land line to my office. I have suppliers who only receive orders by fax or mail. Is there a solution to connect my HP 5500 fax/printer to the 7130 and "dial", send the fax?

    If not, is there a newer model with which this feature is possible?

    Thanks in advance,

    Richard

    Hello

    The answer is: No.

    But there are a lot of other options to sedn faxes fomr the BB.

    Print2Fax is a software that allows you to send an email receipt/attachment as a fax through a third party.

  • AcrobatX worked well both printing and scanning when harwired to my computer. I went wireless and Windows programs work well both printing and scanning, but not Acrobat.

    Using Windows7 - I tried Windows10 but restored to 7.

    AcrobatX worked well both printing and scanning when connected to my computer. I went wireless and Windows programs work well both printing and scanning, but not Acrobat. In Acrobat, we don't get the scanner and printer prints in a .prn e-file, not to the printer.

    Help please...

    OK - I'VE CORRECTED THE PRINTER WHICH HAS BEEN INEXPLICBLY THE 'PRINT TO FILE' VALUE, BUT THE SCANNER IS STILL MISSING.

  • HP printer stopped working all of a sudden.

    Original title: driver missing

    Windows 7 64-bit. New HP Photosmart Premium C410a/all-in-one printer. Installed using CD installion. Everything worked well for a week. Now the HP Solutions does not and the message saying that problems device driver has not been correctly installed. On the phone with HP for an hour. Downloaded and installed device driver. Complete cleaning. Uninstalled and reinstalled printer software. Still trying troubleshooting message this device driver is missing. Help!

    I had the same problem when I first installed this printer. Under normal conditions the 64-bit driversDID install correctly on your machine. I used mine for the the last three months without sequelNo. . I used all the features selected for installation, with the exception of the fax; even if the fax test has been successful.

    The solution was:

    1) DO a clean install as you normally would, including the functions of selection/deselectings you want to install.

    (2) as long as the device is functioning correctly (print, scan, copy, fax) - IGNORE the Device Manager - explain later.

    3) DO NOT ATTEMPT TO resolve PROBLEMS, this will disable that drivers HAVE been installed correctly.

    (4) you should be able to view the device under the DEVICES & PRINTERS Panel, which is accessible via the control panel.

    The problem is a lack of communication between HP and Microsoft. HP initially notified Microsoft that 32-bit drivers were compatible and Microsoft Compatibility page shows this. The lack of communication is that HPdidn't notify Microsoft 64-bit drivers were also consistent, or they notify Microsoft and Microsoft has not taken any action.

    Because of this Microsoft did not update the software on the DEVICE MANAGER to recognize the drivers. That's why you dialogueMUST IGNORE THE DEVICE MANAGER for this DEVICE AND NO ATTEMPT OF RUNNING through TROUBLESHOOTING . Device Manager displays the printer under two different devices (multifunction devices & other). They will have a yellow triangle on the device. If you try to update the drivers through the Device Manager or the resolution of the problems, the drivers dialog box who properly installed will be disabled and the only way to use the device is completely uninstall the device, recycle the machine, clean the registry and then do a clean install.

    I have been in contact with HP technical support, who had no idea what happened. A product support manager contacted me and after explaining in detail what is happening, he assured that it will be supported as soon as possible. It becomes as well as product and software engineers to find out what has / did not appear on the issue of compatibility. It won't happen overnight, but he assured that he will push for an escalatiopn in this area. It might hurt their sales.

  • I can't get my HP model number 5515 printer to work

    I did a system restore and I can't get my new 5515 HP printer to work, the problem seems to be that the computer and the printer are not in harmony with each other. I went to the HP guide to shooters of problems, but without success. I checked the connection Wireless on the printer and its ok. the message on the bridge of photo printers, tells me I have a wireless connection with success. The computer is a computer laptop Dell 9400, Inspiron, about three to four years old. The printer was working until I did a system restore. I press the sign of the key to my Google page and printing sign comes up, when I press print sign, its just dead. I was on Internet explorer, but it was so slow, that I went to Google, chrome, which is lighting fast. The switch to Google Chrome could be cause my problems?

    Hello

     
    What is the brand and model of the computer?
     
    Method 1: Uninstall and reinstall the wireless card driver.
    Step 1: Download driver network card wireless on the manufacturer's website.
    Step 2: Uninstall the wireless drivers, and then restart the computer. Let Windows install the generic drivers and then see if it helps you to solve the problem.
    A. open the Manager of devices by clicking the Start button, click on the Control Panel, clicking system and Maintenance, and then clicking Device Manager.
    B. Si you are prompted for an administrator password or a confirmation, type the password or provide confirmation.
    C. find the device network according to the option of the network card, right-click on it and select uninstall.
    D. restart the computer (driver will install once you restart the computer, if you are connected to the cable network)
    E. install the wireless network card driver and check.
     
    Method 2: Temporarily disable the security software.
    Disable the anti-virus software
    1 open Security Center by clicking the Start button, click on the Control Panel, clicking Security, and then click Security Center.
    2. click on malware protection.
    If Windows can detect your antivirus software, it will appear under virus protection.
    3. If the software is activated, see the help provided with the software for more information on disabling of this.
     
    You can also go through:
    Printer in Windows problems.
  • OfficeJet Pro 8100: Lost my printer drivers (after a Windows 10 update)!

    Hello

    After the recent Windows 10 updates (one installed on Christmas day), I lost my (custom installed) to the printer drivers. No big deal I thought, ONLY MIcrosoft MOST inconvienience - I'll reinstall just them. But when I open the properties of the printer Panel, I found that ALL ADVANCED TAB where I needed access to reinstall drivers is now GRAY and completely unaccessable! I not only lost my custom drivers, I also lost my second tray of the printer (installed optionally) capacity! YES, MERRY CHRISTMAS!

    Now I need help to reinstall (they gave me specific instructions for installation, so I won't bumble worse trying to install them differently (as a regular driver) without confirmation first.)
    This is a PERFECT EXAMPLE of why we should be allowed to choose for outselves when and what updates to install on OUR computer! I checked the Windows Update history and there is NOTHING there that would strike even he would have had to change printer drivers, nor I anthing that would affect them being changed (for example, allowing control HP from my PC to automatically updated drivers), but clearly something changted them.

    What I HAD... I use a printer Officejet Pro 8100 bought two years ago February next with the option second tray of the installed printer. I also use Officejet 8600 drivers in order to be able to print my graphic files properly (these drivers were recommended on this forum once I have posted having problems printing after the first installation. These drivers worked PERFECTLY in all of my PC (running Windows XP, 8.1, and 10), but now with the missing options, everytting is printing through the upper status bar (where I have a THICK paper). I don't have the ability to choose which try to print (Tray 1 or 2), and I need to change paper whenever I want to print on different paper (I always had a THICK paper on top (Tray 1) and plain paper in the lower part (tray 2) because it would not print thick paper from the tray at the bottom.

    To use the 8600 drivers, I was given specific instructions (on this forum) on install in the section "NEW DRIVER" of the ADVANCED TAB in the properties of the printer. Now that I don't have access to this tab, I need to know if there is a way to access new (my preferred method) OR another way to install (for example just install them as if I would install the printer (8600))?

    It's free enough explainatory tab FULL area is GRAYED OUT, but in case there are any doubts, I have attached is a screenshot showing what he looks like.

    I apprecate any help you could offer.

    Kind regards... Chugbug

    OK, now it's really WEID!

    I tried during the last 24 hours to get to the Panel in question, including the restart of Windows at least half a dozen times without success.  But now tonight after that I dug around the different tabs, once again, INCLUDING clicking on through security and permissions panels (but not to make changes) AND for posting my question here, all in the advanced Panel was suddenly accessible once more!

    I reinstalled my 8600 drivers again, then reset my printing (default) preferences (paper 2 / plain plateau), and everything is good again (kumbaya...)!

    Good thing, I took a screenshot of it (grey) or I can't believe myself!

    Happy holidays!  Chugbug

    Screenshot showing access with my 8600 drivers installed:

  • HP 6500 printer stops working

    Intermittent printer.  A few times, it works very well with radio and sometimes it does not.  I reloaded the software several times, but it does not correct

    Intermittent printer.  A few times, it works very well with radio and sometimes it does not.  I reloaded the software several times, but it does not correct

    Hey waldo 2005

    ·                        try to uninstall then reinstall it and use thelatest VISTA printer drivers for your model of the manufacturer of the printer

    http://welcome.HP.com/country/us/en/support.html

    You can also track information to try to solve your problems of printer below

    read the printer correct that information the slot microsoft, including the 'fix - it' and the other links here

    Solve printer problems

    http://Windows.Microsoft.com/en-us/Windows-Vista/troubleshoot-printer-problems

    and read this microsoft tutorial too

    Introduction

    This tutorial is designed to help you identify and fix the problem printer common windows problems, including print errors, or errors, and other issues that could prevent you from printing. This tutorial does not cover printing problems related to specific programs. Printing problems can be caused by cables that are not properly connected, corrupt, drivers, incompatible drivers, the printer settings, missing updates and problems with your printer.

    How to use this tutorial

    For best results, complete each step before move you on to the next. Try to print after each step before moving on to the next step.

    http://Windows.Microsoft.com/en-us/Windows/help/printer-problems-in-Windows

    Walter, the time zone traveller

Maybe you are looking for