Home All Groups Group Topic Archive Search About

Help in saving database

Author
7 Jun 2006 5:28 AM
SemiNoviceProgramer
Dear friends
I started a new project in Visual studio 2005, then I added a database
connection using the wizard (access database)
the problem that when I press the save button on the automatically
generated toolbar nothing saved to my database file, so each time I
restarted the project I found the original dat unmodified
what code should I add to the wizard-generated code to let the original
database file updated permanently

thanks in advance

Author
7 Jun 2006 6:12 AM
Cor Ligthert [MVP]
SemiNovice,

Can you tell what wizard you did use, by generating only a connection string
this will not work.

Cor


Show quoteHide quote
"SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
news:1149658100.396372.226640@f6g2000cwb.googlegroups.com...
> Dear friends
> I started a new project in Visual studio 2005, then I added a database
> connection using the wizard (access database)
> the problem that when I press the save button on the automatically
> generated toolbar nothing saved to my database file, so each time I
> restarted the project I found the original dat unmodified
> what code should I add to the wizard-generated code to let the original
> database file updated permanently
>
> thanks in advance
>
Author
10 Jun 2006 4:24 AM
SemiNoviceProgramer
thank you Cor for your reply,
I mean the add new data source wizard in VS 2005 (the Tab next to the
solution explorer)
Every thing wworks weel excepth that the Save button saves to the data
set not to the data base!
thanks in advance for your help
Nesr

Cor Ligthert [MVP] wrote:
Show quoteHide quote
> SemiNovice,
>
> Can you tell what wizard you did use, by generating only a connection string
> this will not work.
>
> Cor
>
>
> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
> news:1149658100.396372.226640@f6g2000cwb.googlegroups.com...
> > Dear friends
> > I started a new project in Visual studio 2005, then I added a database
> > connection using the wizard (access database)
> > the problem that when I press the save button on the automatically
> > generated toolbar nothing saved to my database file, so each time I
> > restarted the project I found the original dat unmodified
> > what code should I add to the wizard-generated code to let the original
> > database file updated permanently
> >
> > thanks in advance
> >
Author
10 Jun 2006 5:07 AM
Cor Ligthert [MVP]
That can be a long traject to find why.

So you did do
Data create DataSource
Dragged the DataSource from the DataSourceView box on your form

Than there should be generated beside the dataview with the save button as a
diskette something as
BindingSource.EndEdit
TableAdapter Fill

Is that the situation?

Cor

Show quoteHide quote
"SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
news:1149913498.625628.283270@h76g2000cwa.googlegroups.com...
> thank you Cor for your reply,
> I mean the add new data source wizard in VS 2005 (the Tab next to the
> solution explorer)
> Every thing wworks weel excepth that the Save button saves to the data
> set not to the data base!
> thanks in advance for your help
> Nesr
>
> Cor Ligthert [MVP] wrote:
>> SemiNovice,
>>
>> Can you tell what wizard you did use, by generating only a connection
>> string
>> this will not work.
>>
>> Cor
>>
>>
>> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
>> news:1149658100.396372.226640@f6g2000cwb.googlegroups.com...
>> > Dear friends
>> > I started a new project in Visual studio 2005, then I added a database
>> > connection using the wizard (access database)
>> > the problem that when I press the save button on the automatically
>> > generated toolbar nothing saved to my database file, so each time I
>> > restarted the project I found the original dat unmodified
>> > what code should I add to the wizard-generated code to let the original
>> > database file updated permanently
>> >
>> > thanks in advance
>> >
>
Author
11 Jun 2006 8:42 AM
SemiNoviceProgramer
Yes this is the situation, and unfortunately the save button (the
diskette) did not save changes to the database but to the dataset (ie
changes are temporarely occured till I stopped running the program, so
when stopped and restarted, the original data base is loaded and all
changes are discarded)


What Can I Do to save to the database file???


Thanks to you all


