Skip to main content

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?
Acucobol includes a WEB-BROWSER control (which basically allows you to embed IE in your screen), so you could use that without doing anything extra (no .def or COM object needed).

If you want it to use the full IE separate from your window, just use the CALL "C$SYSTEM" call and pass it a command line of:

start \\path\\to\\your\\file.htm

This will start IE and load \\path\\to\\your\\file.htm.

To use IE as a COM object, you have to generate a .def file using the axdefgen utility that comes with Acucobol. See the help file for details.

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?
Web browser control. Very nice. I see the example in the UI Programming manual has the full slate of toolbars and buttons included. A generic browser I add to my program comes up with the file name I feed it but no buttons/toolbars. Is there a trick to enabling those?

Thanks for the help, btw.

-Tony

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?
Web browser control. Very nice. I see the example in the UI Programming manual has the full slate of toolbars and buttons included. A generic browser I add to my program comes up with the file name I feed it but no buttons/toolbars. Is there a trick to enabling those?

Thanks for the help, btw.

-Tony

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?
There is source for an example program using it included with Acucobol. Look in the sample directory for webbrows.cbl.

[Migrated content. Thread originally posted on 21 October 2004]

Hello. New to Cobol. Have a question I'm sure has been solved before. I have a report program that writes to a disk file. I would like to use Internet Explorer to view the file so the user can then scroll up/down, print, email, etc. I've seen posts where Word and Outlook are called via COM objects which require specific .DEF files. Is there a standard approach for doing the same with IE ? Where does one get a .DEF file or how do you create it?
Just a note: i had some problems using c$system when calling
IE ("start " that is). This in fact caused the runtime to crash. This problem was not experienced when calling adobe acrobat the same way ("start "). This
slight problem is easily solved by setting the CSYS-ASYNC flag which allows
the cobol-prgram to run independently from whatever program youre calling.