• Another problem

    From Terminator@VERT to All on Tue Aug 14 13:01:00 2001

    I am having a problem with this program. Its not copying ovoer the varbales like it should be.

    Here is the program

    # Put all the includes here
    !INCLUDE FILE_IO.INC
    !INCLUDE ERRNO.INC
    !INCLUDE USERDEFS.INC
    !INCLUDE NODEDEFS.INC
    !INCLUDE SBBSDEFS.INC
    #
    #
    #
    #
    # Put all the Dim Statements here
    int minsec maxsec newsec
    str floc info1 fn fo tp1
    set tp1 ""
    set fn ""
    set flo
    int file1
    chkfile "c:\sbbs\exec\qtv.cfg"
    if_false
    goto nocfg
    end_if
    # qtv.cfg file exist so open it.
    #
    # Read the file contents:
    #
    # 1. floc = File location
    # 2. minsec = Mimium security level to run this program.
    # 3. maxsec = Max security level to run
    fopen file1 O_RDONLY "c:\sbbs\exec\qtv.cfg"
    fread_line file1 floc
    fread_line file1 minsec
    fread_line file1 maxsec
    fread_line file1 newsec
    fclose file1
    cls
    pause
    # Check the users security level
    compare _useron.level minsec
    if_less
    goto nop
    end_if
    compare _useron.level maxsec
    if_greater
    goto nop
    end_if
    cls
    # Test ---> Test
    set fn "welcome.msg"
    #strcat fo floc
    copy fo floc
    strcat fo fn
    print fo
    chkfile fo
    if_false
    goto nowelc
    end_if
    call pause
    crlf
    goto end
    #
    #-------------------------------------------------------------------
    # End of the program

    Its the part with the strcat its not copying the varables like it should be.



    ---
    Synchronet Synchronet -> Chatfree BBS bbs.chatfree.org
  • From Digital Man@VERT to Terminator on Tue Aug 14 16:21:05 2001
    RE: Another problem
    BY: Terminator to All on Tue Aug 14 2001 08:01 pm

    Its the part with the strcat its not copying the varables like it should be.

    strcat is not used to "copy" a variable - use copy instead. strcat is used to concatenate (append) a string onto another string variable.

    -Rob
    ---
    Synchronet Vertrauen Home of Synchronet telnet://vert.synchro.net