B4J Question Printhtml.exe Problem in Windows 8.1

behnam_tr

Active Member
Licensed User
Longtime User
hi

i have problem with printhtml.exe in windows 8.1 and probably windows 10
but its ok in windows 7

i tested some ways but no chance

update .NetFreamwork
run as administrator
move app to c:/ and other writeable Folders
installing two or more pdfprinter
i also test Erel Example

After clicking on the button, a text file is created, but after that, the program has no reaction. The program also has no error.
B4X:
Sub btnPrint_Action
    Dim js As Shell
    Dim params As List
    params.Initialize
    'save the text to a file. New lines characters are replaced with <br/>.
    File.WriteString(File.DirApp, "temp.txt", txtArea.Text.Replace(CRLF, "<br/>" & CRLF))
    If printer.Text <> "" Then params.Add("printername=" & printer.Text)
    params.Add("file=temp.txt")
    js.Initialize("js", "printhtml.exe", params)
    js.WorkingDirectory = File.DirApp
    js.Run(-1) 'run with no timeout
    btnPrint.Enabled = False
End Sub

Sub js_ProcessCompleted (Success As Boolean, ExitCode As Int, StdOut As String, StdErr As String)
    Log("Success=" & Success & ", StdOut=" & StdOut & ", StdErr=" & StdErr)
    btnPrint.Enabled = True
End Sub
 

EnriqueGonzalez

Well-Known Member
Licensed User
Longtime User
Upvote 0

behnam_tr

Active Member
Licensed User
Longtime User
thanks
yes i install DHTML on windows 8
i think windows 8 does not support DHTML.
 
Last edited:
Upvote 0
Top