Great! We all love "really cool"

> -----Original Message-----
> From: [email protected] [mailto:[email protected]] On Behalf Of Doug
> Hamilton
> Sent: Wednesday, February 18, 2015 10:10 AM
> To: RBASE-L Mailing List
> Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> 
> Dennis & Karen - here's more detail.
> The data gets pasted into a Variable Memo control, component ID
> "cidPasteText", variable name vPasteText.
> The variable vPasteText already has a short description that appears in
> the control for the operator's benefit, "Double click here to paste text."
> 
> This is part of the code from the On Double Click EEP:
> 
> --First clear the operator message. The PasteFromClipboard property
> appends, not overwrites.
> SET VAR vPasteText = ''
> RECALC VARIABLES
> --Paste the text into the control
> PROPERTY cidPasteText PASTEFROMCLIPBOARD 'TRUE'
> --Load the pasted text into the variable, don't have worry about
> changing focus or inadvertent editing
> SET VAR vPasteText = (CVAL('CLIPBOARDTEXT'))
> --Pasted text is usually larger than what's visible in the control, so
> move to first character, top of text
> --There are also several error checks, operator can now see the
> pertinent part of the pasted text
> PROPERTY cidPasteText FIRSTCHAR 'TRUE'
> --Do what I have to do.  Processing continues without any further
> operator intervention ....
> 
> Thanks again for your help.
> It turned out really cool.  :)
> Doug
> 
> On 2/18/2015 8:30 AM, Dennis McGrath wrote:
> > Doug is eliminating the problem by populating the variable AND the control
> display, probably something like this:
> > set var vPasteText = (CVAL('CLIPBOARDTEXT'))  -- populate the variable
> > PROPERTY VariableMemo PasteFromClipboard 'TRUE' -- populate the
> control display (without resorting to RECALC VARIABLES or FOCUS)
> >
> > Dennis McGrath
> >
> > From: [email protected] [mailto:[email protected]] On Behalf Of Karen
> Tellef
> > Sent: Wednesday, February 18, 2015 8:20 AM
> > To: RBASE-L Mailing List
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> >
> > One caveat to Doug's code:  the button would need to NOT be a "speed
> button", right?  Because a speed button doesn't change focus?
> >
> > Karen
> >
> >
> >
> > -----Original Message-----
> > From: Dennis McGrath <[email protected]>
> > To: RBASE-L Mailing List <[email protected]>
> > Sent: Wed, Feb 18, 2015 8:16 am
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> > Great Doug,
> >
> > I thought you might go that way.
> >
> > Razzak’s method is great when the user might be pasting multiple times,
> building a final result.
> >
> > Your’s will assure that only the last paste populates your control.
> >
> > Dennis McGrath
> >
> > From: [email protected] [mailto:[email protected]] On Behalf Of Doug
> Hamilton
> > Sent: Tuesday, February 17, 2015 6:12 PM
> > To: RBASE-L Mailing List
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> >
> > OK, got it working.
> > What we're doing is pasting an entire screen of mainframe data and then
> using certain fields for order entry, so the screen doesn't need to be edited.
> > The most foolproof (and we know where this is gonna go...) is to use
> > set var vPasteText = (CVAL('CLIPBOARDTEXT'))
> > I've put it in a double-click EEP in the target variable memo control.
> > That way I don't have to worry about changing focus; heck I don't even
> have to paste the text into the variable memo control, but it's good to show
> it for operator comfort level.
> >
> > It's cool - they copy the entire mainframe screen and double click on the
> memo control and - poof!  It's all processed!
> >
> > Thanks Razzak, Karen and Dennis for your help.
> > Doug
> > On 2/17/2015 4:36 PM, Dennis McGrath wrote:
> >     PROPERTY VariableMemo PasteFromClipboard 'TRUE'
> >     PROPERTY VariableMemo SET_FOCUS 'TRUE'
> >     PROPERTY VariableMemo LASTCHAR 'TRUE'
> >     Property Btn_Paste SET_FOCUS 'TRUE'  --pull focus away so  variable gets
> updated
> >     Pause 1 using .vPasteText – looking good!
> >
> > From: [email protected] [mailto:[email protected]] On Behalf Of A.
> Razzak Memon
> > Sent: Tuesday, February 17, 2015 4:18 PM
> > To: RBASE-L Mailing List
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> >
> > Doug,
> >
> > For PasteTextFromClipBoard.rff form, update the "On Click EEP" for [Paste
> Text from Windows Clipboard] button as follows:
> >
> >     PROPERTY VariableMemo PasteFromClipboard 'TRUE'
> >     PROPERTY VariableMemo SET_FOCUS 'TRUE'
> >     PROPERTY VariableMemo LASTCHAR 'TRUE'
> >
> > This will also allow users to add further text at the end, if they wish.
> >
> > SHOW VARIABLE vPasteText should return the correct value.
> >
> > That's all there is to it!
> >
> > Have fun!
> >
> > Razzak
> > -----Original Message-----
> > From: Doug Hamilton <[email protected]>
> > To: [email protected] (RBASE-L Mailing List)
> > Date: Tue, 17 Feb 2015 16:05:06 -0600
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> >
> > Yeah, that does it.  Thanks Karen.
> > But the pasting is done by a separate button that has the
> PasteFromClipBoard property.  So to get it to work, I click the Paste button
> (which pastes the text into the variable memo control), then click the
> variable memo control and then tab off it.  The variable vPasteText is then
> updated.
> > After the PASTE property, I'll try programmatically setting focus on the
> Variable Memo and then off of it.
> > Seems like extra horsing around - I tried RECALC VARIABLES but that didn't
> work.  Is there an equivalent PROPERTY command?
> >
> > Hmm, maybe I'll put the PASTE property in a double-click EEP on the
> Variable Memo control itself and then programmatically advance to the next
> field.
> > Doug
> > On 2/17/2015 3:23 PM, Karen Tellef wrote:
> > Doug:  have you "moved off" the variable memo field?  This has tripped me
> up before.  Until you move off the field you haven't "saved" the value into
> the variable.  You might have to have the eep advance to the next field after
> the paste?
> >
> > Karen
> >
> >
> >
> > -----Original Message-----
> > From: Doug Hamilton <[email protected]>
> > To: RBASE-L Mailing List <[email protected]>
> > Sent: Tue, Feb 17, 2015 3:15 pm
> > Subject: [RBASE-L] - Re: PROPERTY PASTEFROMCLIPBOARD
> > Thank you Razzak.
> > I'm able to run the PasteTextFromClipBoard external form and text gets
> pasted into the Variable Memo control (variable = vPasteText) when I click
> the Paste button.
> > But when I sho var, the variable vPasteText is null.
> > Shouldn't it contain the pasted text?
> > If I do a Ctrl-V and manually paste text into the Variable Memo control, the
> text gets pasted and the variable vPasteText contains the pasted text.
> > That's what I'm trying to accomplish.
> > Am I misunderstanding the PasteFromClipBoard property?
> >
> > Thanks much for your help.
> > Doug
> > 9.5.5.20214 (32)
> > On 2/16/2015 6:37 PM, A. Razzak Memon wrote:
> > At 06:47 PM 2/16/2015, Doug Hamilton wrote:
> >
> > I give up, how does it work?
> >
> > I've got a Variable Memo control for the variable vPasteText, component ID
> > cidPasteText. On a DoubleClick EEP for the Variable Memo, I have:
> > PROPERTY cidPasteText PASTEFROMCLIPBOARD TRUE
> >
> > As I TRACE, the text gets pasted into the Variable Memo control, but the
> > variable vPasteText remains null.
> >
> > RECALC VARIABLES doesn't work and I've tried TRUE and 'TRUE'.
> >
> > Attributes Word Wrap, How Hint and Tab Stop are the only ones checked.
> > None of the Cut, Copy and Paste Settings are checked to prevent the
> > respective action.
> > Here's a sample that illustrates the use of such property ...
> >
> >
> http://www.Razzak.com/SampleApplications/files/PasteTextFromClipBoard.
> zip
> >
> > This is an External Form File and you should be able to run from any
> > R:BASE eXtreme 9.5 session regardless of the connected database.
> >
> > Have fun!
> >
> > Very Best R:egards,
> >
> > Razzak
> >
> >
> >
> 
> --- RBASE-L
> ================================================
> TO POST A MESSAGE TO ALL MEMBERS:
> Send a plain text email to [email protected]
> 
> (Don't use any of these words as your Subject:
> INTRO, SUBSCRIBE, UNSUBSCRIBE, SEARCH,
> REMOVE, SUSPEND, RESUME, DIGEST, RESEND, HELP)
> ================================================
> TO SEE MESSAGE POSTING GUIDELINES:
> Send a plain text email to [email protected]
> In the message SUBJECT, put just one word: INTRO
> ================================================
> TO UNSUBSCRIBE:
> Send a plain text email to [email protected]
> In the message SUBJECT, put just one word: UNSUBSCRIBE
> ================================================
> TO SEARCH ARCHIVES:
> Send a plain text email to [email protected]
> In the message SUBJECT, put just one word: SEARCH-n
> (where n is the number of days). In the message body,
> place any
> text to search for.
> ================================================
> 

Reply via email to