Silverfrost Forums

Welcome to our forums

select_printer@

11 Apr 2023 4:36 #30181

I wonder if users can try this example and see if it shows the select printer dialog when compiled with 64-bits.

program p
use clrwin
integer ii
CHARACTER(256) dev, port
ii=select_printer@(dev,port)
end

It works for me and I know it does for Paul. I have a VM on which it fails but that has no real printer drivers.

11 Apr 2023 5:15 #30182

/64 fails on my machine. Win32 OK

11 Apr 2023 5:28 #30183

What does it do Ken?

11 Apr 2023 5:36 #30184

Unknown exception (80040155) at address 7ffb14a2fe7c

Within file KERNELBASE.dll In RaiseException at address 6C In RpcRaiseException at address 50 Within file RPCRT4.dll In RpcRaiseException at address 14 In Ordinal147 at address 36B2 Within file combase.dll In NdrServerCallAll at address 2BE Within file RPCRT4.dll In NdrServerCallAll at address 250 In NdrServerCallNdr64 at address 2E30 In NdrClientCall3 at address 1DC0 In NdrStubCall3 at address D3 In CStdStubBuffer_Invoke at address 6F

RAX = 00007ffb16b22cc1 RBX = 0000000080040155 RCX = 000000000260f948 RDX = 0000000000000000 RBP = 0000000000000000 RSI = 00000000025f7f30 RDI = 00000000146fec30 RSP = 00000000146fe850 R8 = 00007ffb16b22c8b R9 = 0000000080040155 R10 = 00007ffb1740be60 R11 = 0000000000000000 R12 = 000000000000011c R13 = 000000000259bd80 R14 = 000000000260f808 R15 = 0000000000000001

7ffb14a2fe7c) db 0f,1f,44,00,00

11 Apr 2023 11:11 #30185

The 32- and 64-bit EXEs display a printer selection dialog.

Windows 64, no printer attached.

12 Apr 2023 9:24 #30186

Robert,

After letting Windows Update do it's thing this morning:

2023-04 Cumulative Update for Windows 11 Version 22H2 for x64-based Systems (KB5025239)

The code now runs as expected!

https://support.microsoft.com/en-gb/topic/april-11-2023-kb5025239-os-build-22621-1555-5eaaaf42-bc4d-4881-8d38-97e0082a6982

All the dlls referred to in the traceback above have been updated - since yesterday.

12 Apr 2023 10:22 #30187

It seems to affect a lot of users. The VM I have it on is an old Windows 10 build so it isn't a transient issue.

13 Apr 2023 7:53 #30188

No issues with the code on my older Windows 10 machine. Both before and after windows updates (not been turned on for a few months).

16 Apr 2023 11:37 #30194

One thing which seem to provoke it is setting the default printer to 'Microsoft Print to PDF'

13 Jun 2025 1:03 #32157

I now seem to be having this same problem. It prints to a printer, but when a PDF driver is selected, after it completes the output, it waits a few moments and then crashes with the following message:

Silverfrost 64-bit exception report on C:\Users\Ian\Documents\Projects\trunnion17\Debug\x64\Trunnion17.exe Thu Jan 1 00:00:00 1970

Unknown exception (80010012) at address 7fff0e819f0a

Within file KERNELBASE.dll In RaiseException at address 8A In RpcBindingToStringBindingW at address 3F0 Within file RPCRT4.dll In RpcRaiseException at address 14 In InternalCStdIdentityGetIProxyManager at address 1CF6 Within file combase.dll In NdrClientCall3 at address 581 Within file RPCRT4.dll In WindowsCompareStringOrdinal at address 386 Within file combase.dll In ObjectStublessClient32 at address 7E62 In CoWaitForMultipleHandles at address BFC In HSTRING_UserMarshal64 at address DB8B In HSTRING_UserMarshal64 at address CF99

RAX = 0000000000000000 RBX = 0000000000000000 RCX = 000000000d7df6b0 RDX = 0000000000000178 RBP = 0000000000000000 RSI = 0000000000000001 RDI = 0000000080010012 RSP = 000000002005ea10 R8 = 00007fff115d68c4 R9 = 0035002d00000002 R10 = 0000000000000000 R11 = 0000000000000000 R12 = 0000000025402318 R13 = 000000002005ecd0 R14 = 0000000000000005 R15 = 00007fff0f91c458

7fff0e819f0a) db 0f,1f,44,00,00

I'm not sure why it reports this as 1st January 1970.

The FTN95 version is: Silverfrost FTN95/x64 Ver 9.10.4.0 I'm running Windows 11 Pro, Version 24H2

It happens whether I compile with Release, Debug or Checkmate.

15 Jun 2025 10:05 #32159

Actually, it has just crashed for a normal physical printer as well.

15 Jun 2025 2:01 #32160

Does it fail when using the old printer dialog?

Call USE_OLD_PRINT_DIALOG@(1) before SELECT_PRINTER@.

15 Jun 2025 11:20 #32162

Yes, it still crashes

16 Jun 2025 6:33 #32164

I don't get this failure on my machine so it looks like a Microsoft issue that only affects certain machines. (I am running Windows 11 24H2 and fully up to date.)

If the exception is 'advisory' (i.e. recovery and continuation is possible without intervention) then we could provide a fix or a routine to call.

16 Jun 2025 10:45 #32167

It is a very strange behaviour. After printing, it may or may not crash, but it definitely does with a pdf. The pdf is created and then a while later it just dies.

After last week, there are several men in white coats 'Coming to take me away - Ha-haaa'.

Help!!!

16 Jun 2025 10:47 #32168

Just a small point, I'm using the dlls which you provided on 8th April.

16 Jun 2025 3:01 #32169

Ian

You can use the latest FTN95 and DLLs downloadable from this Forum but there is no reason to expect any improvement for select_printer@.

17 Jun 2025 9:28 #32171

The problem occurred with FTN95/x64 Ver 9.10.4.0, with the dlls etc. dated 8th April 2025. I have returned to using Ver 9.10.0.0; the crash still occurs.

17 Jun 2025 9:44 #32172

The latest available update is to version 9.12 dated 31 May 2025.

See https://forums.silverfrost.com/Forum/Topic/3780.

18 Jun 2025 10:37 #32173

I've tried that and still have the same fault.

Please login to reply.