Search Results

Search found 8942 results on 358 pages for 'print r'.

Page 198/358 | < Previous Page | 194 195 196 197 198 199 200 201 202 203 204 205  | Next Page >

  • Can't open a sheet on a window twice

    - by moldov
    I'm opening a sheet on a window , the first time the sheet opens correctly, but if I close it, and try to open again it doesn't work, I just get the system alert sound. - (IBAction) showSpeedSheet:(id)sender { [NSApp beginSheet:addEditPackagePanel modalForWindow:[[NSApp delegate] window] modalDelegate:nil didEndSelector:nil contextInfo:nil]; } -(IBAction)endSpeedSheet:(id)sender { [NSApp endSheet:addEditPackagePanel]; [addEditPackagePanel orderOut:sender]; } I can't find what's wrong, the app doesn't print any error on the log.

    Read the article

  • Why is "int + string" possible in statically-typed C# but not in dynamically-typed Python?

    - by Salvador Dali
    While studying C# I found it really strange, that dynamically typed Python will rise an error in the following code: i = 5 print i + " " whereas statically typed C# will normally proceed the similar code: int i = 5; Console.Write(i + " "); I would expect other way around (in python I would be able to do this without any casting, but C# would require me to cast int to string or string to int). Just to highlight, I am not asking what language is better, I am curious what was the reason behind implementing the language this way.

    Read the article

  • There is a JavaScript error in my rails application!

    - by Small Wolf
    As the title said, I got a problem! i encountered the "RJS Error:[object error]",the code in my application is page << "#{hidden_print("#{url_for(:controller => 'tables', :action => 'dispatch', :id => id, :pop => true, :print =>true)}")} " the method hidden_print is def hidden_print(url) "window.parent.headFrame.document.all.iframe_helper.src = '#{url}';" end

    Read the article

  • Drupal: link to latest node of a certain content type

    - by james6848
    I have a link within a block. At the moment it goes to a list of newsletter nodes: <p><a href="<?php global $base_url; print $base_url;?>/news-events/newsletter">Read our latest newsletter</a></p> What I would prefer is to have it go to the latest node of the content type 'newsletter', is this possible?

    Read the article

  • What is the best way to generate XML from a C based CGI application using the SQLite API?

    - by Tommy
    Learning the basics of XML for the first time from W3C tutorials. How are most XML files generated? Does the server side application usually print a complete XML file to be parsed each time there is new data? I have a CGI application in C and it includes the SQLite API. Is the best way to do some sort of printf to a XML file (using my data from the database) so it can be parsed? Thanks.

    Read the article

  • Customising Tweets

    - by thesunneversets
    I have some PHP creating automatic Twitter updates, which in the small print at the bottom reads "[date/n minutes ago] via API". Is it possible to somehow change the "via API" part to something more useful and descriptive?

    Read the article

  • script to sum all numbers in a file (linux)

    - by Mark Roberts
    I have a file which contains several thousand numbers, each on it's own line: 34 42 11 6 2 99 ... I'm looking to write a script which will print the sum of all numbers in the file. I've got a solution, but it's not very efficient. (It takes several minutes to run.) I'm looking for a more efficient solution. Any suggestions?

    Read the article

  • TERM environment variable not set

    - by rahkarp
    I'm using python to develop an app and want to view running processes.The code txt = commands.getoutput("top -d 1") print txt gives an error "TERM Environment Variable not set" Can someone tell me what this means and how to solve this

    Read the article

  • How to pickle and unpickle objects with self-references and from a class with slots?

    - by EOL
    Is it possible to pickle an object from a class with slots, when this object references itself through one of its attributes? Here is a simple example: import weakref import pickle class my_class(object): __slots__ = ('an_int', 'ref_to_self', '__weakref__') def __init__(self): self.an_int = 42 self.ref_to_self = weakref.WeakKeyDictionary({self: 1}) # __getstate__ and __setstate__ not defined: how should this be done? if __name__ == '__main__': obj = my_class() # How to make the following work? obj_pickled = pickle.dumps(obj) obj_unpickled = pickle.loads(obj_pickled) # Self-references should be kept: print "OK?", obj_unpickled == obj_unpickled.ref_to_self.keys()[0]

    Read the article

  • .NET Library for drawing tables with GDI+

    - by Jan Willem B
    I need to print the contents of a datagridview, simple text in rows and columns, with GDI+ in .NET to paper. To do this, I need to iterate over the rows, draw lines, iterate over the columns, calculate width, height, wrap the contents if contents do not fit on one line, etc. This is all possible, but is there a library that simplifies the drawing of tables in GDI+ and abstracts some of the difficulties away?

    Read the article

  • Why Netbeans stop completing my php code?

    - by T1000
    It seems that Netbeans don't know about functions like mysql_query and complete only globals like $_SESSION or $_POST and stuff like echo and print (don't know about print_r)... Screenshot: http://img163.imageshack.us/img163/4290/clipboard03vr.png

    Read the article

  • Is there a command line C++ to PDF converter with syntax highlighting?

    - by NoMoreZealots
    I need to supply "Source code documents w/ Line numbers" which is essentially just a PDF of the source code with syntax highlighting and Line numbers. Is there any existing command line tools for windows that I could call from a script as a "build release version" script? Right now I'm doing it manually using VC++, which isn't even the dev enviroment the code is for a TI processor, and a PDF printer driver, which has a pop up for each file I print.

    Read the article

  • Hyphen in Array keys

    - by Vincent
    All, I have an array with hyphens in the key name. How do I extract the value of it in PHP? It returns a 0 to me, if I access like this: print $testarray->test-key; This is how the array looks like testarray[] = {["test-key"]=2,["hotlink"]=1} Thanks

    Read the article

  • Problems with usually short solutions to test in a programming language

    - by sub
    I'm currently creating an experimental programming language for fun and educational purpose and in search for some tasks beyond the classical "Hello, World!"-program. I've already come up with these ideas: Print out the program's input Calculator Generate Prime numbers, Fibonacci series What other interesting programming problems do you have for me to test? It would be good if they required the language to solve a broad spectrum of task, take prime numbers for example: You need variables, increment them, divide them, perform actions under certain conditions, etc.

    Read the article

  • HTML tags in ojective c programming

    - by user1661826
    Is there any function in Objective-C to print a list of elements as unordered HTML elements. For ex - [@"a--b-c---d" htmlList: @"--"] returns @ "ab-c-d" the "--" is the delimiter to seperate the string of elements. I have used NSSArray to store the input string and function componentsSeperatedByString:@"--" to get the elements. How do I go ahead in adding the HTML tags li and /li between elements and ul and /ul at the end of the entire list? Please help, Im a beginner in objective -C

    Read the article

  • Why can't my function access a variable in an enclosing function?

    - by nailer
    I know about the LEGB rule. But a simple test of whether a function has read access to variables defined in an enclosing function doesn't seem to actually work. Ie: #!/usr/bin/env python2.4 '''Simple test of Python scoping rules''' def myfunction(): print 'Hope this works: '+myvariable def enclosing(): myvariable = 'ooh this worked' myfunction() if __name__ == '__main__': enclosing() Returns: NameError: global name 'myvariable' is not defined Am I doing something wrong? Is there more to it than the LEGB resolution order?

    Read the article

  • PHP alternative for MSSOAP.SoapClient30 in ASP.NET

    - by sasa
    Hello, Can somebody help me with this - I need some tips or code to connect to wsdl service, send XML request and than print response on client side. I only have primer written in ASP.NET and need PHP alternative: function doXMLRequest(Xmltext) Set oSOAP = Server.CreateObject("MSSOAP.SoapClient30") oSOAP.ClientProperty("ServerHTTPRequest") = True oSOAP.mssoapinit sys_xmlservice, "", "", "" oSOAP.ConnectorProperty("Timeout") = 600000 myXMLResponse = oSOAP.XMLReq(XmlText) doXMLRequest=myXMLResponse set oSOAP=nothing end function Thanks in advance! :)

    Read the article

  • C# Saving an arraylist to a file?

    - by Zka
    I have a simple program where I would like to save an arraylist to a file, so that when the program is restarted, it loads from the file to the arraylist in memory. Is this possible in C#? Or do I need to itterate over the arraylist countaining my custom classes and in someway print them out? Any tips on a correct way to do this?

    Read the article

  • Python regular expression

    - by user3692739
    I have this HTTP Request and I want to display only the Authorization section (base64 Value) : any help ? This Request is stored on a variable called hreq I have tried this : reg = re.search(r"Authorization:\sBasic\s(.*)\r", hreq) print reg.group() but doesn't work Here is the request : HTTP Request: Path: /dynaform/custom.js Http-Version: HTTP/1.1 Host: 192.168.1.254 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate Referer: http://domain.com/userRpm/StatusRpm.htm Authorization: Basic YWhtEWa6MDfGcmVlc3R6bGH I want to display the value YWhtEWa6MDfGcmVlc3R6bGH Please I need your help thanks in advance experts

    Read the article

  • doing arithmetic upto two significant figures in Python?

    - by user248237
    I have two floats in Python that I'd like to subtract, i.e. v1 = float(value1) v2 = float(value2) diff = v1 - v2 I want "diff" to be computed upto two significant figures, that is compute it using %.2f of v1 and %.2f of v2. How can I do this? I know how to print v1 and v2 up to two decimals, but not how to do arithmetic like that. thanks.

    Read the article

< Previous Page | 194 195 196 197 198 199 200 201 202 203 204 205  | Next Page >