Home > database >  Could you tell me how to realize the drop-down control list values for the value of the database tab
Could you tell me how to realize the drop-down control list values for the value of the database tab

Time:09-30

Of DDLB in PB is controls display dynamic data (the data in the table)?

CodePudding user response:

 declare yb cursor for 
The select yhm from users order by DLSJ asc.
//add each user name to the drop-down list box (in the login time)
Ddlb_1. Reset ()
The open yb.
The fetch yb into: s_mc;
The do while the sqlca. Sqlcode=0
Ddlb_1. Insertitem (s_mc, 1)
Ddlb_1. Text=s_mc
The fetch yb into: s_mc;
Loop
The close yb.

CodePudding user response:

 
//define the cursorDeclare yb cursor for
The select yhm from users order by DLSJ asc.
//add each user name to the drop-down list box (in the login time)
Ddlb_1. Reset ()
The open yb.
The fetch yb into: s_mc;
The do while the sqlca. Sqlcode=0
Ddlb_1. Insertitem (s_mc, 1)
Ddlb_1. Text=s_mc
The fetch yb into: s_mc;
Loop
The close yb.

CodePudding user response:

Writing in the drop-down list control in your window Open event!

CodePudding user response:

Choose the drop-down control, define your own events: ue_dropdown event_id: pbm_cbndropdown
Datastore lds_object
Long ll_rowcount
Long ll_row
String ls_add_data
Lds_object=create datastore
Lds_object. Dataobject='d_select_data'
Lds_object. Settransobject (sqlca)
Lds_object. Retrieve ()
Ll_rowcount=lds_object. Rowcount ()
If ll_rowcount & lt; 1 then return
For ll_row=1 to ll_rowcount
ls_add_data=https://bbs.csdn.net/topics/lds_object.getitemstring (ll_row, 'col_name)
If isnull (ls_add_data) or trim (ls_add_data)='then continue;
Enclosing insertitem (ls_add_data, 1)
End for
Destroy (lds_object)
Also can use the cursor:
Declare c_data cursor for
The select... Such as upstairs
,

CodePudding user response:

That I said the words on the right, definition of a cursor, using a cursor in the database you want to act as drop-down control list items of data, and then take out the inside of the cursor variable, an a in the drop-down list (can use ADDITEM function, specific see F1)

CodePudding user response:

The up

CodePudding user response:

Pb combox feel is redundant, with dw + DDDW not solved
  • Related