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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I want to use a nonstandard control in a form

Status
Not open for further replies.

dannG

Programmer
Jan 9, 2003
26
RO
Hi,
I want to use in an Access Form a DirListBox control (a standard VisualBasic 6.0 control) or a TreeView control.
It is possible?
I tried "More Controls" but I can't find the control that I want(DirListBox) and another one does't work!
Anybody know a solution for my problem?
Thanks



 
Hi,
Are you trying to add a dialog box that will allow the user to select a file? If so, you can use the Microsoft Windows Common Dialog Control, version 6.0. You should be able to find it listed when you click on Tools, ActiveX Controls.

As you probably know from VB6, you can specify the initial directory (InitDir property, under the Other tab) and the filter to be used (e.g., "jpg" - "Filter" property, also under the Other tab).

Add a command button to your form that will be used to call the Common Dialog control. On the clicked event, use this code:
cdlOpen.ShowOpen

BTW, this control can also be used to specify color and font. Click on the Custom property (under Other), then click the ellipses (...). You will see 5 basic categories that this Active X control can manipulate. HTH, [pc2]
Randy Smith
California Teachers Association
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top