Sign Up |  Live StatsLive Stats    Articles 34,879| Comments 154,836| Members 17,229, Newest kuljeet kaur| Online 268
Home Contact
 (Forgotten?): 
    Sikhism

   
                                                                     Your Banner Here!    

 
 
  
  

RecordsetClone theory

Our Donation Goal : Why Donate? : Donate Today! : Donate Anonymously (ਗੁਪਤ) : Our Family of Supporters
Goal this month: 400 USD, Received: 25 USD (6%)
Please Donate...
Related Topics...
Thread Thread Starter Forum Replies Last Post
Materialism Theory in Philosophy Scarlet Pimpernel Christianity 3 06-Jun-2011 04:52 AM
A Theory of Civilization - Silence is Assent Aman Singh Hard Talk 0 29-Jan-2010 06:05 AM
Hair = Antenna Theory BhagatSingh Hard Talk 29 09-Sep-2008 23:46 PM
The Aryan theory bulleshah Hinduism 1 28-May-2006 17:16 PM
Recordsetclone Property Error rico Information Technology 0 10-Nov-2005 21:08 PM


Tags
recordsetclone, theory
Reply Post New Topic In This Forum Stay Connected to Sikhism, Click Here to Register Now!
  #1 (permalink)  
Old 28-Jul-2006, 08:01 AM
eric's Avatar eric
Guest
 
Posts: n/a
   
   
RecordsetClone theory

  Donate Today!   Email to Friend  Tell a Friend   Show Printable Version  Print   Contact sikhphilosophy.net Administraion for any Suggestions, Ideas, Feedback.  Feedback  

Register to Remove Advertisements
Hi,
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/information-technology/9347-recordsetclone-theory.html

In the MS Accesguide "VB for App's" I read about finding a record in a table
by using Set rst => RecordsetClone => Findfirst => Bookmark => etc.
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
In the book it says that, with using the property RecordsetClone, a copy of
the recordset is made, you work in the copy, and at the end the changes in
the copy are put in the original recordset.

My question is: why is Access/VB not working DIRECTLY IN THE ORIGINAL
RECORDSET, but via the clone ?
I'm sure the must be a logical reason, but don't see it and can't find it
in the tutorial.

Can anyone please explain ?
Thank you in advance

--
eric



 
Do share your immediate thoughts or reactions on this issue? We value your views! Login Now! or Sign Up Today! to share your views with us.. Gurfateh!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 28-Jul-2006, 08:01 AM
Dirk Goldgar's Avatar Dirk Goldgar
Guest
 
Posts: n/a
   
   
Re: RecordsetClone theory

"eric" wrote in message
news:80975D22-60AD-4E9D-A620-4236346D7BF0@microsoft.com
> Hi,
>
> In the MS Accesguide "VB for App's" I read about finding a record in
> a table by using Set rst => RecordsetClone => Findfirst => Bookmark
> => etc.
> In the book it says that, with using the property RecordsetClone, a
> copy of the recordset is made, you work in the copy, and at the end
> the changes in the copy are put in the original recordset.
>
> My question is: why is Access/VB not working DIRECTLY IN THE ORIGINAL
> RECORDSET, but via the clone ?
> I'm sure the must be a logical reason, but don't see it and can't
> find it in the tutorial.
>
> Can anyone please explain ?
> Thank you in advance


Three reasons:

1. Until Access 2000, the form's recordset was not directly accessible.
The form had no (public) Recordset property, only the RecordsetClone
property.

2. Actions performed directly on the form's recordset (obtained via the
Recordset property) are reflected immediately on the form. That
includes navigation -- if you move in the form's recordset, the form's
currently displayed record changes. If you perform an AddNew on the
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
form's recordset, the form displays the "new record".

Sometimes, that's what you want. Other times it isn't. For example, if
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
you just want to position the form to a different record located by
FindFirst, it's perfectly okay to do this:

Me.Recordset.FindFirst "ID=" & lngIDtoFind

.... instead of this:

With Me.RecordsetClone
.FindFirst "ID=" & lngIDtoFind
If Not .NoMatch Then
Me.Bookmark = .Bookmark
End If
End With

On the other hand, if you want to look at some record in the form's
recordset *without changing the record displayed on the form*, then you
must use the RecordsetClone, because navigation in the form's
RecordsetClone is not reflected on the form.

3. Also, form events are not raised by any of the actions you may take
on the RecordsetClone. But actions performed on the form's Recordset,
because they are reflected on the form, may cause form events to fire.
This may or may not be desirable.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


