Prev: access a network folder in the SYSTEM account process
Next: _tcstok_s not tokenizing as expected
From: Jackie on 8 Jul 2010 09:01 yodadrinkslager wrote: > After finally getting Detours to build (seems VS2008 doesnt support > makerfiles any more so had to use VS2005) I have my detour dll working > but the problem is the calls are coming from Python. I dont know > which exe to inject with my dll :-( > > Allan I'm using MS Detours Express 2.1 (not for commercial use) which works fine for me with VS 2008 and 2010. It's safer to use than the old one. Now, I don't really know much about Python but it should be easy to find out which executable to launch and provide the path to the script as a parameter. Documentation for Python: http://docs.python.org/using/index.html Please look under "1.1 Command line". If you want to "fix" the script a bit, just take a bit of Googling and make up something simple like.. 1. Take a certain command line parameter that your launcher specifies. This indicates whether to set the cursor position. 2. If the parameter is present or a specific value, call SetCursorPos in the script. Sounds simple at least but I haven't really coded in Python before. I can still even try to help if you would like that (because it _sounds_ simple, at least). -- Regards, Jackie
From: Jackie on 8 Jul 2010 09:21 http://docs.python.org/tutorial/interpreter.html#argument-passing Launching script: python "thescript.py" '-no-setcursorpos' In script: if sys.argv[1] == "-no-setcursorpos": Set the cursor pos here (cut'n'paste old code) Something like this, maybe? Again, I don't code in Python (actually I think this is the first time I tried to write Python code), so I can't guarantee that it works (I don't even have the Python interpreter installed). I am not used to not ending if's and such so my guess is that you need to indent lines properly. Please pardon me if I am giving you false information. -- Regards, Jackie
From: Jackie on 8 Jul 2010 09:24 Jackie wrote: > if sys.argv[1] == "-no-setcursorpos": Sorry, please change this to "not equals". -- Regards, Jackie
From: yodadrinkslager on 8 Jul 2010 10:08 On 8 July, 14:24, Jackie <Jac...(a)an.on> wrote: > Jackie wrote: > > if sys.argv[1] == "-no-setcursorpos": > > Sorry, please change this to "not equals". > > -- > Regards, > Jackie Thanks for the info Jackie. Unfortunately I cant find where in the python code the cursor pos is being set otherwise I would have just removed it. Our python codebase is rather large! Thanks Allan
From: yodadrinkslager on 8 Jul 2010 10:12 On 8 July, 14:01, Jackie <Jac...(a)an.on> wrote: > I'm using MS Detours Express 2.1 (not for commercial use) which works > fine for me with VS 2008 and 2010. It's safer to use than the old one. Just to clarify, my problem was building the detour.bin file. For some reason when I tried from VS2008 it didnt know what nmake was. Once I added that to the path, it then failed knowing what rc.exe was. Doing this from VS2005 worked fine (after I already wasted an hour trying to get 2008 working). Once the bin file was compiled, I can use detours fine in VS2008. Cheers Allan
First
|
Prev
|
Next
|
Last
Pages: 1 2 3 Prev: access a network folder in the SYSTEM account process Next: _tcstok_s not tokenizing as expected |