Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ACT! Automation - Insert problems
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
ACT! Automation - Insert problems
Divers
Thread ID:
00837744
Message ID:
00837744
Vues:
86
I am using VFP 6 to create a sync program between ACT! (Contact management) and VFP tables. I have to use 6 because automation of ACT! with VFP 7 or 8 causes errors (intellisense), but that's another story.

The problem I have is when I lookup data in ACT!, all is well, but when I try to insert into ACT!, I get "OLE Error Code 0x8002000e: Invalid number of parameters"

That seems logical, except that I'm following working VB6 example code as my guide. Here's the two examples...

VB:
    Set objDatabase = CreateObject("ACTOLE.DATABASE")
    objDatabase.Open dbName
    
    bReturn = Login(objDatabase)

    ' assign the EMAIL table object
    Set objEmail = objDatabase.EMAIL
    
    objEmail.MoveFirst
    objEmail.Add
                           
    ' set field data
    objEmail.Data EF_Logon, frmAddEmail.txtLogon.Text           This line works fine in VB...
    objEmail.Data EF_Carrier, frmAddEmail.cboCarrier.Text

    strEmailID = objEmail.Update
Here's the VFP Code:
o_actdb = CREATEOBJECT('ACTOLE.DATABASE')
o_actdb.open(dbName)
l_loggedin = Login(o_actdb)

objEmail = l_actdb.email

objEmail.movefirst()
objEmail.add()

objEmail.data(EF_Logon,"text")                 This is the line that generates the error!!!
objEmail.data(EF_Carrier,"moretext")
l_updated = objEmail.update()
I have the same number of parameters as the VB example. All other code seems to work as I can see data already in ACT, just not add anything to it.

Please Help!!!!!

Thanks in advance ~
Steve Howie, owner
DaSH Technology
Denver, CO
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform