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

Allow User to Save Form Changes

Status
Not open for further replies.

GordonQuayle

Programmer
Sep 21, 2001
2
US
My application uses run-time Access. It has an unbound form with text boxes that I want the user to be able to position on the form where he wants them.

I have no problem letting him move the text boxes (I'm capturing the KeyDown event on the key pad arrow keys and setting the text box's left and top properties appropriately).

The problem I have is I can't find a way for him to save the changes. The DoCmd.Save has no effect. It seems that changing these properties programmatically does not mark the form as changed. Even in full-blown Access, after moving the controls, when I close the form, it does not ask if I want to save changes. However, if I manually change some attribute, as well as move the controls programmatically, then it will ask to save the form and all changes, manual and programmatic are saved.

But I can't come up a way to save the changes for some one in the run-time environment.

Any ideas?
 
I have never tried this and don't see anything that would cause me to allow a user to dio it. But, have you thought about storing the properties into a table in the database? Probably have to create some Global Variables and then save their value into the database upon exit, or something like that. Then, when they open Access up again, read those values back into the global variables.

Hope that helps... Terry M. Hoey
 
Thank you for responding. And yes I had thought of that approach, but it seemed like such overkill if the user could just save the form after making the changes.

The application is for Self-Storage facility. They want to have a birds-eye view of their facility. The controls are for each unit and they need to be able to lay them out to match their physical position. Each control will be colored-coded to indicate various status information about the unit. It will also display data when the user hovers the mouse over the unit.

I would still like to know of a way for the user to save the changes. Many facilities have several hundred units and I would like to avoid the overhead of trying to recreate the layout every time they open the form.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top