Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: tushar Kanvinde
  Where is tushar Kanvinde?
 Kolhapur, Maharastra
 India
 tushar Kanvinde
 To: Khurram Tahir
  Where is Khurram Tahir?
 Karachi
 Pakistan
 Khurram Tahir
 Tags
Subject: RE: Parent , Child Form and Sql Cursors
Thread ID: 310689 Message ID: 310694 # Views: 49 # Ratings: 0
Version: Visual FoxPro 9 Category: Forms
Date: Thursday, June 23, 2011 2:38:42 PM         
   


> Parent Form has 2-Private Data Session
> Child Form has 1-Default Data Session
>
> In Parent form created following cursor
>
>
	SELECT Name_1,Code_1 From Accnt INTO CURSOR TcAcnt
> 
> 	WITH thisform.CmbDrAc As ComboBox 
> 		.BoundTo = .F. 
> 		.ColumnCount = 2
> 		.ColumnWidths = '330,68'
> 		.RowSourceType = 6 
> 		.RowSource = 'TcAcnt.Name_1,Code_1'
> 		.Requery()
> 	ENDWITH 

>
>
>
DO FORM Child1 NOSHOW NAME oChild1 LINKED
> 
> oChild1.Show(1) && 1-Modal

>
> Problem
>
> when return back from Child form in Parent form CURSOR TcAcnt gone.
>
> By setting Child form data environment to 2-Private Data Session it solves the problem but then add again all required tables in data environemtn of child form too.

You have some code in the child form that closes TcAcnt cursor. Check the code in the child form

Regards
Tushar

ENTIRE THREAD

Parent , Child Form and Sql Cursors Posted by Khurram Tahir @ 6/23/2011 2:07:47 PM
RE: Parent , Child Form and Sql Cursors Posted by tushar @ 6/23/2011 2:38:42 PM
RE: Parent , Child Form and Sql Cursors Posted by Khurram Tahir @ 7/1/2011 9:05:07 AM
RE: Parent , Child Form and Sql Cursors Posted by tushar @ 7/1/2011 10:49:15 AM
RE: Parent , Child Form and Sql Cursors Posted by Gio Car @ 7/1/2011 4:37:30 PM
RE: Parent , Child Form and Sql Cursors Posted by Anders Altberg @ 7/1/2011 5:42:23 PM