Announcement

Collapse
No announcement yet.

command line compile for PB\DLL?

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

  • command line compile for PB\DLL?

    I'd like to build myself a text editor for PBdll and I want to be able to compile my code from it, I was wondering if there was a way to compile a bas file from command line.

    Somthing in the nature of C:\PBDLL60\Bin\PBedit.exe /c myProject.bas
    and have it spit out my exe or dll

    is this implimented currently?



    ------------------
    -----------
    Paul Dwyer
    Network Engineer
    Aussie in Tokyo
    (Paul282 at VB-World)

  • #2
    From the PB/DLL helpfile:

    Run PBDLL.EXE from the DOS prompt using a command line with the following syntax:

    PBDLL [/Ipath] [/L] [/Q] FileName

    where FileName is the name of the source file to compile. If you just type PBDLL (omitting FileName), you'll get a dialog box asking for the name of the file to compile.
    If FileName does not have an extension, PB/DLL assumes .BAS. If you don't want the file you're compiling to have an extension, you must append a period (.) to the end of FileName.
    The PB/DLL compiler is a 16-bit Windows application. Your source code files can not use long filenames, nor can you use long filenames when specifying a path. For example, if your source is located in “C:\Program Files\MyProject\myfile.bas”, you must specify the path as “c:\progra~1\myproj~1\myfile.bas” (case is not significant).
    It is important to note that programs you compile are true 32-bit Windows applications and will support long filenames. All Basic language statements that use filenames (OPEN, DIR$, NAME, KILL, etc…) will support long filenames. Only metastatements such as #INCLUDE and #RESOURCE do not support long filenames as these are interpreted at compile time.

    Include
    The /I command line option provides the compiler with a search path when looking for #INCLUDE and #RESOURCE files. See #INCLUDE and #RESOURCE for more details.

    Log
    The /L command line option causes the compiler to generate a log file with all of the compile results, including error code and error line number if an error occurs during compile time.

    Quiet
    The /Q command line option causes the compiler to not display a message box when compiling is finished. This should only be used with the /L option.



    ------------------
    Peter.
    mailto[email protected][email protected]</A>
    Regards,
    Peter

    Comment


    • #3
      Thanks dood,

      You're a legend!

      Paul


      ------------------
      -----------
      Paul Dwyer
      Network Engineer
      Aussie in Tokyo
      (Paul282 at VB-World)

      Comment


      • #4
        Isn't there an API call that will return the "short" version of a given filename?
        Dan

        Comment


        • #5
          Long filename to short:

          Code:
          #Compile Exe
          #Include "Win32api.inc"
          Function PbMain () As Long
            Local lZStr As Asciiz * %MAX_PATH
            GetShortPathName Command$, lZStr, SizeOf (lZStr)
            Print "Long file name : "; Command$
            Print "Short file name: ";lZStr
          End Function

          ------------------
          Peter.
          mailto[email protected][email protected]</A>
          Regards,
          Peter

          Comment

          Working...
          X