Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data control

Status
Not open for further replies.

sborny

Technical User
Jun 29, 2001
157
0
0
GB
Hi,

I have a datacrontrol called data1 and a textbox that is bound to the control. The control loads an access db and displays email addresses in the text box.

I am trying to find out how to delete the currently selected email address and to then refresh the data control.

Can anyone help.

Cheers

Sborny.

Everything has an answer, it's just knowing the right question to ask. !!!!
 
I don't tend to use data controls but can't you just use:

data1.Recordset.Delete
 
Hi Glasgow,

Would you be kind enough to tell me how you would do it without data controls.

Thanks

Sborny.

Everything has an answer, it's just knowing the right question to ask. !!!!
 
I declare and populate a recordset as you may well have done yourself already then, for example, bind the textbox to that recordset.

Code:
Set Text1.DataSource=RsMine
Text1.DataField="Email"

Of course, without a visible data control, you need some other mechanism to allow the user to step through the recordset. I use a DataGrid control for that.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top