Group:  Microsoft Access ยป microsoft.public.access.formscoding
Thread: saving form on close

saving form on close
Gator 12/31/2008 3:21:01 PM
I have a form with listboxes that allow me to click values that are then
added to records. Whenever I close the form, a 'do you want to save' prompt
occurs, even though I don't make any changes to the form design. What code
can I use to save the form when it is exited?
Re: saving form on close
"Ken Snell \(MVP\)" <kthsneisllis9[ at ]ncoomcastt.renaetl> 12/31/2008 3:59:08 PM
How are you closing the form? Using a command button? Using the Red X button
at top right?

--

Ken Snell
<MS ACCESS MVP>
http://www.accessmvp.com/KDSnell/


"Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
[Quoted Text]
>I have a form with listboxes that allow me to click values that are then
> added to records. Whenever I close the form, a 'do you want to save'
> prompt
> occurs, even though I don't make any changes to the form design. What
> code
> can I use to save the form when it is exited?


Re: saving form on close
Gator 12/31/2008 4:30:03 PM
both

"Ken Snell (MVP)" wrote:

[Quoted Text]
> How are you closing the form? Using a command button? Using the Red X button
> at top right?
>
> --
>
> Ken Snell
> <MS ACCESS MVP>
> http://www.accessmvp.com/KDSnell/
>
>
> "Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
> news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
> >I have a form with listboxes that allow me to click values that are then
> > added to records. Whenever I close the form, a 'do you want to save'
> > prompt
> > occurs, even though I don't make any changes to the form design. What
> > code
> > can I use to save the form when it is exited?
>
>
>
Re: saving form on close
"Gina Whipp" <NotInterested[ at ]InViruses.com> 12/31/2008 4:34:32 PM
Gator,

Happened to me once and I when I looked the RecordSource for the form had a
field that I had deleted from the table. Once I fixed the RecordSource, by
deleting that field, the error went away.

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

"Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
[Quoted Text]
>I have a form with listboxes that allow me to click values that are then
> added to records. Whenever I close the form, a 'do you want to save'
> prompt
> occurs, even though I don't make any changes to the form design. What
> code
> can I use to save the form when it is exited?


Re: saving form on close
Gator 12/31/2008 4:59:01 PM
I'm not getting an error...just a save form prompt and I'm not making any
changes in the recordsource. I've noticed that it only happens when a new
record is added to the recordsource which is a query? Would the fact that it
is a query recordsource have anything to do with it?

"Gina Whipp" wrote:

[Quoted Text]
> Gator,
>
> Happened to me once and I when I looked the RecordSource for the form had a
> field that I had deleted from the table. Once I fixed the RecordSource, by
> deleting that field, the error went away.
>
> --
> Gina Whipp
>
> "I feel I have been denied critical, need to know, information!" - Tremors
> II
>
> "Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
> news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
> >I have a form with listboxes that allow me to click values that are then
> > added to records. Whenever I close the form, a 'do you want to save'
> > prompt
> > occurs, even though I don't make any changes to the form design. What
> > code
> > can I use to save the form when it is exited?
>
>
>
Re: saving form on close
"Gina Whipp" <NotInterested[ at ]InViruses.com> 12/31/2008 5:23:58 PM
It would not be an error, you would get a Save on Close prompt.

It shouldn't matter whether it's a query or a table, only that a field is
missing. You said previously that it happened whether you added a new
reocrd or did nothing. Are you now saying it only happens when you go to
add a new record?


--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II
"Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
news:2BEFCA01-70FE-4B20-AC03-A375429E3051[ at ]microsoft.com...
[Quoted Text]
> I'm not getting an error...just a save form prompt and I'm not making any
> changes in the recordsource. I've noticed that it only happens when a new
> record is added to the recordsource which is a query? Would the fact that
> it
> is a query recordsource have anything to do with it?
>
> "Gina Whipp" wrote:
>
>> Gator,
>>
>> Happened to me once and I when I looked the RecordSource for the form had
>> a
>> field that I had deleted from the table. Once I fixed the RecordSource,
>> by
>> deleting that field, the error went away.
>>
>> --
>> Gina Whipp
>>
>> "I feel I have been denied critical, need to know, information!" -
>> Tremors
>> II
>>
>> "Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
>> news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
>> >I have a form with listboxes that allow me to click values that are then
>> > added to records. Whenever I close the form, a 'do you want to save'
>> > prompt
>> > occurs, even though I don't make any changes to the form design. What
>> > code
>> > can I use to save the form when it is exited?
>>
>>
>>


Re: saving form on close
"Ken Snell \(MVP\)" <kthsneisllis9[ at ]ncoomcastt.renaetl> 12/31/2008 5:30:01 PM
What is the RecordSource for the form? What do you do on the form?

--

Ken Snell
<MS ACCESS MVP>
http://www.accessmvp.com/KDSnell/


"Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
news:9CCFEC55-1B95-4FAC-889F-D2A9E659FF63[ at ]microsoft.com...
[Quoted Text]
> both
>
> "Ken Snell (MVP)" wrote:
>
>> How are you closing the form? Using a command button? Using the Red X
>> button
>> at top right?
>>
>> --
>>
>> Ken Snell
>> <MS ACCESS MVP>
>> http://www.accessmvp.com/KDSnell/
>>
>>
>> "Gator" <Gator[ at ]discussions.microsoft.com> wrote in message
>> news:6A1F165D-0C59-47BF-BF68-42BD01492E10[ at ]microsoft.com...
>> >I have a form with listboxes that allow me to click values that are then
>> > added to records. Whenever I close the form, a 'do you want to save'
>> > prompt
>> > occurs, even though I don't make any changes to the form design. What
>> > code
>> > can I use to save the form when it is exited?
>>
>>
>>


Re: saving form on close
"Linq Adams via AccessMonster.com" <u28780[ at ]uwe> 12/31/2008 5:32:53 PM
"I have a form with listboxes that allow me to click values that are then
added to records."

"I'm not making any changes in the recordsource."

These two statements are mutually exclusive. If you've "added values to
records" you have made changes to your recordsource.

Is this warning referring to the form itself or to the data in the current
record? It sounds like the latter.

--
There's ALWAYS more than one way to skin a cat!

Answers/posts based on Access 2000/2003

Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/Forums.aspx/access-formscoding/200812/1

Home | Search | Terms | Imprint
Newsgroups Reader