World: r3wp
[I'm new] Ask any question, and a helpful person will try to answer.
older | first |
Endo 1-Dec-2011 [4626] | I'm also working on very similar to your case right now. I don't know if its useful for you but here how I do (on Windows) command: {csvde -u -f export.ldap -d "ou=myou" -r "(objectClass=user)" -s 10.1.31.2 -a "" "" -l "DN,sn,uid,l,givenName,telephoneNumber,mail"} call/wait/console/shell/error command %export.err ;export all users, bind annonymous if 0 < get in info? %export.err 'size [print "error" editor %export.err halt] lines: read/lines %export.ldap ;create an object from the first line (field names, order may differ from what you give in the batch) ldap-object: construct append map-each v parse first content none [to-set-word v] 'none foreach line lines [ ( set words-of o: make ldap-object [] parse/all line {,} append users: [] o ) ] ;append all valid users as an object to a block probe users I hope it gives some idea. |
MagnussonC 1-Dec-2011 [4627] | Interesting. Thnx. |
Endo 8-Dec-2011 [4628] | There is no "CONTINUE" in any loop in REBOL, right? We have BREAK but no CONTINUE as in other languages. Rarely I need it :x |
Henrik 8-Dec-2011 [4629] | R2 does AFAIK not have it, but R3 does. |
Endo 8-Dec-2011 [4630] | R3 does? I didn't know that. Thanks |
Sunanda 8-Dec-2011 [4631] | You can fake 'continue in R2 using 'loop 1 ... as this (incorrect!) implemention of BuzzFizz shows: for n 1 100 1 [ loop 1 [ if n // 3 = 0 [print [n "buzz"] break] if n // 5 = 0 [print [n "fizz"] break] ] ] |
Endo 8-Dec-2011 [4632x3] | ; use following to have the functionality. I have a very long script and I don't want to put it inside a IF block do-block: [ long long script ] foreach a b [ if any [a = 3 a = 5 ...] do-block] ;continue on other values of a. |
Magnusso: I faced a problem parsing exported LDAP users using above CSVDE command-line tool. Because it fails if you don't use -u argument and if your ldap data has some unicode data. And if you use -u the exported file will be unicode and cannot be read/parse in R2. | |
then I found a very simple way to convert a unicode file to ascii in DOS, TYPE my-unicode-file > my-ascii-file This line converts the file to ascii, just non-convertable characters looks wierd but rest is ok. | |
Gregg 9-Dec-2011 [4635] | You can also use read/binary on the data, then EXTRACT with a value of 2 to just remove all the nulls (assuming wide chars). Unicode chars will be munged that way too though. |
yubrshen 2-Feb-2012 [4636x3] | Hi, I'm tring to use "Excel Interface" of Gregg Irwin, with documentation dated 18-Dec-2004. I'm wondering if there is any way to select a worksheet's all used content, that's all cells having values? From the documentation, I don't see how. |
Also to make the Excel Interface to work, I'm wondering, where I should put the DLL file? | |
I guess that this is of some documenation, how can I open it, reb-excel-docs.rdml? | |
Gregg 2-Feb-2012 [4639x2] | The DLL should go in the dir with your script or encapped app. RDML is plain text, but I can send you the html generated from it if you want. I don't remember doing anything for finding cells with contents. |
I don't have Excel on this machine, so can't test. | |
yubrshen 2-Feb-2012 [4641x2] | Gregg, thanks!. Please the pointer on how to generate the html file from *.RDML, is through make-doc? |
Actually, I guess the generated html may already be available to me: reb-excel-docs | |
Endo 3-Feb-2012 [4643] | Yes it is in there. You can find that document online in Robert's blog. |
Gregg 3-Feb-2012 [4644] | Robert extended makedoc, but I'm not sure if this doc might build under RT's makedoc. Robert might say, but it sounds like it's on the web anyway. |
Evgeniy Philippov 13-Feb-2012 [4645x2:last] | I think REBOL is a much better name since it includes "O" (holistic approach). All names without "O" are faulty. OBERON has two O's and MACHINE CODE has a single O :) |
O makes mind think it all holistically and perfectly. GOD has O, too. Names without O don't force human recognition apparatum to loop at quality assurance of a code that is being produced. REBOL has O, too. | |
older | first |