Alan/Bruce:

Thank-you so much for your detailed response. Greatly appreciated. I 
apologize for my tardiness in getting back to you on my success – or 
lack thereof – in getting it to work.

I have never done anything with scripts – so am going to ask first 
about using config to accomplish my task.

I set-up my hotkey:
"Enter command, or select…" => field=win.getfocus

My bar item is:
"Enter command, or select…" => win.setfocus(field) 
(I assume I use the actual word "field" versus the name of my field.)
"Enter more commands with button…" => *Keys Testing

Here's what I do and what happens:
1.      Click in field
2.      run hotkey
3.      click bar item
Nothing happens.
4.      Click back in field and text automatically gets keyed in.

My understanding is that I would not have to click back into the 
field – so I might be doing something wrong. Any ideas?

I couldn't get the "paste" config you suggested to work. It works in 
something like Windows Notepad – but not in the field. It just can't 
seem to find the focus.

In terms of the script:
Like with the paste config above, it doesn't find focus. When 
executed in something like Windows Notepad, it pastes the last item 
from the clipboard 4 times instead of pasting the text from the 
script! As well, you suggested calling the file paster.powerpro. 
When I do so, I get an error message "Cannot access script file 
paster". If I call it simply "paster", it does what I stated in the 
first sentence of this paragraph. It fires – but not properly.
Any ideas?

Dave


--- In [email protected], Alan Martin <[EMAIL PROTECTED]> wrote:
>
> Hello ajzbc,
> 
> I think the following workaround is as close as possible to your 
design.
> I did not test it here because I do not have your database program
> nor Outlook 2003.
> 
> You need only one hotkey.
> Only two user actions are necessary: press the hotkey when the
> cursor is in the target field, then click the desired bar button.
> 
> The hotkey's command: field=win.getfocus
> 
> For every item on the bar:
> Command: win.setfocus(field)
> More commands:
> wait.for(100)
> keys your text for this button
> 
> Note: the wait.for(100) might not be needed.
> Try it with no wait, or experiment with longer or shorter
> waits to find the minimum wait which makes it work.
> 
> --------------------------------------------------------
> 
> Disadvantage: two user actions are necessary.
> 
> Advantages:
> - only one hotkey to remember
> - no need to click back into the target field to focus it
> - no need to use Ctrl-v
> 
> - no need to keep the bar showing all the time;
> you can show it only after the hotkey is pressed.
> 
> To do that, uncheck OnTop in the bar's properties
> and change your hotkey to:
> 
> Command: field=win.getfocus
> More commands: bar show mybar
> 
> -------------------------------------------------------
> 
> Maybe you will find that Pasting into the field is faster
> and more reliable than using a Keys command.
> You can do that in a way which does not change the clipboard
> in case it contains something useful.
> 
> Set the same hotkey as above, and every button does this:
> 
> Command: win.setfocus(field)
> More commands:
> oldclip=clip.get
> wait.for(100)
> clip.setpaste("your text for this button")
> clip.set(oldclip)
> 
> Note: experiment with shorter/longer/no wait
> 
> -----------------------------------------------------
> 
> If you often change the text to be pasted for each button,
> maybe you will prefer editing a text file script, instead of
> using the pproconf dialogs to change the bar's command list.
> 
> Same hotkey: Command: field=win.getfocus
> More commands: bar show mybar
> 
> The first button on the bar has a permanent command like this:
> Command: [EMAIL PROTECTED]
> 
> for the second button:
> Command: [EMAIL PROTECTED]
> 
> etc
> 
> Save the following as paster.powerpro in your powerpro\scripts 
folder.
> 
> ;; ------------- paster.powerpro -------
> 
> @one
> thistext = "text for button one"
> [EMAIL PROTECTED]
> 
> @two
> thistext = "text for button two"
> [EMAIL PROTECTED]
> 
> @three
> thistext = "text for button three"
> [EMAIL PROTECTED]
> 
> @common
> oldclip=clip.get
> win.setfocus(field)
> wait.for(100) ;; [experiment with this]
> clip.setpaste(thistext)
> clip.set(oldclip)
> quit
> 
> ;; ------------- end of paster.powerpro --------
>







------------------------ Yahoo! Groups Sponsor --------------------~--> 
See what's inside the new Yahoo! Groups email.
http://us.click.yahoo.com/2pRQfA/bOaOAA/yQLSAA/JV_rlB/TM
--------------------------------------------------------------------~-> 

Attention: PowerPro's Web site has moved: http://www.ppro.org 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/power-pro/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to