Information générale
Catégorie:
Codage, syntaxe et commandes
Titre:
KeyPress Enter Loop
Wanted to add logic to the KeyPress of a textbox to perform some code that is part of a cmd.click. It is not working as I would like. Outside of the developer it is in a loop and eventually I have to hard restart my machine because it keeps opening new windows of IE. If I go into the debugger on the assert .f. it works fine.
KEYPRESS
LPARAMETERS nKeyCode, nShiftAltCtrl
IF nKeyCode = 13 and nShiftAltCtrl = 0
assert .f.
THIS.Parent.Cmd_search_pa.click()
Keyboard "{ENTER}"
NODEFAULT
ENDIF
CMD_SEARCH.PA.CLICK
oIE = CreateObject("InternetExplorer.Application")
save_number = alltrim(left(m.pst1,at(' ',m.pst1)))
save_name = alltrim(upper(right(m.pst1,len(m.pst1)-at(' ',m.pst1))))
save_name = alltrim(strTRAN(save_name, ' ', '%20'))
URL = 'http://www.scpafl.org/pls/web/re_web.show_pads?pad='+save_name+'&pad_num='+save_number
oIE.Navigate(URL)
oIE.Visible = .t.
Thanks
Brenda
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement