Quickreport forum
Go to Quickreport website
Welcome Guest Search | Active Topics | Log In | Register

QuickReport AV in Windows 10 (Build 14393)
hinsona
#1 Posted : 26 April 2017 15:13:33(UTC)
Rank: Newbie

Groups: Registered
Joined: 26/04/2017(UTC)
Posts: 2

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
QR5.02 / Delphi 7 / Windows 10 (Build 14393)

AV in QRPrntr.pas (3280)

Code:
procedure TPrinterSettings.ApplySettings;
var
  Cancel : boolean;
begin
  FPrinter.GetPrinter(FDevice, FDriver, FPort, DeviceMode);
  DevMode := GlobalLock(DeviceMode);
  begin
    SetField(dm_paperlength);
  ...
end;


FPrinter has no printer assigned.
DeviceMode is 0.

Attempts at GetPrinter fail to set a DeviceMode (DevMode) value, which raises an exception when SetField() is called.

Prior to build 14393 the report worked fine, and continues to work in earlier builds of Windows.

Here are two short videos where I stepped into the QuickReport.Print method. Hopefully it illustrates the issue I’m seeing.

Windows 10 Build 15063
https://1drv.ms/v/s!AsbtokV75aocsXs0dxSMZnfxEC-E

Windows 7
https://1drv.ms/v/s!AsbtokV75aocsXyNLaipFUr8G4LD

Here's a sample project where it happens. In the folder, there's a main project and dll project. Build the main first, then open the dll project and set the Run>Parameters>Host Application (needs full path) to the exe created from the main project. Once this is done you can step into the print methods called in the dll. It's repeatable from a fresh install of Windows and Delphi with admin rights.
https://1drv.ms/u/s!AsbtokV75aocsXM6MQZcrvwpHKcg
Rezig fayçal
#2 Posted : 26 May 2017 12:17:00(UTC)
Rank: Newbie

Groups: Registered
Joined: 26/05/2017(UTC)
Posts: 1
Location: algeria

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
hello


add

uses Winspool, Printers;

in quickreport Form.

hinsona
#3 Posted : 05 June 2017 14:18:50(UTC)
Rank: Newbie

Groups: Registered
Joined: 26/04/2017(UTC)
Posts: 2

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
Rezig fayçal wrote:
hello


add

uses Winspool, Printers;

in quickreport Form.



Thanks for the reply. I tried this and it did not work for me. I ended up back porting changes from QRPrntr.pas from QR5.06 (this version worked in testing) into QR5.02 (had to be remain compatible with ANSI API calls) to solve the issue. If you're having these types of problems with Windows 10, contact support. I sent them a copy of the working QRPrntr.pas since other users were reporting similar issues with QR5.02 and Windows 10.

Cheers.
Users browsing this topic
Guest (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Clean Slate theme by Jaben Cargman (Tiny Gecko)
Powered by YAF 1.9.4 | YAF © 2003-2010, Yet Another Forum.NET
This page was generated in 0.029 seconds.