Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

GetFocus – PB Docs 150 – PowerBuilder Library

GetFocus – PB Docs 150

GetFocus event

Description

Occurs just before the control receives focus (before it is
selected and becomes active).

GetFocus applies to all controls

Event ID

Event ID

Objects

pbm_bnsetfocus

CheckBox, CommandButton, Graph, OLE,
Picture, PictureHyperLink, PictureButton, RadioButton

pbm_cbnsetfocus

DropDownListBox, DropDownPictureListBox

pbm_dwnsetfocus

DataWindow

pbm_ensetfocus

SingleLineEdit, EditMask, MultiLineEdit,
StaticText, StaticHyperLink

pbm_lbnsetfocus

ListBox, PictureListBox

pbm_lvnsetfocus

ListView

pbm_rensetfocus

RichTextEdit

pbm_sbnsetfocus

HScrollBar, HTrackBar, VScrollBar, VTrackBar

pbm_setfocus

HProgressBar, VProgressBar, DatePicker, MonthCalendar,
InkEdit, InkPicture

pbm_tcnsetfocus

Tab

pbm_tvnsetfocus

TreeView

Parameters

None

Return Values

Long. Return code choices (specified
in a RETURN statement):

  • 0 Continue
    processing

Examples

[Example 1]

This example in a SingleLineEdit control’s GetFocus
event selects the text in the control when the user tabs to it:

[Example 2]

In Example 1, when the user clicks the SingleLineEdit rather
than tabbing to it, the control gets focus and the text is highlighted,
but then the click deselects the text. If you define a user event
that selects the text and then post that event in the GetFocus event,
the highlighting works when the user both tabs and clicks. This
code is in the GetFocus event:

This code is in the ue_select user event:

See Also


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x