Announcement

Collapse
No announcement yet.

Problems with attr 8 in PB/DLL 6.0

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problems with attr 8 in PB/DLL 6.0

    I am trying to write a 32-bit Windows program that installs my BBS to the hard drive.
    The problem is, when I try to use <var$> = DIR$("h:", 8)
    it always returns a null string to <var$>. Here is an excerpt from my code:

    V1$ = ENVIRON$("V1")
    NN$ = DIR$(V1$ + ":", 8)
    IF NN$ <> "TRIBBS" THEN GOTO ENDIT

    I use the DOS environment approach because I have MANY programs that
    access the Zip drive. The V1 env. var. is set in the AUTOEXEC.BAT file.
    I do this because it is MUCH easier than manually changing a bunch of
    programs every time the Zip drive letter changes.

    I have tried the 8 attr with the DIR$ function with the <file$> literals
    of "C" and "C:", and it still returns a null string.

    Is PB/DLL *flawed*, or am I using the statement wrong?

  • #2
    Some procedures in 32bits have changed and require \
    Maybe?

    Or use the API way..
    It's a simple procedure for volume name

    NN$ = DIR$(V1$ + ":\", 8)

    Comment


    • #3
      Or use the GetVolumeInformation() API function.


      -------------
      Lance
      PowerBASIC Support
      mailto:[email protected][email protected]</A>
      Lance
      mailto:[email protected]

      Comment

      Working...
      X