• Correct BAJA Command

    From MRO@VERT/BBSESINF to DesotoFireflite on Wednesday, December 13, 2017 15:53:26
    Re: Correct BAJA Command
    By: DesotoFireflite to All on Wed Dec 13 2017 02:06 pm

    Need some help on a baja compare statement. I want to compare a current users name (Handle) with the last entry of a file im keeping created by baja.

    I'll use me as an example

    What I want is if I was the last entry "Desotofireflite" in the log file called call.dat, I want it to do nothing, but if I wasn't the last entry in the call.dat, I want it to write to the call.dat my name. My problems is I don't know how to compare a handle to the last entry of a file. My guess would be

    COMPARE_ARS Handle c:\sbbs\data\call.dat
    If True
    Goto end
    end_if

    FOPEN FILE O_WRONLY|O_CREAT|O_APPEND "%Jcalls.dat"

    :end


    none of this code is correct and your fopen file is doing nothing.

    you are better off doing a batchfile using the tail program and then getting an error lvl after using the file or grep command on a temporary file created by tail. you will need win32 unix programs,btw.

    17 years ago i could seek into a file and load it up into a string that you could read with baja but i've forgotten a lot of that shit.
    ---
    þ Synchronet þ ::: BBSES.info - free BBS services :::
  • From DesotoFireflite@VERT/VALHALLA to MRO on Thursday, December 14, 2017 05:53:37
    Re: Correct BAJA Command
    By: MRO to DesotoFireflite on Wed Dec 13 2017 03:53 pm

    none of this code is correct and your fopen file is doing nothing.

    you are better off doing a batchfile using the tail program and then getting an error lvl after using the file or grep command on a temporary file created by tail. you will need win32 unix programs,btw.

    17 years ago i could seek into a file and load it up into a string that

    I think echicken gave me what I ndde to make this happen, but I really need to take the time to learn the js language and re do the entire baja script. It is one of your older scripts, that has worked well for me, but I'm trying to update it a bit for my system. I've been updating it through the years to do things I want it to do, but I just could not figure out haw to make it compare a file entry to a result, even after reading the baja docs. Thanks for jumping in and replying.

    SysOp: C.G. Learn, AKA: DesotoFireflite
    Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
    Valhalla II! - (GAP) - bbs.valhallabbs.com:24
    A Gamers Paradise - Over 150 Registered Online Game Doors!

    Play Trade Wars Between 10 Other BBS's On Valhalla's Trade Wars Game Server!

    Featuring Legion, A New RPG, Available On Both Systems!

    --- Don't eat the yellow snow!
    þ Synchronet þ Valhalla Home Services þ USA þ http://valhalla.synchro.net
  • From echicken@VERT/ECBBS to DesotoFireflite on Thursday, December 14, 2017 10:32:40
    Re: Correct BAJA Command
    By: DesotoFireflite to MRO on Thu Dec 14 2017 05:53:37

    I think echicken gave me what I ndde to make this happen, but I really need to take the time to learn the js language and re do the entire baja script. It is one of your older scripts, that has worked well for me, but

    If your current script works and you've customized it over the years, there may not be a compelling reason to redo it in JS. Could be a lot of work for little benefit, taking the learning curve into account. Both languages are suitable for most simple BBS tasks.

    If you want to learn JS, though, replicating one of your existing Baja modules in it is a good way to learn. In the long run it's a more useful language to know, makes a lot of tasks simpler, and enables some stuff that just can't be done in Baja.

    ---
    echicken
    electronic chicken bbs - bbs.electronicchicken.com - 416-273-7230
    þ Synchronet þ electronic chicken bbs - bbs.electronicchicken.com
  • From DesotoFireflite@VERT/VALHALLA to echicken on Thursday, December 14, 2017 15:26:23
    Re: Correct BAJA Command
    By: echicken to DesotoFireflite on Thu Dec 14 2017 10:32 am

    If your current script works and you've customized it over the years, there may not be a compelling reason to redo it in JS. Could be a lot of work for little benefit, taking the learning curve into account. Both languages are suitable for most simple BBS tasks.

    I think I'm going to incorporate your fix into my present script, and get it working for now, as I'm pretty comfortable working with BAJA.

    If you want to learn JS, though, replicating one of your existing Baja modules in it is a good way to learn. In the long run it's a more useful language to know, makes a lot of tasks simpler, and enables some stuff that just can't be done in Baja.

    As soon as I get my current script going, and working, I think your idea about trying to redo it in js will help me learn the language, and I can take my time doing it. Right now, when I look at js, it just looks greek to me, at least with baja, I can somewhat follow what is going on. Thanks for your help ec.

    SysOp: C.G. Learn, AKA: DesotoFireflite
    Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
    Valhalla II! - (GAP) - bbs.valhallabbs.com:24
    A Gamers Paradise - Over 150 Registered Online Game Doors!

    Play Trade Wars Between 10 Other BBS's On Valhalla's Trade Wars Game Server!

    Featuring Legion, A New RPG, Available On Both Systems!

    --- The truth will set you free. But first it'll piss you off.
    þ Synchronet þ Valhalla Home Services þ USA þ http://valhalla.synchro.net
  • From Nightfox@VERT/DIGDIST to DesotoFireflite on Thursday, December 14, 2017 14:26:18
    Re: Correct BAJA Command
    By: DesotoFireflite to echicken on Thu Dec 14 2017 03:26 pm

    As soon as I get my current script going, and working, I think your idea about trying to redo it in js will help me learn the language, and I can take my time doing it. Right now, when I look at js, it just looks greek to me, at least with baja, I can somewhat follow what is going on. Thanks for your help ec.

    If you do learn JavaScript, it might also help you understand other languages. C, Java, C#, and some other languages have a syntax that's similar to JavaScript (although slightly different). With each language, you'd have to learn its own libraries for what you want to do, but as far as the syntax, it's similar.

    Nightfox

    ---
    þ Synchronet þ Digital Distortion: digitaldistortionbbs.com
  • From MRO@VERT/BBSESINF to DesotoFireflite on Thursday, December 14, 2017 17:51:31
    Re: Correct BAJA Command
    By: DesotoFireflite to MRO on Thu Dec 14 2017 05:53 am

    I think echicken gave me what I ndde to make this happen, but I really need to take the time to learn the js language and re do the entire baja script. It is one of your older scripts, that has worked well for me, but I'm trying to update it a bit for my system. I've been updating it through the years to do things I want it to do, but I just could not figure out haw to make it compare a file entry to a result, even after reading the baja docs. Thanks for jumping in and replying.



    is it a last callers mod?
    ---
    þ Synchronet þ ::: BBSES.info - free BBS services :::
  • From DesotoFireflite@VERT/VALHALLA to MRO on Friday, December 15, 2017 06:45:25
    Re: Correct BAJA Command
    By: MRO to DesotoFireflite on Thu Dec 14 2017 05:51 pm

    is it a last callers mod?

    Yes. it's the last version you had. I took it from there, and have updated throughout the years. I have it now doing just about everything I want. This last mod is to keep the same user from showing up if they log on and off the system alot of times in one session and fill up the screen with their name only.

    SysOp: C.G. Learn, AKA: DesotoFireflite
    Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
    Valhalla II! - (GAP) - bbs.valhallabbs.com:24
    A Gamers Paradise - Over 150 Registered Online Game Doors!

    Play Trade Wars Between 10 Other BBS's On Valhalla's Trade Wars Game Server!

    Featuring Legion, A New RPG, Available On Both Systems!

    --- Don't eat the yellow snow!
    þ Synchronet þ Valhalla Home Services þ USA þ http://valhalla.synchro.net
  • From MRO@VERT/BBSESINF to DesotoFireflite on Friday, December 15, 2017 17:46:11
    Re: Correct BAJA Command
    By: DesotoFireflite to MRO on Fri Dec 15 2017 06:45 am

    Re: Correct BAJA Command
    By: MRO to DesotoFireflite on Thu Dec 14 2017 05:51 pm

    is it a last callers mod?

    Yes. it's the last version you had. I took it from there, and have updated throughout the years. I have it now doing just about everything I want. This last mod is to keep the same user from showing up if they log on and off the system alot of times in one session and fill up the screen with their name only.


    i think you can check the ARS of U_LTODAY and have it display and not
    write to the last calls based on how many logons that day.
    ---
    þ Synchronet þ ::: BBSES.info - free BBS services :::
  • From DesotoFireflite@VERT/VALHALLA to MRO on Saturday, December 16, 2017 15:30:14
    Re: Correct BAJA Command
    By: MRO to DesotoFireflite on Fri Dec 15 2017 05:46 pm

    Yes. it's the last version you had. I took it from there, and have
    updated throughout the years. I have it now doing just about
    everything I want. This last mod is to keep the same user from showing
    up if they log on and off the system alot of times in one session and
    fill up the screen with their name only.


    i think you can check the ARS of U_LTODAY and have it display and not write to the last calls based on how many logons that day.

    Ok, thanks, I will see if I can figure that out.

    SysOp: C.G. Learn, AKA: DesotoFireflite
    Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
    Valhalla II! - (GAP) - bbs.valhallabbs.com:24
    A Gamers Paradise - Over 150 Registered Online Game Doors!

    Play Trade Wars Between 10 Other BBS's On Valhalla's Trade Wars Game Server!

    Featuring Legion, A New RPG, Available On Both Systems!

    --- Old farts never die! They just smell that way...
    þ Synchronet þ Valhalla Home Services þ USA þ http://valhalla.synchro.net
  • From MRO@VERT/BBSESINF to DesotoFireflite on Saturday, December 16, 2017 15:36:36
    Re: Correct BAJA Command
    By: DesotoFireflite to MRO on Sat Dec 16 2017 03:30 pm


    i think you can check the ARS of U_LTODAY and have it display and not write to the last calls based on how many logons that day.

    Ok, thanks, I will see if I can figure that out.



    but if you have it stop writing to the last callers, it really doesnt serve a purpose anymore.
    ---
    þ Synchronet þ ::: BBSES.info - free BBS services :::
  • From DesotoFireflite@VERT/VALHALLA to MRO on Sunday, December 17, 2017 07:24:31
    Re: Correct BAJA Command
    By: MRO to DesotoFireflite on Sat Dec 16 2017 03:36 pm

    but if you have it stop writing to the last callers, it really doesnt serve a purpose anymore.

    My goal, if I can manupulate it is to still write it to another file called dupe.dat, that way I can still track all the callers, but the same name won't show to all the callers over and over again. It's still a work in progress. as I'm having to change the structure everytime I think of things I want it to do. I'll post the code if I'm successful :)

    SysOp: C.G. Learn, AKA: DesotoFireflite
    Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
    Valhalla II! - (GAP) - bbs.valhallabbs.com:24
    A Gamers Paradise - Over 150 Registered Online Game Doors!

    Play Trade Wars Between 10 Other BBS's On Valhalla's Trade Wars Game Server!

    Featuring Legion, A New RPG, Available On Both Systems!

    --- A true friend knows who you are... But likes you anyway.
    þ Synchronet þ Valhalla Home Services þ USA þ http://valhalla.synchro.net