Mike :) Posted December 29, 2005 Share Posted December 29, 2005 Hello! I was wondering if there's any method to apply Opt('SendKeyDownDelay') to some of sent keys and to some not? Well, of course I could do f.ex. Opt('SendKeyDownDelay',1) Send ('2') Opt('SendKeyDownDelay', 100) Send('{SPACE}') But I think it's too noobie method... though I have no ideas Is there anything I can do like $var = Opt('SendKeyDownDelay',1) $var2 = Opt('SendKeyDownDelay', 100) Send('2',$var) Send('{SPACE}',$var2) ?? ( I know it's a bad code, I was just giving example to make my idea easier to understand ) Link to comment Share on other sites More sharing options...
Developers Jos Posted December 29, 2005 Developers Share Posted December 29, 2005 SendStr('2',10) Sendstr('{SPACE}',100) Func Sendstr($istr,$idelay) Opt('SendKeyDownDelay',$idelay) Send ($istr) EndFunc SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Mike :) Posted December 29, 2005 Author Share Posted December 29, 2005 Thanks a lot JdeB, I'd never write such code, although it's not what I actually meant. I'm going to run my script on old laptop (Dell, 400MhZ PII) with NO graphics accelerator, with turned on game that requires it, so... I need it to save as much CPU as possible... what you just written is great, but it still does the SendKeyDownDelay option, I don't know if it's the best solution. Well, still I might be wrong, maybe changing options doesn't affect the CPU at all? Link to comment Share on other sites More sharing options...
LxP Posted December 29, 2005 Share Posted December 29, 2005 Changing an Opt() will have minimal CPU stress, and also it's the only way to do what you need. Link to comment Share on other sites More sharing options...
Developers Jos Posted December 29, 2005 Developers Share Posted December 29, 2005 Thanks a lot JdeB, I'd never write such code, although it's not what I actually meant.I'm going to run my script on old laptop (Dell, 400MhZ PII) with NO graphics accelerator, with turned on game that requires it, so... I need it to save as much CPU as possible... what you just written is great, but it still does the SendKeyDownDelay option, I don't know if it's the best solution. Well, still I might be wrong, maybe changing options doesn't affect the CPU at all?Stop assuming and just try to see if it works for you.. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Mike :) Posted December 29, 2005 Author Share Posted December 29, 2005 Changing an Opt() will have minimal CPU stress, and also it's the only way to do what you need.Well, all I can say is Stop assuming and just try to see if it works for you.. I'll surelly do this, as soon as i finish it Thanks for help again! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now