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.
    •  
      CommentAuthorettman
    • CommentTimeNov 6th 2009
     
    Are there NTK functions for validating the existance of a file (with ' ' embedded in path and/or filename), along with opening such a file, editing it, etc.? Or do I need to use hb_fsfile() and other functions? If so, what steps are necessary to get access to the hb_ functions? Thank you, Frank.
    •  
      CommentAuthorjnd
    • CommentTimeNov 6th 2009 edited
     
    Hi Frank,

    Long time no talk!


    >>are there NTK functions for validating the existance of a file (with ' ' embedded in path and/or
    >>filename), along with opening such a file, editing it, etc.?

    If you want to check if a file (with long name or not) is currently existing, why don't you use the std xharbour File() function?

    Something simple like this should work great:
    Local cLongFName := "c:\Test\My file with Long name.txt"
    if !File(cLongFName)
          NTK_MsgBox( , "Cannot find "+cLongFName, "Alert!" )
          Return
    endif
    
    
    // Do some code here ...
    
    


    However, if you need more info about this topic, just take a look at fcpy32.prg and fdel32.prg in your c:\wntk4hrb\ntkcore\ folder.

    BR
    jnd
    •  
      CommentAuthorettman
    • CommentTimeNov 6th 2009
     
    Hi jnd! I was mistakenly surrounding the filename with the double quotes as if I was at a C: prompt.
    ie: '"c:\Test\My file with Long name.txt"'
    So, I was getting .F. all the time. Many thanks, might have different questions soon as I'm converting more types of apps. Frank.