Reply With Quote
  #3 (permalink)  
Old 28-Jul-2006, 08:01 AM
BW's Avatar BW
Guest
 
Posts: n/a
   
   
Re: RecordsetClone theory

I'm fairly new to the VBA side of things. Did you say that any changes
made to the recordset clone are then saved to the original forms recordset
automatically?


"Dirk Goldgar" wrote in message
news:%23JmFSLGdGHA.4932@TK2MSFTNGP03.phx.gbl...
> "eric" wrote in message
> news:80975D22-60AD-4E9D-A620-4236346D7BF0@microsoft.com
>> Hi,
>>
>> In the MS Accesguide "VB for App's" I read about finding a record in
>> a table by using Set rst => RecordsetClone => Findfirst => Bookmark
>> => etc.
>> In the book it says that, with using the property RecordsetClone, a
>> copy of the recordset is made, you work in the copy, and at the end
>> the changes in the copy are put in the original recordset.
>>
>> My question is: why is Access/VB not working DIRECTLY IN THE ORIGINAL
>> RECORDSET, but via the clone ?
>> I'm sure the must be a logical reason, but don't see it and can't
>> find it in the tutorial.
>>
>> Can anyone please explain ?
>> Thank you in advance

>
> Three reasons:
>
> 1. Until Access 2000, the form's recordset was not directly accessible.
> The form had no (public) Recordset property, only the RecordsetClone
> property.
>
> 2. Actions performed directly on the form's recordset (obtained via the
> Recordset property) are reflected immediately on the form. That
> includes navigation -- if you move in the form's recordset, the form's
> currently displayed record changes. If you perform an AddNew on the
> form's recordset, the form displays the "new record".
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
>
> Sometimes, that's what you want. Other times it isn't. For example, if
> you just want to position the form to a different record located by
> FindFirst, it's perfectly okay to do this:
>
> Me.Recordset.FindFirst "ID=" & lngIDtoFind
>
> ... instead of this:
>
> With Me.RecordsetClone
> .FindFirst "ID=" & lngIDtoFind
> If Not .NoMatch Then
> Me.Bookmark = .Bookmark
> End If
> End With
>
> On the other hand, if you want to look at some record in the form's
> recordset *without changing the record displayed on the form*, then you
> must use the RecordsetClone, because navigation in the form's
> RecordsetClone is not reflected on the form.
>
> 3. Also, form events are not raised by any of the actions you may take
> on the RecordsetClone. But actions performed on the form's Recordset,
> because they are reflected on the form, may cause form events to fire.
> This may or may not be desirable.
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
>
> --
> Dirk Goldgar, MS Access MVP
> www.datagnostics.com
>
> (please reply to the newsgroup)
>
>



Reply With Quote
  #4 (permalink)  
Old 28-Jul-2006, 08:02 AM
Dirk Goldgar's Avatar Dirk Goldgar
Guest
 
Posts: n/a
   
   
Re: RecordsetClone theory

"BW" wrote in message
news:OoaLOfHdGHA.4128@TK2MSFTNGP05.phx.gbl
> I'm fairly new to the VBA side of things. Did you say that any
> changes made to the recordset clone are then saved to the original
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
> forms recordset automatically?


I'm not sure what you mean. Both the form's recordset and the clone of
that recordset are linked to the same table or tables. Changes to the
records and fields in one will be reflected in the other, so data
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
changes made to the recordsetclone will be apparent on the form.
However, the form's recordset is linked to the form, so the current
record in the recordset is the current record on the form, and
navigation in the recordset also navigates the form. But the
recordsetclone is not linked directly to the form, so you can navigate
in the recordsetclone without affecting the form.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


Reply With Quote
  #5 (permalink)  
Old 28-Jul-2006, 08:02 AM
eric's Avatar eric
Guest
 
Posts: n/a
   
   
Re: RecordsetClone theory

Hi Dirk,
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
Understanding WHY makes it easier for me to remember the programming code.
You helped me on that. Thank you very much !

Hi BW,
Dirk answered my question but I leave it up to you to conclude the thread,
in case you need to go on on this.

Greetings
--
eric


"Dirk Goldgar" wrote:

> "BW" wrote in message
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
> news:OoaLOfHdGHA.4128@TK2MSFTNGP05.phx.gbl
> > I'm fairly new to the VBA side of things. Did you say that any
> > changes made to the recordset clone are then saved to the original
> > forms recordset automatically?

