Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
NewObject gives me an error: Object name is invalid
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
NewObject gives me an error: Object name is invalid
Divers
Thread ID:
00559510
Message ID:
00559510
Vues:
46
Hi everybody,

I have a form with two pages. On the first page I have a grid called grdDataDict. In the run-time I change each header to Header based on myHeader class. This code is in Init of the form and works fine.

On the second page I add container with page objects on the fly (I use this technique to not load unvisible objects, which may be never accessed). This is the code in Page2.Activate:
********************************************************************
*  Description.......: Page2.Activate
*  Calling Samples...:
*  Parameter List....:
*  Created by........:
*  Modified by.......: Nadya Nosonovsky 05/31/2000 05:41:31 PM
********************************************************************
thisform.dataenvironment.initialselectedalias="IndxDict"
select IndxDict
with this
	if type("this.ContIndxPage")<>"O"
		.newobject("ContIndxPage","IndxDictPage","ddwg.vcx")
		with .ContIndxPage
			.top=5
			.left=20
			.visible=.t.
			set step on
			local loColumn, lcCaption
			for each loColumn in .grdIndxDict.Columns
		     lcCaption = loColumn.Header1.Caption
		     loColumn.removeobject('Header1')
		     loColumn.NewObject('Header1','myheader','myheader.prg',,m.lcCaption)
		next       
		endwith
	endif
	.refresh()
	thisform.navstand.navupdate()
	thisform.navstand.lstOrders.enable()
	.ContIndxPage.grdIndxDict.setfocus()	
endwith
Line with NewObject generates an Error : Object name is invalid (Error 1575)

What could be wrong here?

Thanks a lot for any clue.
If it's not broken, fix it until it is.


My Blog
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform