Solved

PropertyBag

Posted on 1997-11-25
5
199 Views
Last Modified: 2008-03-10
I have build my own control in vb5. That control needs a databasefile that the user can choose. I 've build some extra properties and indeed, the user can see them when he or she is designing the program with my control. The problem is that the user must give the filename by the hand. How can I put a commandbutton on the right side of the textbox so the user will get a browser to pick up his or her file. I would also like to link  some other events to these buttons, not only the browsefunction.
0
Comment
Question by:ndb
  • 2
  • 2
5 Comments
 
LVL 8

Expert Comment

by:mrmick
ID: 1442397
You'll find you answer in the Microsoft VB Knowledgebase: Q161094
0
 
LVL 1

Author Comment

by:ndb
ID: 1442398
I don't want a property page, I want imediatly a browser or performing another command.
0
 
LVL 6

Expert Comment

by:anthonyc
ID: 1442399
Add the button.....   add a commondialog control to your form/usercontrol.   When the button is clicked, you can set the properties of the commondialog like this

with commondialog1
   .title = "Pick File"
   .filter = "MDBs (*.mdb)|*.mdb"
   
   'look for help on the commondialogcontrol
   .cancelerror = true
   on local error resume next
   .showopen
   if err = 0 then
      text1.text = .filename
   end if
end with
0
 
LVL 1

Author Comment

by:ndb
ID: 1442400
As I just said, I don't want to have a propertypage! The example that you just gaved works with propertypage, I knew that before, but I don't want propertypages.
0
 
LVL 6

Accepted Solution

by:
anthonyc earned 100 total points
ID: 1442401
And I read, I know you didn't want a property page.  This would work either way, but I am not going to help anymore if you are going to have an attitude.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now