Cor Ligthert [MVP] wrote:
Show quoteHide quote
> That can be a long traject to find why.
>
> So you did do
> Data create DataSource
> Dragged the DataSource from the DataSourceView box on your form
>
> Than there should be generated beside the dataview with the save button as a
> diskette something as
> BindingSource.EndEdit
> TableAdapter Fill
>
> Is that the situation?
>
> Cor
>
> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
> news:1149913498.625628.283270@h76g2000cwa.googlegroups.com...
> > thank you Cor for your reply,
> > I mean the add new data source wizard in VS 2005 (the Tab next to the
> > solution explorer)
> > Every thing wworks weel excepth that the Save button saves to the data
> > set not to the data base!
> > thanks in advance for your help
> > Nesr
> >
> > Cor Ligthert [MVP] wrote:
> >> SemiNovice,
> >>
> >> Can you tell what wizard you did use, by generating only a connection
> >> string
> >> this will not work.
> >>
> >> Cor
> >>
> >>
> >> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
> >> news:1149658100.396372.226640@f6g2000cwb.googlegroups.com...
> >> > Dear friends
> >> > I started a new project in Visual studio 2005, then I added a database
> >> > connection using the wizard (access database)
> >> > the problem that when I press the save button on the automatically
> >> > generated toolbar nothing saved to my database file, so each time I
> >> > restarted the project I found the original dat unmodified
> >> > what code should I add to the wizard-generated code to let the original
> >> > database file updated permanently
> >> >
> >> > thanks in advance
> >> >
> >
Author
11 Jun 2006 9:38 AM
Cor Ligthert [MVP]
Novice,

Withouth that there is an error showed this cannot happen.

Can you set before the code in the code part xxxxxxxxxxxxx.endedit a
breakpoint.

Click inside that second empty column on the left. Or right click
breakpoints and choose that.

Cor

Show quoteHide quote
"SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
news:1150015334.523775.112040@g10g2000cwb.googlegroups.com...
> Yes this is the situation, and unfortunately the save button (the
> diskette) did not save changes to the database but to the dataset (ie
> changes are temporarely occured till I stopped running the program, so
> when stopped and restarted, the original data base is loaded and all
> changes are discarded)
>
>
> What Can I Do to save to the database file???
>
>
> Thanks to you all
>
>
> Cor Ligthert [MVP] wrote:
>> That can be a long traject to find why.
>>
>> So you did do
>> Data create DataSource
>> Dragged the DataSource from the DataSourceView box on your form
>>
>> Than there should be generated beside the dataview with the save button
>> as a
>> diskette something as
>> BindingSource.EndEdit
>> TableAdapter Fill
>>
>> Is that the situation?
>>
>> Cor
>>
>> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
>> news:1149913498.625628.283270@h76g2000cwa.googlegroups.com...
>> > thank you Cor for your reply,
>> > I mean the add new data source wizard in VS 2005 (the Tab next to the
>> > solution explorer)
>> > Every thing wworks weel excepth that the Save button saves to the data
>> > set not to the data base!
>> > thanks in advance for your help
>> > Nesr
>> >
>> > Cor Ligthert [MVP] wrote:
>> >> SemiNovice,
>> >>
>> >> Can you tell what wizard you did use, by generating only a connection
>> >> string
>> >> this will not work.
>> >>
>> >> Cor
>> >>
>> >>
>> >> "SemiNoviceProgramer" <hgnov3***@gmail.com> schreef in bericht
>> >> news:1149658100.396372.226640@f6g2000cwb.googlegroups.com...
>> >> > Dear friends
>> >> > I started a new project in Visual studio 2005, then I added a
>> >> > database
>> >> > connection using the wizard (access database)
>> >> > the problem that when I press the save button on the automatically
>> >> > generated toolbar nothing saved to my database file, so each time I
>> >> > restarted the project I found the original dat unmodified
>> >> > what code should I add to the wizard-generated code to let the
>> >> > original
>> >> > database file updated permanently
>> >> >
>> >> > thanks in advance
>> >> >
>> >
>
Author
7 Jun 2006 7:33 AM
gene kelley
On 6 Jun 2006 22:28:20 -0700, "SemiNoviceProgramer"
<hgnov3***@gmail.com> wrote:

>Dear friends
>I started a new project in Visual studio 2005, then I added a database
>connection using the wizard (access database)
>the problem that when I press the save button on the automatically
>generated toolbar nothing saved to my database file, so each time I
>restarted the project I found the original dat unmodified
>what code should I add to the wizard-generated code to let the original
>database file updated permanently
>
>thanks in advance

1)  Run the project .exe file in the project's bin\debug folder.
2) Save some data and then close app.
3) Rerun the .exe file.
4) Do the saved changes show?

Gene