Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Unexpected Connection handle is invalid error
Message
De
07/12/2005 15:40:55
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Visual FoxPro Beta
Titre:
Unexpected Connection handle is invalid error
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01075877
Message ID:
01075877
Vues:
120
To modify report stored in Postgres SQL server, I use in VFP 9 SP1 beta
nres=SQLEXEC(nconn, "SELECT frxcontent, frtcontent from RAPORT WHERE id=123", 'vormikirj', aRowCount )
bytea2file( vormikirj.frxcontent, 'myreport.frx')
bytea2file( vormikirj.frtcontent, 'myreport.frt')
modify report myreport
cFRX = File2ByteA( 'myreport.frx')
cFRT = File2ByteA( 'myreport.frt')
nRes=SQLEXEC(nconn, "UPDATE raport SET frxcontent=?cfrx," + ;
           "frtcontent=?cFRT WHERE id=123" )
In modify report command, I add a new field with expression 1 and save report.
After that error 1466 "Connection handle is invalid" occurs in SQLEXEC() line which tries to UPDATE RAPORT table.

nconn has value 1 .
If I re-create the connection, UPDATE command runs OK.

This error occurs only if I run my application as .exe file
If I run my application from VFP 9 IDE, error does not occur.
Also, error does not occur if I build exe file using VFP 7 .

Error does not occur if I only move existing field in report. Error occurs always when changing some field contents in report designer.
This is reproducible always. I tried it in XP and Win 98 computers.


Any idea ?
Andrus
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform