Subj : Re: code example To : Digital Man From : Finnigann Date : Fri Aug 18 2006 11:26 pm -=> With regards to the social ramifications; Digital Man wrote to Finnigann <=- DM> Re: Re: code example DM> By: Finnigann to Digital Man on Fri Aug 18 2006 10:13 pm > -=> With regards to the social ramifications; > Digital Man wrote to Finnigann <=- > > DM> Re: Re: code example > DM> By: Finnigann to Digital Man on Fri Aug 18 2006 07:42 pm > > > -=> With regards to the social ramifications; > > Digital Man wrote to Finnigann <=- > > > > DM> Re: code example > > DM> By: Finnigann to All on Fri Aug 18 2006 05:12 pm > > > > > Can anyone post some baja code for extracting messages from the messa > > > data base. sort of the opposite of smbutl (i cmd) > > > > DM> smbutil can be used to extra messages from the message base. Baja > > DM> doesn't have any functions for directly accessing the message data b > > DM> files. > > > > Well that was my first impulse. But after studying the help/opt list. I > > am stumped as to which switches would define the message(s) to extract. > > DM> I suppose I mispoke: you can *read* messages (interactively) with > DM> smbutil (using the 'r' command), but can't really "extract" message > DM> (programatically). This could be done with small JS module however. > > DM> If I knew more about exactly what you're trying to accomplish, I might > DM> be able to help more. > > If you recall Jazzman's sports... game? I was wondering how syncdata > might be useful for tying other BBS' together. > > SMBUTIL can be made to upload game data. getting it out is another > item. > > But if a javascript segment can be called to cull out messages for the > door (making large assumptions) or added functionality to smbutil, > would be great. DM> Even if smbutil could extract a specific message, how would you know DM> *which* message to extract? Well I was thinking that switches would tell what values to look for in a message. Let me just make up some for demonstration puposes. usage: smbutil [-opts] cmd cmd: l[n] = list msgs starting at number n r[n] = read msgs starting at number n v[n] = view msg headers starting at number n i[f] = import msg from text file f (or use stdin) e[f] = import e-mail from text file f (or use stdin) n[f] = import netmail from text file f (or use stdin) /m = export message from message base /t = set 'To' to sort for /s = set 'subject' to sort for h = dump hash file s = display msg base status c = change msg base status d = delete all msgs m = maintain msg base - delete old msgs and msgs over max p[k] = pack msg base (k specifies minimum packable Kbytes) opts: f = set 'from' user name for imported message e = set 'from' user number for imported message smbutil /m /tdoorgame /sweeknumber \sbbs\xtrn\doorgame\input.dat > Of course you know I'm not a programmer, but is this function in the > SDK? I would think someone else would have sought out syncdata to > transport data before now. DM> A JS module would be the way to go. I'm not sure which SDK you're DM> referring to. The XSDK does not include any message base functionality. DM> The SMBLIB is available as a separate library for message base access, DM> but a JS module would be much easier. Well could something highly configurable be written in baja/javascript? // syncdata.js // Pulls text from syncdata message base // $Id: syncdata.js,v .12 2006/08/19 rswindell Exp $ // @format.tab-size 8, @format.use-tabs true load("sbbsdefs.js"); // Available Command-line options: // // m indicates extraction // t sets 'To' field value // s sets 'Subject' field value // syncdata is the default message base // // syncdata.js /m /tdoorgame /sweeknumber \sbbs\xtrn\doorgame\input.dat P_OPENCLOSE _ _ _ _ _ _ _ _ _ / \ / \ / \ / \ / \ / \ / \ / \ / \ ( F | i | n | n | i | g | a | n | n ) \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ .... "Other kings said I was _daft_ to build a castle in a swamp!" --- MultiMail/Win32 v0.47 þ Synchronet þ Bits-N-Bytes - bnb.dtdns.net / bnb.synchro.net .