>
> I'm not sure what you mean. Both the form's recordset and the clone of
> that recordset are linked to the same table or tables. Changes to the
> records and fields in one will be reflected in the other, so data
> changes made to the recordsetclone will be apparent on the form.
> However, the form's recordset is linked to the form, so the current
> record in the recordset is the current record on the form, and
> navigation in the recordset also navigates the form. But the
> recordsetclone is not linked directly to the form, so you can navigate
> in the recordsetclone without affecting the form.
>
> --
> Dirk Goldgar, MS Access MVP
> www.datagnostics.com
>
> (please reply to the newsgroup)
>
>
>

Reply With Quote
  #6 (permalink)  
Old 28-Jul-2006, 08:02 AM
BW's Avatar BW
Guest
 
Posts: n/a
   
   
Re: RecordsetClone theory

  Donate Today!  
Dirk, You response clarified my question. I was misunderstanding
"RecordsetClone" to mean a static copy of the forms data.
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347

Thanks
Brent

"Dirk Goldgar" wrote in message
news:%23Bh0SqLdGHA.1436@TK2MSFTNGP05.phx.gbl...
> "BW" wrote in message
> news:OoaLOfHdGHA.4128@TK2MSFTNGP05.phx.gbl
>> I'm fairly new to the VBA side of things. Did you say that any
>> changes made to the recordset clone are then saved to the original
>> forms recordset automatically?

>
> I'm not sure what you mean. Both the form's recordset and the clone of
> that recordset are linked to the same table or tables. Changes to the
> records and fields in one will be reflected in the other, so data
> changes made to the recordsetclone will be apparent on the form.
> However, the form's recordset is linked to the form, so the current
> record in the recordset is the current record on the form, and
> navigation in the recordset also navigates the form. But the
> recordsetclone is not linked directly to the form, so you can navigate
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=9347
> in the recordsetclone without affecting the form.
>
> --
> Dirk Goldgar, MS Access MVP
> www.datagnostics.com
>
> (please reply to the newsgroup)
>
>



Reply With Quote
   Click Here to Donate Now!

Support Us!
Become a Promoter!
Gurfateh ji, you can become a SPN Promoter by Donating as little as $10 each month. With limited resources & high operational costs, your donations make it possible for us to deliver a quality website and spread the teachings of the Sri Guru Granth Sahib Ji, to serve & uplift humanity. Every contribution counts. Donate Generously. Gurfateh!
ReplyPost New Topic In This Forum Stay Connected to Sikhism, Click Here to Register Now!

Bookmarks


(View-All Members who have read this thread : 0
There are no names to display.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Tools Search
Search:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On

» Gurbani Jukebox
Listen to Gurbani while surfing SPN!
» Recent Discussions
sikhism Is Hindu/Sikh a Valid...
Today 02:20 AM
82 Replies, 1,426 Views
sikhism Undercover Mosque
Today 01:10 AM
0 Replies, 16 Views
sikhism Fools Who Wrangle Over...
Today 00:56 AM
911 Replies, 77,820 Views
sikhism Incidental happiness
Yesterday 23:00 PM
0 Replies, 32 Views
sikhism Amazing truth!
Yesterday 22:20 PM
0 Replies, 37 Views
sikhism Black money: Indians...
Yesterday 21:40 PM
1 Replies, 40 Views
sikhism Benti Chaupai - Keertan...
Yesterday 21:06 PM
9 Replies, 202 Views
sikhism Meditate - How, What,...
Yesterday 21:04 PM
37 Replies, 1,104 Views
sikhism Sikh temple brawl a...
Yesterday 20:33 PM
0 Replies, 46 Views
sikhism Turban Cloth
Yesterday 20:32 PM
3 Replies, 98 Views
sikhism A village where every...
Yesterday 19:12 PM
0 Replies, 40 Views
Why have Sikhs Changed...
Yesterday 18:12 PM
34 Replies, 1,166 Views
Scientists cure cancer,...
By Kamala
Yesterday 14:09 PM
7 Replies, 123 Views
Any Japji Sahib videos...
By Kamala
Yesterday 13:02 PM
6 Replies, 77 Views
SGPC Recruitment Scandal
Yesterday 04:09 AM
0 Replies, 54 Views
» Books You Should Read...
Powered by vBadvanced CMPS v3.2.2

All times are GMT +6.5. The time now is 03:38 AM.
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.5.2 Copyright © 2004-12, All Rights Reserved. Sikh Philosophy Network


Page generated in 0.50286 seconds with 30 queries