Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Using Heiarchial Flex Grid Control
Message
De
26/10/1999 13:50:27
 
 
À
26/10/1999 08:16:22
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00281117
Message ID:
00281633
Vues:
19
Hello Cetin,

Still no luck I fear.

I have absolutely nothing else in the form, just a subclassed HFlexGrid and Ado Data Control.
And now the code you gave in the INIT method.

_SCREEN.PRINT( IIF( TYPE("THISFORM.HFlexGrid1") = "O" AND !ISNULL(THISFORM.HFlexGrid1) , ;
"Flexgrid is here", "Flexgrid is missing" ) + CHR(13) )
_SCREEN.PRINT( IIF( TYPE("THISFORM.ADODc1") = "O" AND !ISNULL(THISFORM.ADODc1), ;
"ADODc is here", "ADODc is missing" )+CHR(13) )
THISFORM.HFlexGrid1.DATASOURCE = THISFORM.Adodc1.object

I then tried using a prg to get me the recordset from Fox2x tables.

#INCLUDE "..\PRGLIB\ADOCONST.H"
PUBLIC oCon, oRs
oCon = CREATEOBJECT( "ADODB.CONNECTION")
WITH oCon
.Provider = "MSDataShape"
.ConnectionString = "Data Provider=MSDASQL.1;Persist Security Info=False;Data Source=VFPDILIP"
.OPEN
ENDWITH
oRs = CREATEOBJECT( "ADODB.RECORDSET")
WITH oRs
.ActiveConnection = oCon
.SOURCE = 'SHAPE {SELECT * FROM INV_MAST WHERE INV_TYPE = "I"} AS INV_MAST ' ;
+ ' APPEND ( { SELECT INV_CODE, BRD_CODE, ITM_YEAR, ITM_CODE FROM ITM_MAST} RELATE "INV_CODE" TO "INV_CODE") AS ITEMS'
.CursorType = adOpenStatic
.LockType = adLockReadOnly
.CursorLocation = adUseClient
.OPEN
?"RecordCount:",.RECORDCOUNT
ENDWITH

Then tried to connect this recordset to the ADO data on the form, like so from the Command window,

oAdo = _SCREEN.ACTIVEFORM.AdoDc1
oAdo.OBJECT.RecordSet = oRs -----> OLE Error 'member not found'

Any help would be 'preciated.

Dilip Pillai
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform