I have a small exe file written in VB.NET which connects to database, gets the last row and send the information to the printer. It is just a small part of a program but it uses special font and also calculates the widths for the printer.
I’ve developed the same program with PHP. Now almost every functionality of it is same wirh the windows based program. But the printing results of the web browser can’t be same as I get with the exe file. So I want to just send a paramater to the exe file and run it. (with a javascript call or else) Exe file is on the client machine and I will know where it is the located.
Can you suggest me a way to do that.
I read that this is possible using dll or ocx.
I’m not familiar developing browser plugins.
Is there a tutorial or book for that?
Thanks in advance.
If my machine suddenly asked me if it was ok for a website to download and run an exe, I’d have closed the window before the dialog had finished rendering.
The simplest thing to do here would be to fix the formatting of the php’s output. Just because you can potentially execute an exe file on the client is a million miles away from meaning you should. Unless you know and have complete control over the users and the systems that those users are working on, any exe related system is going to be brittle at best and even if you do have that control, it’s a bodge.
There are pdf libraries written for php that would permit you better control over your outputs, including fonts. There’s a write up of one such library over at Sitepoint.
Alternatively, you could probably turn your .NET app into a web app/service that your php could communicate with.