Results for "Author: pj naughter"
Welcome to CSMTPConnection, a freeware MFC class to support the SMTP protocol. SMTP for those not familiar with all the internet protocols is the protocol used to send internet email. For detailed information about the Simple Mail Transfer Protocol you should read RFC 821, You can find numerous servers which carry these documents by going to www.yahoo.com and look for RFC and 821 and/or 2045. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. The code does not rely on the MFC socket classes. These classes have a number of shortcomings, one of which causes problems when they are used in NT services. The code can be used in a console application without any problems (Again this is not the case for the MFC socket classes). A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. As of v1.1, the classes now fully supports file attachments. Full support is included for CC (Carbon Copy) & BCC (Blind Carbon Copy). PJ Naughter at http://indigo.ie/~pjn/index.html
MFC class to support the PING/ICMP protocol. ICMP for those not familiar with all the internet protocols is the protocol used to retrieve information about how IP packets are routed. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. The enclosed zip file contains the CPing source code and a simple test program to exercise all of the functions the classes provide.
CMapi v1.0 an MFC class to encapsulate sending mail using Simple MAPI Welcome to CMapi, 2 simple classes to encapsulate sending mail using Simple MAPI. Simple MAPI is a set of functions exported by MAPI32.dll which allows you to send and receive mail in a transport independent way. It is an optional part of all Win32 operating systems since Windows 95 (excluding Windows CE). MAPI is intended more for the corporate environment when compared with the Internet mail standard SMTP e.g. products such as MS Exchange Server use MAPI extensively. Transport providers are available for a number of messaging transports including Exchange Server, SMTP, Fax, cc:Mail CompuServe etc. To be able to specify different transports, MAPI provides the concept of profiles which are setup using the Mail control panel applet Features Simple and clean C++ interface. All the code is UNICODE compliant and build configurations are provided for this. Even though Simple MAPI only exports an ASCII versions of it's functions, the class internally performs the necessary conversions. The code can be used in a console application or without bringing up any Mapi dialogs if so desired. The code gracefully handles the case where MAPI is not installed on client machines. Internally the class loads the DLL and uses GetProcAddress calls. The enclosed zip file contains the source code and a simple test program to exercise all of the functions the classes provide. PJ Naughter at http://indigo.ie/~pjn/index.html
A very simple utility to allow you to call the ShellExecute API from the command line. Places where you might find ShelExec useful are in adding an Autorun.inf file to your CD-R / CD-RW Discs. For example suppose you have a HTML page called index.htm on the root of your CD which you would like to run automatically whenever the user inserts the CD. All you need to do is put ShelExec.exe, some ico file and the index.htm files into the root directory and create a autorun.inf file with the following contents: [autorun] open=ShelExec.exe index.html icon=youricon.ico Items that ShelExec can handle include any file which is registered with the shell e.g. Word .Doc files, Text Files, batch files etc etc. It can also handle URLs such as "http://somesite.com", "ftp://www.microsoft.com" and "mailto:pjn@indigo.ie". The more technically minded of you may say why is there a need to have this program since you can use "start filename" on autorun CD's without any apparent problems. The problem with this approach is that it does not work on NT because on NT "start" is implemented as an "Internal" command in cmd.exe (as opposed to a standard exe on 95/98) with the upshot that your CD's will not AutoRun on NT 4 or Windows 2000. Using ShelExec will mean that your CD's will autorun on all OS's which support it. The zip file contains the ShelExec source code and a prebuilt version of ShelExec.
Memory mapping is a powerful mechanism Win32 provides to implement shared memory and also to access files though a simple memory pointer without having to implement your own home brewed buffering mechanisms. As an example its as simple as calling void* lpData = mmf.Open(); CharUpperBuff((char*) lpData, mmf.GetLength()); to convert a file (of any length) to upper case. Areas where you might find this of interest include very large database files with fixed records, audio processing, string operations and image processing. The other side of memory mapped files is to implement shared memory. As you will probably know, Win32 puts each process into its own address space, thus making it impossible to pass ordinary pointers across process boundaries. With memory mapped files you get back this very useful mechanism. The enclosed zip file contains the CMemMapFile source code and a simple dialog based application which demonstrates all the functionality of the class. For further details about the example program have a look at the BOOL CTestmemmapApp::InitInstance() function and the CDialog1 member functions both in testmemmap.cpp PJ Naughter at http://indigo.ie/~pjn/index.html
DynData v1.0 A collection of freeware MFC classes to encapsulate the Windows 95/98 performance counters. Ever wanted to write some code to determine the amount of bytes sent or received by Dial-Up Networking, what is the current CPU Usage or how many threads are currently running on the system?. The classes provided allow you do query any of these parameters, or to query the availability of performance objects and heir counters both on the local machine and any machine on the network. Please note that since NT has its own version of performance counters which are incompatible with the 95/98 versions, these classes will not work on NT. If you want classes to work with NT, have a look at the CPdh classes which I have developed.
Ever wanted to write some code to determine the amount of bytes sent or received by Dial-Up Networking, what is the current CPU Usage or how many threads are currently running on the system?. The classes provided allow you do query any of these parameters, or to query the availability of performance objects and their counters both on the local machine and any machine on the network. Please note that since 95/98 has its own version of performance counters which are incompatible with the NT versions, these classes will not work on 95/98. If you want classes to work with 95/98, have a look at the DynData classes which I have developed.
Welcome to CPop3Connection, a freeware MFC class to support the POP3 protocol. POP3 for those not familiar with all the internet protocols is the protocol used to retrieve internet email. For detailed information about the Post Office Protocol Version 3 you should read RFC 1725. You should also refer to RFC 822 which contains details on the layout of messages. You can find numerous Web Servers which carry these documents by going to www.yahoo.com and look for RFC and 1725 or 822.
Welcome to CSMTPConnection, a freeware MFC class to support the SMTP protocol. SMTP for those not familiar with all the internet protocols is the protocol used to send internet email. For detailed information about the Simple Mail Transfer Protocol you should read RFC 821, You can find numerous servers which carry these documents by going to www.yahoo.com and look for RFC and 821 and/or 2045. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. The code does not rely on the MFC socket classes. These classes have a number of shortcomings, one of which causes problems when they are used in NT services. The code can be used in a console application without any problems (Again this is not the case for the MFC socket classes). A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. As of v1.1, the classes now fully supports file attachments. Full support is included for CC (Carbon Copy) & BCC (Blind Carbon Copy). PJ Naughter at http://indigo.ie/~pjn/index.html
MFC class to support the PING/ICMP protocol. ICMP for those not familiar with all the internet protocols is the protocol used to retrieve information about how IP packets are routed. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. The enclosed zip file contains the CPing source code and a simple test program to exercise all of the functions the classes provide.
CMapi v1.0 an MFC class to encapsulate sending mail using Simple MAPI Welcome to CMapi, 2 simple classes to encapsulate sending mail using Simple MAPI. Simple MAPI is a set of functions exported by MAPI32.dll which allows you to send and receive mail in a transport independent way. It is an optional part of all Win32 operating systems since Windows 95 (excluding Windows CE). MAPI is intended more for the corporate environment when compared with the Internet mail standard SMTP e.g. products such as MS Exchange Server use MAPI extensively. Transport providers are available for a number of messaging transports including Exchange Server, SMTP, Fax, cc:Mail CompuServe etc. To be able to specify different transports, MAPI provides the concept of profiles which are setup using the Mail control panel applet Features Simple and clean C++ interface. All the code is UNICODE compliant and build configurations are provided for this. Even though Simple MAPI only exports an ASCII versions of it's functions, the class internally performs the necessary conversions. The code can be used in a console application or without bringing up any Mapi dialogs if so desired. The code gracefully handles the case where MAPI is not installed on client machines. Internally the class loads the DLL and uses GetProcAddress calls. The enclosed zip file contains the source code and a simple test program to exercise all of the functions the classes provide. PJ Naughter at http://indigo.ie/~pjn/index.html
A very simple utility to allow you to call the ShellExecute API from the command line. Places where you might find ShelExec useful are in adding an Autorun.inf file to your CD-R / CD-RW Discs. For example suppose you have a HTML page called index.htm on the root of your CD which you would like to run automatically whenever the user inserts the CD. All you need to do is put ShelExec.exe, some ico file and the index.htm files into the root directory and create a autorun.inf file with the following contents: [autorun] open=ShelExec.exe index.html icon=youricon.ico Items that ShelExec can handle include any file which is registered with the shell e.g. Word .Doc files, Text Files, batch files etc etc. It can also handle URLs such as "http://somesite.com", "ftp://www.microsoft.com" and "mailto:pjn@indigo.ie". The more technically minded of you may say why is there a need to have this program since you can use "start filename" on autorun CD's without any apparent problems. The problem with this approach is that it does not work on NT because on NT "start" is implemented as an "Internal" command in cmd.exe (as opposed to a standard exe on 95/98) with the upshot that your CD's will not AutoRun on NT 4 or Windows 2000. Using ShelExec will mean that your CD's will autorun on all OS's which support it. The zip file contains the ShelExec source code and a prebuilt version of ShelExec.
One of the posts that keeps reappearing in the programming newsgroups is how to enumerate all the serial ports installed. The problem is that there is no standard Win32 API call which allows serial port enumeration. The approach that this code uses is calling CreateFile directly. If the port cannot be opened, the code examines the error code to see if it was accessed denied error in which case it knows that the port exists even though it could not open the port. .
A very simple utility to allow you to call the ShellExecute API from the command line. Places where you might find ShelExec useful are in adding an Autorun.inf file to your CD-R / CD-RW Discs. For example suppose you have a HTML page called index.htm on the root of your CD which you would like to run automatically whenever the user inserts the CD. All you need to do is put ShelExec.exe, some ico file and the index.htm files into the root directory and create a autorun.inf file with the following contents: [autorun] open=ShelExec.exe index.html icon=youricon.ico Items that ShelExec can handle include any file which is registered with the shell e.g. Word .Doc files, Text Files, batch files etc etc. It can also handle URLs such as "http://somesite.com", "ftp://www.microsoft.com" and "mailto:pjn@indigo.ie". The more technically minded of you may say why is there a need to have this program since you can use "start filename" on autorun CD's without any apparent problems. The problem with this approach is that it does not work on NT because on NT "start" is implemented as an "Internal" command in cmd.exe (as opposed to a standard exe on 95/98) with the upshot that your CD's will not AutoRun on NT 4 or Windows 2000. Using ShelExec will mean that your CD's will autorun on all OS's which support it. The zip file contains the ShelExec source code and a prebuilt version of ShelExec.
Ever wanted to write some code to determine the amount of bytes sent or received by Dial-Up Networking, what is the current CPU Usage or how many threads are currently running on the system?. The classes provided allow you do query any of these parameters, or to query the availability of performance objects and their counters both on the local machine and any machine on the network. Please note that since 95/98 has its own version of performance counters which are incompatible with the NT versions, these classes will not work on 95/98. If you want classes to work with 95/98, have a look at the DynData classes which I have developed.
Welcome to CSMTPConnection, a freeware MFC class to support the SMTP protocol. SMTP for those not familiar with all the internet protocols is the protocol used to send internet email. For detailed information about the Simple Mail Transfer Protocol you should read RFC 821, You can find numerous servers which carry these documents by going to www.yahoo.com and look for RFC and 821 and/or 2045. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. The code does not rely on the MFC socket classes. These classes have a number of shortcomings, one of which causes problems when they are used in NT services. The code can be used in a console application without any problems (Again this is not the case for the MFC socket classes). A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. As of v1.1, the classes now fully supports file attachments. Full support is included for CC (Carbon Copy) & BCC (Blind Carbon Copy). PJ Naughter at http://indigo.ie/~pjn/index.html
MFC class to support the PING/ICMP protocol. ICMP for those not familiar with all the internet protocols is the protocol used to retrieve information about how IP packets are routed. Features Simple and clean C++ interface. The interface provided is synchronous which provides an easier programming model than using asynchronous sockets. A configurable timeout for the connection can be set through the class API. The classes are fully Unicode compliant and include Unicode built options in the workspace file. The enclosed zip file contains the CPing source code and a simple test program to exercise all of the functions the classes provide.
3Mfc 1.1 A collection of freeware MFC classes to implement a Web Server Welcome to W3Mfc, a collection of freeware MFC classes to implement a simple Web server. The idea behind is W3Mfc was originally to learn about the Http protocol and how it is implemented on Win32. It is not intended to be a replacement for IIS or Apache. Instead it is designed as a tool for learning or in cases where deployment of a solution on IIS would be considered overkill or your product must run on 95/98 in addition to NT. For detailed information about the Hyper Text Transfer Protocol you should read RFC 1945, You can download this from a number of sites by searching for RFC and 1945 on www.yahoo.com. Another document that these classes refer to is RFC 2045 which defines MIME. The classes which constitute W3Mfc are: CHttpServerSettings: This class contains the settings which are used to configure the web server. Example member variables in this class include the root directory and the default filename. If you are developing a stand alone web server based on W3Mfc, you could for example store all the variables for the CHttpServerSettings instance in an ini file or in the registry. In the future this is the class which will be extended to include additional settings such as multiple virtual directories. CHttpServer: This is the actual class which implements the web server. It has a number of very simple functions to allow you to control the state of the web server such as Start and Stop. Internally a background thread is spun off to handle the client connections. CHttpSocket: This is a simple C++/MFC encapsulation of an SDK socket. CHttpResponseHeader: This class helps in the handling of sending request headers when returning the HTTP responses to clients. It provides a number of methods to allow standard Http headers to be added to the client response. CHttpMimeManager: This class is used when returning client responses. It is used to determine the mime type of a file given its extension type. This information is taken from the registry and is cached in this class. For example, files of .htm or .html will normally be of mime type "text/html". CHttpRequest: This class represents a request from a client. It contains information such as the URI of the request, the Http Verb used and the Http version used for the request. A member of this type is stored in the CHttpClient class. CHttpClient: This class is used in the CHttpServer class to handle client connections. It handles the parsing of client requests and returning the appropriate response. A number of virtual functions are provided to allow end user customization. The enclosed zip file contains the W3Mfc source code and a simple console based application which implements a simple web server. PJ Naughter at http://indigo.ie/~pjn/index.html
CMapi v1.0 an MFC class to encapsulate sending mail using Simple MAPI Welcome to CMapi, 2 simple classes to encapsulate sending mail using Simple MAPI. Simple MAPI is a set of functions exported by MAPI32.dll which allows you to send and receive mail in a transport independent way. It is an optional part of all Win32 operating systems since Windows 95 (excluding Windows CE). MAPI is intended more for the corporate environment when compared with the Internet mail standard SMTP e.g. products such as MS Exchange Server use MAPI extensively. Transport providers are available for a number of messaging transports including Exchange Server, SMTP, Fax, cc:Mail CompuServe etc. To be able to specify different transports, MAPI provides the concept of profiles which are setup using the Mail control panel applet Features Simple and clean C++ interface. All the code is UNICODE compliant and build configurations are provided for this. Even though Simple MAPI only exports an ASCII versions of it's functions, the class internally performs the necessary conversions. The code can be used in a console application or without bringing up any Mapi dialogs if so desired. The code gracefully handles the case where MAPI is not installed on client machines. Internally the class loads the DLL and uses GetProcAddress calls. The enclosed zip file contains the source code and a simple test program to exercise all of the functions the classes provide. PJ Naughter at http://indigo.ie/~pjn/index.html
Memory mapping is a powerful mechanism Win32 provides to implement shared memory and also to access files though a simple memory pointer without having to implement your own home brewed buffering mechanisms. As an example its as simple as calling void* lpData = mmf.Open(); CharUpperBuff((char*) lpData, mmf.GetLength()); to convert a file (of any length) to upper case. Areas where you might find this of interest include very large database files with fixed records, audio processing, string operations and image processing. The other side of memory mapped files is to implement shared memory. As you will probably know, Win32 puts each process into its own address space, thus making it impossible to pass ordinary pointers across process boundaries. With memory mapped files you get back this very useful mechanism. The enclosed zip file contains the CMemMapFile source code and a simple dialog based application which demonstrates all the functionality of the class. For further details about the example program have a look at the BOOL CTestmemmapApp::InitInstance() function and the CDialog1 member functions both in testmemmap.cpp PJ Naughter at http://indigo.ie/~pjn/index.html