How to prevent of turning visible, hidden fields of form datasheet

G

Guest

Good day:

I have the following problem. I have a form in the datasheet view and I have
some fields that I hid and that have the visible property set to NO. When I
open the form these don't appear because I hid them with the right button of
the mouse. But if I put the mouse in the limit of a field and drag the mouse
the field is visible. How is it that can impede this?

Thanks in advance for your cooperation.

Best regards,
José Leal
 
A

Allen Browne

Create a query into the table.
Omit the fields you do not want from the query.
Base your datasheet-view form on this query.
 
G

Guest

Good day, Allen:

Thank you for your comment, but it doesn't result.
One of the fields of the table 1 is the key of a table 2. And in the form of
the table 1 I don't want that the key field of the table 2, be visible, but I
need him because I will create a value list that will store the value in that
field. If the field doesn't exist, I cannot link the value list to that field.

Best regards,
José Leal
 
A

Allen Browne

Jose, you can have a field in the source query, without having a text box on
the form.

If you do need the text box on the form, you can set its Visible property to
No.

You also have the option of showing this as a continuous form instead of a
datasheet. That's my preferred interface, because end users can't get
themself into trouble with messing around with the columns (resizing,
reordering, hiding, ...)
 
G

Guest

Good day, Allen:

I already put the visible property of the field to no, and he appears in the
same way. Then I have to hid it with the functions of the right button of the
mouse. The problem is if you have 3 fields for instance (1,2 and 3) and you
hide the field 2, if you put the mouse on the right side of the field 1, it
can happen 2 things:
- To increase the width of the field 1;
- To show the field 2, which I don't want that it happens.

Thank you for the suggestion of the continuous form, but I wanted to do this
with datasheet view.

Best regards,
José Leal
 
B

Brendan Reynolds

Private Sub Form_Timer()

If Me.TestID.ColumnHidden = False Then
Me.TestID.ColumnHidden = True
End If

End Sub

Set the form's TimerInterval property to a short interval such as 250.
 
G

Guest

Good night,Brendan:

Thank you for the suggestion. I will try.
I think that it going to work.

Best regards,
José Leal
 
V

Vincent Johns

jleal said:
Good day, Allen:

Thank you for your comment, but it doesn't result.
One of the fields of the table 1 is the key of a table 2. And in the form of
the table 1 I don't want that the key field of the table 2, be visible, but I
need him because I will create a value list that will store the value in that
field. If the field doesn't exist, I cannot link the value list to that field.

Best regards,
José Leal

:

Allen's suggestion seems quite good to me. You appear NOT to want the
user of the datasheet to see the hidden field, so I assume that your
user will not have any need to update the field. For updating, you can
use some other query that you don't show the user. For display, use the
query that Allen suggested. You can have any number of queries attached
to one table (or set of tables).

-- Vincent Johns <[email protected]>
Please feel free to quote anything I say here.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top