Re: Send To Menu/Drag And Drop Question
- Posted by Bernie Ryan <xotron at bluefrog.com> Nov 11, 2006
- 517 views
Virtual B wrote: > > > Hi Everyone. > > I posted a question a while back, but didn't recieve a response. I know that > > usually means that noone has an answer, but I'm hoping that it just got missed > > in all the excitement about Euphoria going open-source. > > I want to write a program that will read a .txt file and search for certain > > criteria. The problem is that I need to make it very easy for the user by > allowing them to use Windows' Send To menu or Drag And Drop to initiate the > > program. I've been using Ed.bat and Ed.ex in this manner since I sarted > using Euphoria, but for the life of me, I just can't figure out how Ed knows > > which file needs to be opened. I would love to be able to do this without > using a batch file, or at least without having a DOS window pop up, but I'd > > be very grateful for any help in getting this to work any way possible. > > Thanks, > > Virtual B. I don't know if this is what you need to know or not ? In order for a program to know which program to process; your program has to process the command line to find what program was passed on the command line. You add a short-cut to your program in the C:\Windows\SendTo directory. Now when you right click on a file the SendTo menu will appear an the icon to your Euphoria progam should appear. If you then click on your program icon in the SendTo menu Windows will start your program and pass the name of the file that you first right click on to your Euphoria program's command line when it starts your program. It is up to your program to process the command line and use the file that was passed to it. Bernie My files in archive: WMOTOR, XMOTOR, W32ENGIN, MIXEDLIB, EU_ENGIN, WIN32ERU, WIN32API Can be downloaded here: http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan