Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What deterrmines where we can copy and paste?
Message
De
29/04/2004 15:17:30
 
 
À
29/04/2004 15:13:27
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00899387
Message ID:
00899486
Vues:
14
Gheesh, thanks Elmer. I was worried that one day it might just stop working. Doesn't make sense when I think about it now I know, but you wouldn't believe how my day has gone so far... I should just call it quits and go home! :o) Nothing would surprise me today!

>Tracy,
>No, I don't think you are missing anything. It looks like you are handling (/reinventing) the copy and paste functionality with your own methods Grabit() or Grabthis() and Pastethis() in your base classes. I think that if you want to use the "built-in" cut,copy &paste functions you would need to have an active edit menu (whether visible or not) with Cut = BAR# _med_cut, Copy = BAR# _med_copy, Paste = BAR# _med_paste. At least that is how I have always implemented it.
>
>
>
>>Am I missing something? I have the below code in the rightclick method of a listbox:
>>
>>
>>DEFINE POPUP shortcut SHORTCUT RELATIVE FROM MROW(),MCOL()
>>		DEFINE BAR 1 OF shortcut PROMPT "COPY"
>>		ON SELECTION BAR 1 of shortcut _Screen.Activeform.GRABIT()
>>		ACTIVATE POPUP shortcut
>>
>>and the form's grabit method contains:
>>
>>PRIVATE nCnt
>>nCnt = THIS.lstSource.ListIndex
>>_cliptext = ALLTRIM(THIS.lstSource.LIST(ncnt))
>>RETURN
>>
>>I use it to copy a value to the clipboard and then I jump to Adobe Acrobat and past the value into a field property. It works and I do not have the edit menu enabled or visible at all.
>>
>>I do the same thing with textboxes':
>>
>>DEFINE POPUP shortcut SHORTCUT RELATIVE FROM MROW(),MCOL()
>>		DEFINE BAR 1 OF shortcut PROMPT "COPY"
>>		DEFINE BAR 2 OF shortcut PROMPT "PASTE"
>>		ON SELECTION BAR 1 of shortcut _Screen.ActiveForm.grabthis('oacordict.txtformfield')
>>		ON SELECTION BAR 2 OF shortcut _Screen.ActiveForm.pastethis('oacordict.txtformfield')
>>		ACTIVATE POPUP shortcut
>>RETURN
>>
>>
>>
>>
>>>I'm not sure, but I think that you have to have an edit menu enabled that contains the cut,copy, and paste options. If your menu has these options but is disabled, or you have no menu at all, copy and paste will not work. Check out Message #886627 or Message #892096 to see if these will offer a solution.
>>>
>>>HTH
.·*´¨)
.·`TCH
(..·*

010000110101001101101000011000010111001001110000010011110111001001000010011101010111001101110100
"When the debate is lost, slander becomes the tool of the loser." - Socrates
Vita contingit, Vive cum eo. (Life Happens, Live With it.)
"Life is not measured by the number of breaths we take, but by the moments that take our breath away." -- author unknown
"De omnibus dubitandum"
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform