Popular recipes tagged "messenger"http://code.activestate.com/recipes/tags/messenger/2012-02-03T01:41:41-08:00ActiveState Code RecipesBatch Local Network Messaging System (Batch) 2012-02-03T01:41:41-08:00Alexander James Wallarhttp://code.activestate.com/recipes/users/4179768/http://code.activestate.com/recipes/578028-batch-local-network-messaging-system/ <p style="color: grey"> Batch recipe 578028 by <a href="/recipes/users/4179768/">Alexander James Wallar</a> (<a href="/recipes/tags/alex/">alex</a>, <a href="/recipes/tags/batch/">batch</a>, <a href="/recipes/tags/batch_file/">batch_file</a>, <a href="/recipes/tags/dos/">dos</a>, <a href="/recipes/tags/messaging/">messaging</a>, <a href="/recipes/tags/messenger/">messenger</a>, <a href="/recipes/tags/network/">network</a>, <a href="/recipes/tags/wallar/">wallar</a>, <a href="/recipes/tags/windows/">windows</a>, <a href="/recipes/tags/wired/">wired</a>, <a href="/recipes/tags/wired_network/">wired_network</a>). Revision 3. </p> <p>This is a Batch Local Messaging System that can be used to send messages between computers that share the same file system.</p> <p>There are three files in the code below. They are separated with dashed lines. There is a comment on the top of each segment of code indicating the file name that the code needs to be saved as. They need to be saved as three separate batch files in the same folder. </p> <p>The first file, MessengerMain.bat will ask you for your name and then an address. The name should be whatever you wish your screen name to be. The address needs to be the path of the FOLDER that is shared between you and the other computer that you are communicating with. Once these pieces of information are entered, two screens will appear. The first is the Sender screen and the other is the Receiver screen. </p> <p>How does it work? The MessengerMain.bat file will create two text files, Name.txt and Address.txt, that will hold your user name and the common folder address. It will then use the START command to run Sender.bat and Receiver.bat. Sender.bat will create a text file named msgtext.txt in the address folder you specified in MessengerMain.bat. If there is already a file of this sort in existence in the address folder, it will overwrite it. Once this file is created, any message you enter will be saved in the msgtext.txt file after the name you entered (%name%: %msg%). Sender.bat the CLS (clears) the screen and asks you for another message continuously. Receiver.bat is very similar. Receiver.bat, first off, reads the Address.txt file and the Name.txt file to find your information given in MessengerMain.bat just like Sender.bat does. It will count the number of lines in the msgtext.txt file and will clear the whole screen and print out the whole contents of the file if the number of lines in msgtext.txt increases. So basically you are writing to a shared file and reading from a shared file. </p> <p>Example:</p> <p>I have a folder called MSGFolder located in the folder as I have my MessengerMain.bat, Receiver.bat, and Sender.bat files. I then run MessengerMain.bat by double clicking on the icon. I enter Alex for my Name and MSGFolder as the Address. I then double click MessengerMain.bat again and enter the name Bob for Name and MSGFolder for Address. Once you do this you can type in either of the Sender.bat interfaces and it will show up as if you are talking. </p> File Share Messenger 2.5 (Python) 2011-04-06T02:45:15-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577638-file-share-messenger-25/ <p style="color: grey"> Python recipe 577638 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/file_io/">file_io</a>, <a href="/recipes/tags/file_share/">file_share</a>, <a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/messenger/">messenger</a>, <a href="/recipes/tags/network/">network</a>, <a href="/recipes/tags/workaround/">workaround</a>). </p> <p>After writing the limited program shown in <a href="http://code.activestate.com/recipes/577637/">recipe 577637</a>, the following program was written with a better yet incompatible I/O system designed not to fill up a file share with many, separate files. This program had five revisions as outlined within the source code. To access settings within this program, use the "F2" key. Documentation may be accessed via the "F1" key (with future plans cut).</p> <p>If anyone wishes to comment or vote this recipe down, please provide your insight into the fault(s) of the program and provide a suggestion as to what solution you would implement to fix the problems.</p> File Share Messenger 1.0 (Python) 2011-04-06T00:03:20-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577637-file-share-messenger-10/ <p style="color: grey"> Python recipe 577637 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/file_io/">file_io</a>, <a href="/recipes/tags/file_share/">file_share</a>, <a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/messenger/">messenger</a>, <a href="/recipes/tags/network/">network</a>, <a href="/recipes/tags/workaround/">workaround</a>). </p> <p>File I/O has many potential uses, and in the case of network file shares, messaging can be conducted by creating files in a directory and scanning for new files to find new messages. In the case where there are restrictions within a network that prevent opening server sockets or creating and using client sockets, the technique in this recipe may be used with file shares instead. The program is simple and was written in about fifty minutes, so there are a great deal of enhancements that could be made to the recipe and its capabilities. Hopefully, this will provide inspiration for other program writers.</p> <p>If you have any comments or wish to down-vote this recipe, please provide your insight as to what could be improved upon and how you would go about fixing any problems that you might find.</p> FSM 2.5 Reader (Python) 2011-04-06T03:02:57-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577639-fsm-25-reader/ <p style="color: grey"> Python recipe 577639 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/commandline/">commandline</a>, <a href="/recipes/tags/file_io/">file_io</a>, <a href="/recipes/tags/file_share/">file_share</a>, <a href="/recipes/tags/messenger/">messenger</a>, <a href="/recipes/tags/network/">network</a>, <a href="/recipes/tags/workaround/">workaround</a>). </p> <p>For those who would want to search the message logs produced by <a href="http://code.activestate.com/recipes/577638/">recipe 577638</a>, this program provides a command-line solution to searching messages according to their authors. If this program is placed in the message directory, the program may be executed on the command-line with the author's name as an argument. If and when the program is executed without an argument, usage information is shown on the screen before exiting. If an author was not found, the author's name is printed stating that nothing could be found. If a matching file was found, all timestamps and messages will be displayed that could be decoded correctly.</p> <p>If there are any recommendation for this recipe or if anyone wishes to down-vote this recipe, please provide corrective criticism showing the the program's faults and give suggestions on how you would fix any problems that it might have.</p>