r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[I'm new] Ask any question, and a helpful person will try to answer.

DideC
22-Jun-2005
[142]
>> help new-line
USAGE:
    NEW-LINE block value /all /skip size

DESCRIPTION:
     Sets or clears the new-line marker within a block.
     NEW-LINE is a native value.

ARGUMENTS:
     block -- Position in block to change marker (Type: block)
     value -- Set TRUE for newline. (Type: any)

REFINEMENTS:
     /all -- Set/clear marker to end of block

     /skip -- Set/clear marker periodically to the end of the block
         size -- (Type: integer)
>> a: [1 2 3 4 5 6 7 8 9 10]
== [1 2 3 4 5 6 7 8 9 10]
>> new-line a true
== [
    1 2 3 4 5 6 7 8 9 10
]
>> new-line a false
== [1 2 3 4 5 6 7 8 9 10]
>> new-line/skip a true 2
== [
    1 2
    3 4
    5 6
    7 8
    9 10
]
Normand
22-Jun-2005
[143]
Thanks, I shure missed that one.
DideC
22-Jun-2005
[144]
It's a new feature and it's not currently documented, just mentioned 
in the View 1.3 change log page.
Volker
22-Jun-2005
[145]
http://www.rebol.net/article/0059.html
RebolJohn
27-Jun-2005
[146]
Hello all.. I need help!  I am trying to append a series within a 
series..  i.e.  [ [a b c] [d e f] ].  How would I add [g h i] to 
the end of my series so that I would have [ [abc] [ d e f] [g h i] 
], and not [ [a b c] [d e f] g h i ] ?
BrianH
27-Jun-2005
[147]
append/only [ [a b c] [d e f] ] [g h i]
RebolJohn
28-Jun-2005
[148]
sweet.
Jean-François
14-Jul-2005
[149]
How to make this work?

>> foreach line read/lines request-file [prin "before " prin line 
print " after"]

** Access Error: Invalid port spec: /C/Documents and Settings/meta/Desktop/node_list.txt
** Where: halt-view

** Near: foreach line read/lines request-file [prin "before " prin 
line print " after"]
>>

I'm trying to read each line from a file and add something before 
and after

thanks
Allen
14-Jul-2005
[150x3]
foreach line read/lines (to-file request-file) [prin "before " prin 
line print " after"]
The to-file converts the response of request-file to the file! datatype 
which read/lines is expecting. The () are needed to ensure that the 
result of to-file is used as the argument
I'm pressed for time. I'm sure others will correct / amend my explanation..
Izkata
14-Jul-2005
[153]
>> request-file
== [%/C/Izkata/Rebol/bay.jpg %/C/Izkata/Rebol/palms.jpg]
>> request-file/only
== %/C/Izkata/Rebol/palms.jpg

This might be better to keep anyone from choosing multiple files:

foreach line read/lines request-file/only [print ["before " line 
" after"]]
Jean-François
15-Jul-2005
[154]
thanks guys
Allen it seems the ( ) are not necessary.
Jean-François
27-Jul-2005
[155]
Hello everyone,

I have an EditME me that I'm using to manage a project this summer. 
I would like to use Rebol to logon to my wiki, edit some pages and 
attach files to pages.

Are their any code exemples that I could use to understand how to 
go about this. I need to be able to fill in forms and send them in 
to my wiki. 
many thanks
Jean-François
20-Aug-2005
[156]
Is there something similar to Python format string in Rebol?
eFishAnt
20-Aug-2005
[157x3]
Have you read the CGI how tos?
http://www.rebol.com/docs/cgi1.htmland    http://www.rebol.com/docs/cgi2.html
after those, the RBBS project does some dynamic pages generated from 
databases and key values http://www.rebol.com/docs/cgi-bbs.html
  HOWEVER, when delving into anything CGI (not wiki link, so maybe 
not what you want) it takes some heavy head-scratching
Gregg
22-Aug-2005
[160]
There is no PRINTF-like function in REBOL right now. Eric Long wrote 
one which should be available somewhere (or write to me privately). 
RT has mentioned it more than once; the hard part will be designing 
the interface to it. I wouldn't want a standard FORMAT function to 
work like PRINTF myself, but I think it would be good if there was 
one out there for pople to use who wanted it.
BrianH
13-Sep-2005
[161]
I know I've been around for a while, but it's been so long since 
I submitted anything to the REBOL.org script library that all the 
rules have changed. So I'm new again :(


What headers should I add to the script to integrate it into the 
script library? I'd like to BSD license it - how do I indicate that? 
Are there any other headers that are necessary? How do I indicate 
that a minimum version of REBOL is required (Core compatible, but 
I use a few recent features)?


This is related to an extended version of the compress-source function 
I made for the Canvas section.
BrianH
14-Sep-2005
[162]
If there is a page on REBOL.org that explains this, could someone 
post the link?
Rebolek
14-Sep-2005
[163]
http://www.rebol.org/cgi-bin/cgiwrap/rebol/one-click-submission-help.r
Sunanda
14-Sep-2005
[164]
Alternatively. try to upload without a Library header.....One'll 
get added, and you can then edit it.


[It'd be good to get one more script in the Library. Right now we 
have 666, and that's an iconic number for some people :-)]
Graham
14-Sep-2005
[165]
here on the other side of the world, it looks like 999
Sunanda
14-Sep-2005
[166]
...That's the number of the beast's yoga trainer?
Graham
14-Sep-2005
[167]
No, that's the number of years Australia will get to keep the Ashes 
once they win it back.
Sunanda
14-Sep-2005
[168]
:-)
PeterWood
14-Sep-2005
[169]
Australia may well win back the Ashes at some stage but they never 
get to keep them. The men with excruciating taste in ties keep them 
under lock and key in the Long Room.
RobertDumond
14-Sep-2005
[170]
Hello, everyone... Ii am using encryption in Rebol/SDK, and I would 
like to store the actual binary value returned from the port as a 
string... not the to-string value, but the binary value... for example, 
if I get back #{455121D505CD240595E530589ADCD7787F22EF9DE899D6D8} 
from the port, I would like to store 455121D505CD240595E530589ADCD7787F22EF9DE899D6D8 
as a string in a file... does anyone know if this is possible?
Gabriele
14-Sep-2005
[171]
enbase/base #{...} 16
RobertDumond
14-Sep-2005
[172]
sweet!  thank you very much
BrianH
14-Sep-2005
[173x3]
Thanks Kru! I'm editing it now.
Hey all, what is the current expected syntax for the Needs header 
of a REBOL script?
Last time I checked (a while ago) it was undocumented.
Graham
14-Sep-2005
[176]
needs: 'rebol
BrianH
14-Sep-2005
[177]
There is some way of specifying the Core and View versions, I remember, 
but don't remember how.
Graham
14-Sep-2005
[178]
I would suggest that is probably like the tested-under block

viz: needs: [ core tuple! view tuple! ]
Sunanda
14-Sep-2005
[179]
Some examples here:
http://www.rebol.net/notes/rv13-changes.html
eg  needs: [view 1.3.0 sound 1.2.4]
BrianH
14-Sep-2005
[180]
Thanks! I'm currently testing my script compression code to see what 
the minimum versions of REBOL it needs.
RobertDumond
14-Sep-2005
[181x2]
i am testing version 2.0.1 of RebDB, and I am having problems doing 
a selection with an equality 'where' predicate... 
do %db.r
if any [ exists? %my-table.ctl 
         exists? %my-table.dat ] 
       [ delete/any %my-table* ]
db-create my-table [col1 col2 col3 col4 col5]
db-insert my-table [next "1" "2" "3" "4"]
db-commit my-table
test: db-select/where * my-table 1
print ["key: " test] 
test: db-select/where * my-table 
	'col1= 1 'col2= "1" 'col2= "2"
print ["eq:  " test]
test: db-select/where * my-table 
	all ['col1= 1 'col2= "1" 'col2= "2"]
print ["eq:  " test]
test: db-select/where * my-table 
	[all ['col1= 1 'col2= "1" 'col2= "2"]]
print ["eq:  " test]
can anyone tell me what i am doing wrong in this test?  tia
Ashley
14-Sep-2005
[183]
The where refinement expects a block, so just use code like the following:

	db-select/where * my-table [col1 = 1]
	db-select/where * my-table [all [col1 = 1 col2 = "1"]]
Bobik
4-Oct-2005
[184]
Could you help me anybody? I have a simple sequences of commands: 
  view layout [label "hello"]  tx: request-text "something" ... I 
need invoke request-text immediately after main window showed - not 
after the main window is closed...
Gabriele
4-Oct-2005
[185]
view/new instead of view
Bobik
4-Oct-2005
[186x2]
what an easy solution :-)  Thank you!
I thought, that view/new i can use only if i  allready have the other 
window.. (sorry for my english..)
Henrik
4-Oct-2005
[188x2]
are you looking for DO-EVENTS ?
whoops, seems you are not, but VIEW/NEW and DO-EVENTS usually go 
hand in hand with the first opened window
Bobik
4-Oct-2005
[190]
So if i use view layout [.....] it is as some as if i use: view/new 
layout [....] do-events ?
Henrik
4-Oct-2005
[191]
correct, and between VIEW/NEW and DO-EVENTS, you can do initialization 
stuff after showing the window