356988-368700

356793-359462 subjects 357187-358795

^ Shared memory creation in ruby
356988 [infibit gmai] I am new to ruby and I want to write code which makes shared memory and
356991 [usenet-nospa] Ahem.  "int main".  (Unless you're in a freestanding environment,
356992 [infibit gmai] Well I am on windows Xp.I have been trying to get this working.
356994 [usenet-nospa] Well, I'm afraid I can't help -- I know nothing about Windows programming.

^ Reg : Auto select Drop down list
356989 [pradheep.rb ] drop down list boxes. in firts dropdown list box if i select a "state"
356999 [b.candler po] It sounds like you are writing a web application, and you want to make
357053 [jazzezravi g] Go thru this link --> http://bonrouge.com/~chain_select_js

356997 [b.candler po] Yes, there are. You can send a RARP packet on the network segment to

^ Using Ruby /DL to invoke function in windows dll
357000 [infibit gmai] I have a C++ code converted into a windows Dll.I want to use Ruby /DL to
+ 357015 [aaron tender] C++ code?  Unless you know how to munge your functions the same way your
+ 357020 [albertschlef] There are some utility programs that let you look into a library and see
+ 357022 [albertschlef] (It goes without saying that if you distribute your source code,
| 357047 [infibit gmai] I used PE explorer and saw the dill in disassembler.Attached is the
| 357048 [infibit gmai] Also the problem is that the MSVC++ compiler is munging them in a weird
| 357060 [infibit gmai] Solved .Thank you all and specifically Albert Schlef
+ 357071 [martindemell] This is the right thing to do, and will save you headaches in the long

^ How to change stdin separator (perl vs ruby)
357001 [sak proxecto] I have to process very very big text files and not line per line, I have
+ 357002 [perfectly.no] STDIN.each_line("%") { |line|
| 357007 [sak proxecto] Thanks Stefan for the answer, that's exactly what I need, thanks Xavier
+ 357003 [fxn hashref.] Ruby has also $/ among its global variables. The methods #gets and + 357004 [ruby slightl] File.open(path_to_file, 'r') do |f| 357006 [shortcutter ] Note that this statement is true for \n as well! ^ Hurry Up Now, Free Check Of$327 With Your Name.
357008 [m.76ahesh gm] Hurry Up, Free Check Of $327 With Your Name. ^ Re: Can't install hpricot gem 357009 [marcel.corso] On ubuntu 9.10 I had to install the ruby-dev package 358522 [otterlei gma] Has anybody gotten this error on Windows 7? ^ difference between [] and Array[] 357021 [am artbot.de] all the time i thought [] would be a shortcut for the corresponding + 357024 [shortcutter ] You defined Array#[] and nothing else. + 357027 [ryand-ruby z] no. [1, 2, 3] is an array literal and part of the syntax. It does not = ^ ruby cross-platform File.basename 357023 [jtprince gma] What is the best idiom for generating a cross-platform basename? + 357025 [shortcutter ] What's wrong with using File.basename? | 357028 [jtprince gma] File.basename("C:\\path\\to\\file.txt") # -> gives: "C:\\path\\to\ | 357072 [shortcutter ] Well, File.basename will work properly on a Windows system. Do you + 357029 [marnen marne] No it doesn't. The problem is that there is no easy way to tell what OS 357031 [s.korteling ] No, a / is not a valid filename character. None of these characters are 357032 [marnen marne] Thanks for the correction. However, \ *is* a valid filename character ^ Exit method? 357030 [artemisc360 ] I am new to programming and am writing a program in ruby that serves as 357033 [marnen marne] If you need to ask the mailing list a question like this, then you are + 357034 [artemisc360 ] Thanks for the encouragement. I guess I should stick to 'Hello World' | 357041 [ehsanul_g3 h] =20 + 357035 [echristopher] That's a little harsh, although it would probably be true if the | + 357036 [marnen marne] Oh, if that's the case, then yes, my response was uncalled-for. I did | | 357089 [shortcutter ] way it | | 357099 [marnen marne] Yeah, I thought so too -- und ich bin Englischmuttersprachler. | | 357107 [masonkelsey ] Harsh and shock tactics seem to be universal solutions for problems that | | 357112 [marnen marne] The problem appeared to exist. Nothing is to be gained from mincing | | 357115 [usenet-nospa] If the goal is to cause someone's behavior to change, politeness is | | 357117 [marnen marne] Agreed. And I really don't think I was impolite. | | 357120 [usenet-nospa] It came across as more confrontational, but that is in practice easier | | 357125 [marnen marne] OK, how would you have put it? | | 357126 [usenet-nospa] That's a good question, and I don't remember enough of the initial context | + 357770 [echristopher] Sorry to resurrect this, but I've had second thoughts. Are | 357785 [shortcutter ] robert@fussel:~$ ruby19 -e 'p File.method(:foreach)'
|   357795 [b.candler po] A similar concept you can use is module_function, which can be used as
+ 357134 [josh.cheek g] I'm not sure that this is true. Sometimes, when the person writing the
+ 357138 [marnen marne] Quite true.  I certainly didn't know the answer off the top of my head
+ 357140 [usenet-nospa] The problem is that the newbies will often figure things out *incorrectly*,
+ 357146 [marnen marne] Yes indeed!  And skilled newcomers could play an important role here.
+ 357148 [albertschlef] He said we was going to *write* a tutorial. This doesn't necessarily

^ Re: difference between
357037 [albertschlef] I don't think so. Array() is a method of the Kernel module. So, I think,
+ 357038 [xenogenesis ] Array([1,2,3]) calls the Array kernel method on the Array created by [1,
| + 357039 [xenogenesis ] ffffff passes the Array created by [1, 2, 3] to the Array method of
| + 357040 [albertschlef] Right. Thanks for correcting me.
+ 357049 [ryand-ruby z] think,=20
357078 [am artbot.de] thanx so far, nice trick Ryan to see the difference

^ trouble using blowfish
357042 [lathty gmail] ruby version: ruby 1.9.1p243
357045 [justincollin] The gem you are using apparently has not been updated to work with Ruby 1.9.
357046 [lathty gmail] Thank you for your advise. That did the trick.

357044 [kvetch gmail] I have a script that parses a bunch of data off the wire and pipes it
357082 [shortcutter ] File.foreach file_name do |line|

^ Test script
357050 [twaynz hotma] I am new to ruby and scripting.
+ 357054 [justincollin] First, pick a testing framework and set up your tests. If you have
+ 357056 [jazzezravi g] Already ruby has framework named as Test::Unit.
357057 [twaynz hotma] I have used Test:Unit and the assert_equal function, but I am just able
357104 [richard.conr] What you are attempting to do here is an acceptance test, not a unit test.
357109 [twaynz hotma] Yes I know, but I need to call my program with different arguments
+ 357116 [justincollin] You can use backticks () to call your program and return the output as
+ 357119 [richard.conr] Well thats what I thought I said - you invoke the shell from within your

^ Call for Paper The International Journal of Computer Science (IJCS)
357051 [ijcsorgedito] Call for Paper

^ Need help with Code (Input Functionality)
357052 [mikejoebro y] puts 'What is your name?'
+ 357055 [jazzezravi g] Did you heard about chomp method earlier?
+ 357058 [usenet-nospa] Hmm, that's odd.  My quick trial produces the "expected" output.
| + 357059 [justincollin] Really? Because you shouldn't be (unless we have a different idea of
| | 357064 [usenet-nospa] I was expecting to see output from all of them, but if I understood the
| + 357061 [jazzezravi g] The exact solution for above(first post) issue
|   357083 [jgabrielygal] puts 'What is your name?'
|   357101 [marnen marne] Or use chomp! on first call, though that's a bit less maintainable.
+ 357062 [josh.cheek g] Here is an explanation of why you get what you do, and examples of how to
+ 357063 [mikejoebro y] Hey Guys!

^ Global rescue - DRY (don't repeat yourself)
357065 [jan jan-rosl] I am trying to implement report to a bug management system in rails.
357066 [jazzezravi g] class Library
+ 357067 [jazzezravi g] You can use the first line as,
+ 357068 [jan jan-rosl] Thanks P.Raveendran
+ 357069 [jan jan-rosl] Sorry, but I ends up adding
357070 [boesemar gmx] class Code
357073 [jan jan-rosl] Thanks for your suggestion. It Works.
357131 [boesemar gmx] local = 'test'
357163 [jan jan-rosl] class VariableStack
357232 [jan jan-rosl] Is there a way to include "raw" ruby source code in ruby method, or an
357336 [vikkous gmai] It seems to me that a macro is the best way to get to almost what you

357076 [fxn hashref.] Ruby needs to interpret the file where the class is defined before you
357077 [serega.sheyp] I understand it.
357081 [fxn hashref.] Ah yes let me explain a bit more. Doing
357086 [serega.sheyp] Nice opportunity to make silly mistakes, especially if you work in group
357106 [serega.sheyp] Excuse me for disturbing you again.
357111 [fxn hashref.] Yes you have the __FILE__ keyword. That evaluates to the filename of

^ Find has key from a value
357084 [johnnybutler] I cant seem to figure this out, if i have a hash value can i then get
+ 357087 [jacob.d.mitc] value exists in the hash but what i need to know is what is the key for
+ 357088 [shortcutter ] Hash#rassoc
357090 [johnnybutler] Thanks,

^ Building Ruby 1.9 in HP-UX IA 11.31
357085 [sebastian ye] Has anyone tried to build Ruby 1.9 on the HP-UX 11.31 platform?
+ 357121 [ryand-ruby z] You'd be better off writing ruby-core@
+ 357158 [sebastian ye] After searching around and doing some more testing I have managed to
357424 [sebastian ye] Just a minor update on building Ruby 1.9 on HP-UX 11.31, in the previous

^ how to use rdebug in ruby script
357091 [thillaibooks] how to use rdebug in a pure ruby script file.Please me
+ 357253 [rogerpack200] I've wondered that myself.
+ 357256 [marco-oweber] require 'rdebug' at the location where you want to start debugging.
357285 [rogerpack200] Which rdebug is it loading ("gem which rdebug")?  My system doesn't seem
357287 [marco-oweber] Sorry, I mixed them up: rdebug is not debug. I was talking about the

^ Re: [ANN] Ripple 0.5 (Initial Release)
357092 [aldric trevo] I, for one, am enthused. Riak is open-source, too. Neat!

^ Re: Ripple 0.5 (Initial Release)
357097 [aldric trevo] Posted via http://www.ruby-forum.com/.

^ Can SWIN CommonDialog.openFilename() select multiple files?
357103 [alex.decaria] Can the SWIN CommonDialog.openFilename() method be used to select
357130 [chris.hulan ] On Feb 11, 10:32=A0am, Alex DeCaria <alex.deca...@millersville.edu>
357139 [s.korteling ] OFN_EXPLORER  = 0x00080000
357206 [chris.hulan ] I was able to get your code to work, surprisingly the docs seem to
357227 [alex.decaria] matter how many files I select, files.length is coming out to be 1.
357247 [chris.hulan ] I installed the latest Ruby 1.9 via RubyInstaller.org
+ 357257 [alex.decaria] I'm running Ruby v.1.8.6 that I installed using the Windows 1-click
| 357264 [alex.decaria] I forgot to mention that I'm running it from the Windows command line.
+ 357309 [alex.decaria] unzipped the DevKit into my C:\Ruby directory.  I don't know what to do
357494 [chris.hulan ] I followed the instructions in install.txt and it Just Worked!
357554 [alex.decaria] SUCCESS!  I installed Ruby 1.9 and vrswin090207, and your code works as
357609 [chris.hulan ] On Feb 17, 2:44=A0pm, Alex DeCaria <alex.deca...@millersville.edu>

357105 [gilsapir86 g] i saw this very cheap macbook pro

^ Re: Welcome to our (ruby-talk ML)         You are added automatically
357110 [mardughard h] # help

^ n00b: text processing from magnetic stip input
357122 [john jmondo.] I'm trying to make a program and I'm really bad at text processing. The
+ 357123 [marnen marne] Then you will have to get better. :)
+ 357124 [jgabrielygal] Show us what you tried, it's easier to help that way. Anyway, you
357127 [john jmondo.] Sorry about the confusion. Apparently I asked the question wrong. I was
357128 [Rob AgileCon] Well, break it into parts...  I'll use %r{ } for Regexp literals

^ [ANN] johnson 2.0.0 prerelease 1
357129 [smparkes smp] johnson version 2.0.0.pre1 has been released!=20

^ ruby sspi
357133 [ttjk0115 gma] Is there any way that I can read user name through SSPI in Ruby on Rails?

^ Delete Item In Array If Conditions Met
+ 357142 [thinkfuture ] reject!
+ 357143 [mat patch.co] The #reject! method is an iterator; so is the for loop (effectively).
| 357147 [thinkfuture ] Thanks guys that did it!
| 357149 [albertschlef] You've better ask your question in the Rails forum. You're using some
+ 357144 [s.korteling ] reject! does the iterating for you, so you can (must) leave out the for
357145 [tony medioh.] In addition to reject! there's also Array#delete_if

^ REXML translate (XPath?)
357150 [andrew.cove ] Can somebody explain or put me to an explanation of how to use
357184 [mark thomasz] group_list.elements["entry[translate(title,
357186 [andrew.cove ] That appears to work for REXML.  Thanks Mark.

^ Finding exact date before specified months & weeks
357153 [martin angle] Dear All,
357154 [Rob AgileCon] I'm not sure that I understand exactly what you need, but perhaps this
357155 [martin angle] Thanks rob,

^ String to symbol
357156 [serega.sheyp] #Base class for all models.
357159 [shortcutter ] IMHO that method would rather be called ensure_attr_allowed - if you
357161 [serega.sheyp] I've added "!" to show that it can throw exception (like in rails)
357165 [shortcutter ] or
357168 [serega.sheyp] Is there any opportunity to add attributes to instance, not to class?
+ 357171 [serega.sheyp] 2435:         self.class.send(:scope, :create).each { |att,value|
+ 357172 [jgabrielygal] Send the define method to the singleton class of the object, instead

^ how to set permission '777' to dir?
357162 [hb.pat87 hot] permission '777'.
357174 [albertschlef] That's because, on POSIX systems, the permissions of a new
357349 [hb.pat87 hot] I try FileUtils.chmod() after create new file but it still has permision
357353 [b.candler po] begin
357358 [hb.pat87 hot] it's show me
357359 [hb.pat87 hot] oh I try in Linux with the same code it's
357415 [albertschlef] You mean to say that Windows 7 has the unixy owner/group/world

^ Problem with array in hash
357166 [serega.sheyp] require 'p'
357167 [jgabrielygal] This is because the + method of Array doesn't modify the array, it
357169 [serega.sheyp] Thank you for explaining.

^ how to detect used protocol (SOAP, JSON, XML etc.)
357170 [jeljer me.co] I am building an ESB (Enterprise Service Bus) for a Content Management
+ 357173 [jeljer me.co] Wel after a discussion with a few students I realized i could of course
+ 357180 [hassan.schro] If all these "protocols" are being delivered over HTTP, you can look
| 357215 [jeljer me.co] Hmm no it isn't :( mostly they are send with just a tcp connection.)
+ 357229 [b.candler po] This is an encapsulation issue.
| 357294 [jeljer me.co] Thank you for your insights in this matter. I do think it is not
| 357319 [b.candler po] Then you're not just squirting the object over a raw TCP socket; you're
| 357341 [jeljer me.co] Yes you are right. I could use an extra field. But I need the ability to
| + 357351 [b.candler po] So either force the clients to use the same protocol you have defined,
| | 357361 [jeljer me.co] Yes i have gone with the second option. Because now I can for example
| + 368700 [me waltonhoo] Actually, in threads if one crashes, everything crashes.  If you have
+ 368530 [unsure tacti] Silly wabbit!  Just take a look at the JSON, XML and SOAP files you are
+ 368531 [unsure tacti] oops sorry, take the vertical bar out of that regex.
+ 368539 [b.candler po] Note that even when fixed, that regexp would match
368545 [jeljer me.co] Ehm guys. Why are you all commenting on a 6 months old  post  ;)

^ [noob] Problem with arrays
357177 [sokaos gmail] I have a few issue using arrays.
+ 357178 [sokaos gmail] Ok, my mistake, I was lost in loops :p
+ 357179 [marnen marne] I saw your later post that this is working, but I thought that since
357181 [luc honk-hon] just=20
357195 [josh.cheek g] I would also define getters for boolean variables

^ Re: Problem with arrays
357182 [marnen marne] Thanks!  I forgot about until.

^ PAPER PRESENTATIONS AND SEMIMAR TOPICS.
357183 [m.76ahesh gm] PAPER PRESENTATIONS AND SEMIMAR TOPICS.