NTK and The NTK Project
are properties of Jn Dechereux
Home | Documentation | FAQ.

Vanilla 1.1.8 is a product of Lussumo. More Information: Documentation, Community Support.

Welcome Guest!
Want to take part in these discussions? If you have an account, sign in now.
If you don't have an account, apply for one now.
    •  
      CommentAuthorccarrignon
    • CommentTimeSep 25th 2013
     
    Hi there!
    Can anyone tell me the way to handle array as data source for NtkTbrowse object?
    Any tutorials or sample code?
    Thanks Chris
    •  
      CommentAuthorxbasefan
    • CommentTimeSep 25th 2013
     
    in my opinion, the arrayrdd support that comes with the NTKADORDD contribution is the best option.
    e.g.
     
    // Create a new dbf in memory using dbCreate() 
       aStruct := { ;
                    { "NAME"     , "C", 40, 0 } ,;
                    { "ADDRESS"  , "C", 40, 0 } ,;
                    { "BIRTHDAY" , "D",  8, 0 } ,;
                    { "AGE"      , "N",  3, 0 }  ;
                  }
       dbCreate( "arrtest.dbf", aStruct, "ARRAYRDD" )
    
    // Open it and browse records
       USE arrtest.dbf VIA "ARRAYRDD" NEW ALIAS dataSrc
       @ nTop,nLeft TO nBottom,nRight CREATE BROWSE oB ;
                            WITH DBAREA dataSrc INTO hWnd
    

    wilson
    •  
      CommentAuthorccarrignon
    • CommentTimeSep 27th 2013
     
    Morning Wilson
    Thanks for the Tip - didn't even know this was possible!
    So I eagerly tried to create a quick TestApp with this code but got linkage errors when building the program.

    // ///////////////////
    C:\KB71A>make
    xHarbour Compiler build 1.2.1 (SimpLex) (Rev. 6406)
    Copyright 1999-2009, http://www.xharbour.org http://www.harbour-project.org/
    Compiling 'brwarray.prg'...
    Lines 60, Functions/Procedures 1
    Generating C source output to 'brwarray.c'...
    Done.
    Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
    brwarray.c:
    xHarbour Compiler build 1.2.1 (SimpLex) (Rev. 6406)
    Copyright 1999-2009, http://www.xharbour.org http://www.harbour-project.org/
    Compiling 'arrayrdd.prg'...
    Lines 1066, Functions/Procedures 35
    Generating C source output to 'arrayrdd.c'...
    Done.
    Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
    arrayrdd.c:

    Press any key to continue ou CTRL+C to stop this process now...
    Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
    Error: Unresolved external '_HB_FUN_USRRDD_RDDDATA' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_USRRDD_AREADATA' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_UR_SUPER_SETFIELDEXTENT' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_UR_SUPER_ADDFIELD' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_USRRDD_ID' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_UR_SUPER_ERROR' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_UR_SUPER_OPEN' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_UR_SUPER_CLOSE' referenced from C:\KB71A\ARRAYRDD.OBJ
    Error: Unresolved external '_HB_FUN_USRRDD_GETFUNCTABLE' referenced from C:\KB71A\ARRAYRDD.OBJ
    Info: Link time = 0.53 seconds
    C:\KB71A>
    // /////////////////

    Any ideas?
    •  
      CommentAuthorxbasefan
    • CommentTimeSep 28th 2013
     
    hmmm, sounds like usrrdd.lib not declared into your makefile. you should check out.
    wilson.
    •  
      CommentAuthorccarrignon
    • CommentTimeOct 1st 2013
     
    You were right, it's working fine now. Thanks!

    - Chris
    •  
      CommentAuthorccarrignon
    • CommentTimeOct 1st 2013 edited
     
    Oh, I forgot to mention: I didn't find arrayrdd.prg in C:\wntk4hrb\Contrib\AdoNtkRdd\ as you told me but in the C:\xharbour\source\rdd\usrrdd\rdds sub-dir. :wink:
Add your comments
  • Format comments as