SELECT field1, field10 FROM table
------------------
smalig
[email protected]
http://vbcode.webhostme.com/
Printable View
SELECT field1, field10 FROM table
------------------
smalig
[email protected]
http://vbcode.webhostme.com/
Done that already. What happened was, when I tried to edit a row of data into the data entry form, and a field present in the data entry form is not in the SELECT statement (which is a field that doesn't appear in the datagrid), an error occurs, which is:
Unable to bind to field or datamember: <field name>
I used the SQL statement "SELECT * FROM table" to access all the fields from the database. But I don't want the other fields to show, say some less important fields which should just appear in a data entry form. HOw could I do that? thanks...
Well, generally if you don't need to show a field, you just don't place any bound control with that field on the form, or set the visible property of this field's bound control to false to hide it, while you still can use SELECT * ...
... and if you are using datagrid (like DBgrid), you can hide the particular columns of the fields you want to hide, this you can do at design-time (rightclick on the grid to get it's property page) or at runtime, something like DBGrid1.Columns("field1").Visible = False