Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
MS Projects and ADD Object
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
MS Projects and ADD Object
Divers
Thread ID:
01266118
Message ID:
01266118
Vues:
47
I am trying to load MS Project (2000) into a form, however, I also want to load a particular MPP file.

I can get the file but not get it into the container else I can get it into the container but without the loaded file.

Code Sample:
&& Object Container THISFORM.box001

THISFORM.box001.AddObject('oProjx','olecontrol', 'MSPROJECT.project.9')

survtemp='c:\temp\matrix.mpp'

&& THESE DOES NOT WORK
&& THISFORM.box001.fileopenex(survtemp)
&& THISFORM.box001.application.fileopenex(survtemp)
&& THISFORM.box001.oProjx.fileopen()
&& THISFORM.box001.oProjx.application.fileopen()

THISFORM.box001.Height			= 360
THISFORM.box001.oProjx.Height		= 360
THISFORM.box001.Width			= 732
THISFORM.box001.oProjx.Width		= 732

THISFORM.box001.Visible	= .t.
THISFORM.box001.oProjx.Visible	= .t.

THISFORM.box001.oProjx.DoVerb (-1)

THISFORM.box001.oProjx.TASKS.ADD('HELLO')
THISFORM.box001.oProjx.TASKS.ADD('GOODBYE!')

THISFORM.box001.oProjx.application.ActiveProject

THISFORM.SHOW

&& Whilst I cannot get the Project file I want : I do get the Project in my container
============================================================

&& This get the correct MS Project File but I cannot get into my Object container
&& Thisform.box001

mbudvar = GETOBJECT('', 'MSPROJECT.project.9')

survtemp='c:\temp\matrix.mpp'
mbudvar.application.fileopen(survtemp)

prjx = mbudvar.application.ActiveProject

mbudvar.application.visible = .t.
Can anyone assist in getting mbudvar into the container
Obviously, missing a simple but forgotten command.

Thanks
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform