FeaturesPluginsDocs & SupportCommunityPartners

NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

Help: Why i can not use print to output a variable

 
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users
View previous topic :: View next topic  
Author Message
sky_mrlin



Joined: 21 Jun 2009
Posts: 6

PostPosted: Sun Jun 21, 2009 10:41 am    Post subject: Help: Why i can not use print to output a variable Reply with quote

The code is:
A=0
print A
But there is no result in the netbeans console,and there is any error info.Why? Is there anyone know the reason.
Thanks.
Back to top
View user's profile Send private message MSN Messenger
Erno Mononen
Posted via mailing list.





PostPosted: Mon Jun 22, 2009 6:47 am    Post subject: Help: Why i can not use print to output a variable Reply with quote

Hi,

sky_mrlin wrote:
Quote:
The code is:

A=0

print A

But there is no result in the netbeans console,and there is any error info.Why? Is there anyone know the reason.


Strange, I don't know now what could be causing this. What platform do
you use? How do you run the file? I guess it works fine if you run the
same file from the command line using the same platform as within the
IDE, right?

Erno
Back to top
sky_mrlin



Joined: 21 Jun 2009
Posts: 6

PostPosted: Mon Jun 22, 2009 9:12 am    Post subject: Reply with quote

Thanks . The IDE is Netbeans 6.5.1 and ruby platform is 1.8.6. It is good to run in other IDE,eg,SciTE.
Back to top
View user's profile Send private message MSN Messenger
Erno Mononen
Posted via mailing list.





PostPosted: Mon Jun 22, 2009 1:42 pm    Post subject: Help: Why i can not use print to output a variable Reply with quote

I guess this could be an issue with the output window I/O - can you try
whether it works in 6.7 RC3? If not, could you turn on detailed logging
(http://wiki.netbeans.org/FaqRubyNBLogging67) and send the log file to me?

BTW, I assume "puts A" works fine, right? What about print with a line
break?

Thanks,
Erno


sky_mrlin wrote:
Quote:
Thanks . The IDE is Netbeans 6.5.1 and ruby platform is 1.8.6. It is good to run in other IDE,eg,SciTE.











Back to top
sky_mrlin



Joined: 21 Jun 2009
Posts: 6

PostPosted: Tue Jun 23, 2009 3:01 am    Post subject: Reply with quote

Hi,
Thanks for your help. 6.7RC3 is OK,it can output the value normally.
BTW, your assumption is right . It can works fine use "puts" to output a variable in Netbeans 6.5.1 platform.
Quote:
I guess this could be an issue with the output window I/O - can you try
whether it works in 6.7 RC3? If not, could you turn on detailed logging
(http://wiki.netbeans.org/FaqRubyNBLogging67) and send the log file to me?

BTW, I assume "puts A" works fine, right? What about print with a line
break?
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB