Search Results

Search found 45013 results on 1801 pages for 'example'.

Page 17/1801 | < Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >

  • What sense does asynchronous IO make if the thread is blocked anyway (see example)

    - by codymanix
    Hello, I found an example for async ftp upload on msdn which does the following (snippet): // Asynchronously get the stream for the file contents. request.BeginGetRequestStream( new AsyncCallback (EndGetStreamCallback), state ); // Block the current thread until all operations are complete. waitObject.WaitOne(); The thing what I do not understand here is, which sense does asynchronous IO make if the thread is blocked anyway with an explicit waithandle. I always thought the advantage of asynchronous IO was that the user/programm does not have to wait.

    Read the article

  • Sencha Touch Nestedlist JSON format Example

    - by Ankit Shah
    Hello Friends, I'm new to sencha. Using Sencha touch. I would like to make nested listing like first of list comes, when click on one of the link it goes to another listing, when click on second list's any link it opens image like that. http://dev.sencha.com/deploy/touch/examples/nestedlist/ Above example is perfectly suitable for this one more than that below application. http://touchstyle.mobi/app/ When i'm doing any modification in http://dev.sencha.com/deploy/touch/examples/nestedlist/ it gives no error or warning i'm using Fedora 11 linux Google Chrome. Can anybody tell me what is the JSON perfect format for this nested listing. I will do it for dynamic. So if anyone help to get static nested list it would be better.

    Read the article

  • DNS delegation on same server with DDNS and second slave server

    - by Austin
    I have two servers running BIND, the first is setup as the master of two zones and the second as a slave for those zones. The zones are example.com and ddns.example.com. I have DDNS running and thousands of device entries are dynamically created in ddns.example.com. I wanted to keep DDNS separate from the main example.com, so I created a separate zone that the DHCP servers update. Considering these zones are hosted on the same server, is it possible to have delegation working from example.com to ddns.example.com? For example if my workstation's search domain is example.com and pointed towards 10.1.10.1 for its DNS provider, I would like to be able to resolve hostname.ddns. As it is, I can resolve hostname.ddns.example.com, but would like to be able to resolve just hostname.ddns. Alternatively, if the workstation's search domain is ddns.example.com, what settings do I need to be able to change to be able to resolve web, ftp, etc, which are all hosts in the parent, example.com zone? Does the ddns.example.com zone need to forward to the example.com zone? Again, all the zones are setup on the same server with a second server setup as a slave. named.conf: zone "example.com" IN { type master; file "example.com"; allow-update { none; }; } zone "ddns.example.com" IN { type master; file "ddns.example.com"; allow-update { key dhcp-update; }; } example.com zone file: $ORIGIN . $TTL 86400 example.com IN SOA ns1.example.com. hostmaster.example.com. ( serial, refresh, retry, etc. ) NS ns1.example.com. NS ns2.example.com. $ORIGIN example.com. ns1 A 10.1.10.1 ns2 A 10.1.10.2 web A 10.1.15.30 ftp A 10.1.15.31 host3 A 10.1.15.32 $ORIGIN ddns.example.com NS ns1 NS ns2 ns1 A 10.1.10.1 ns2 A 10.1.10.2

    Read the article

  • Simple example of popup authentication with Facebook Graph API

    - by ensnare
    Trying to get Facebook to authenticate my users via a javascript popup. Right now, I have: <input type="button" value="Connect with Facebook" onclick="window.open('https://graph.facebook.com/oauth/authorize?client_id=XXXXXXXXXXX&redirect_uri=http://example.com/step2&display=popup')" /> But when the user logs in via Facebook, the popup just displays the Facebook.com homepage. I'd like for the popup to authenticate the user and go away so that I can start retrieving user data from the graph api. Is there a better / easier way to do this? Simple examples are appreciated. Thank you.

    Read the article

  • Problem with "Hello, WebView" example

    - by arakn0
    Hi there, I'm new in android development and I am trying out the WebView example in the official android site. http://developer.android.com/guide/tutorials/views/hello-webview.html But I do everything they say...which is pretty simple: I create the project, edit the layout file, then i add the code, etc. No problems building...but when I launch the app in the simulator I just got a black screen. It is like if the Layout is empty...like if the WebView is not created. does anybody know what I am doing wrong? Thanks in advanced

    Read the article

  • Maven multi-module project with many reports: looking for an example

    - by hstoerr
    Is there an open source project that can serve as a good example on how to use the maven site plugin to generate reports? I would prefer it to consist of many modules, possibly hierarchically structured use as many plugins as possible (surefire, jxr, pmd, findbugs, javadoc, checkstyle, you name it) the reports should be aggregated: if some tests fail you want to have a single page that shows all modules with failing tests, not only a gazillion individual pages to check include enterprisey stuff (WAR, EAR etc), but this is not so important. The idea is to have something where you can gather ideas on how it is done and what is possible.

    Read the article

  • Ask for an example code for parsing xml and get attributes by using GData API

    - by ben
    When i use GData API in my app for parsing xml,how could i get attributes and it's value? Wanted a piece of example code.Thanks a lot. xml: <playurls><url islive="0" type="3" bit_stream="1">http://vods.netitv.com//dy2/2010/02/08/cf584b76-3579-4b75-a0c8-f7a473d79f8c.mp4 </url><url islive="0" type="3" bit_stream="2">http://vods.netitv.com//dy/2010/02/08/965bbc65-8ec0-4c50-98ae-c69a831926cc.mp4 </url><url islive="0" type="2" bit_stream="1">http://vods.netitv.com//dy2/2010/02/08/cf584b76-3579-4b75-a0c8-f7a473d79f8c.mp4 </url><url islive="0" type="2" bit_stream="2">http://vods.netitv.com//dy/2010/02/08/965bbc65-8ec0-4c50-98ae-c69a831926cc.mp4 </url></playurls>

    Read the article

  • MySQL LOAD DATA LOCAL INFILE example in python?

    - by David Perron
    I am looking for a syntax definition, example, sample code, wiki, etc. for executing a LOAD DATA LOCAL INFILE command from python. I believe I can use mysqlimport as well if that is available, so any feedback (and code snippet) on which is the better route, is welcome. A Google search is not turning up much in the way of current info The goal in either case is the same: Automate loading hundreds of files with a known naming convention & date structure, into a single MySQL table. David

    Read the article

  • Delphi - COM/OLE starting example needed

    - by durumdara
    Hi! 10 years have ellapsed since I used COM/OLE, and I forget 90% of them. Now we need to make a COM object to access some data from PHP/Python (this is specific thing, the php ODBC don't access the output params of a DataBase - like stored proc output), and my idea the I realize a minimal object with one method, and PHP/Python can call this to get the output... procedure ExecSQL(Config, IP, Port, DBName, SQL, IDFieldName : variant) : output output is [IDValue, ErrorMsg, HResult] Please help me a very little example, how to start it? I need only this, but I'm confused by many ActiveX/COM in the palette. What I need to use to make a simple COM DLL, and how to register my COM object with this DLL? Thanks: dd

    Read the article

  • Example of tree.drop_mode with jQuery sortable anywhere

    - by fred
    Hello Everyone, I have a working tree of galleries next to a sortable list of image thumbnails. I've been vainly trying to set up the galleries tree so that users can add images to the galleries by dropping the sortable thumbnails on to the galleries tree. I've been told this requires drop_mode. All efforts to get it to work have failed and I can't really make heads or tails of the drop_mode documentation. I've sought out some working examples via Google of just such an application but have failed. Can anyone point me to a working example of either a draggable or sortable list that successfully drops on to a tree and passes along some parameters between the two? Thanks!

    Read the article

  • Is this an example of polymorphism?

    - by computer-science-student
    I'm working on a homework assignment (a project), for which one criterion is that I must make use of polymorphism in a way which noticeably improves the overall quality or functionality of my code. I made a Hash Table which looks like this: public class HashTable<E extends Hashable>{ ... } where Hashable is an interface I made that has a hash() function. I know that using generics this way improves the quality of my code, since now HashTable can work with pretty much any type I want (instead of just ints or Strings for example). But I'm not sure if it demonstrates polymorphism. I think it does, because E can be any type that implements Hashable. In other words HashTable is a class which can work with (practically) any type. But I'm not quite sure - is that polymorphism? Perhaps can I get some clarification as to what exactly polymorphism is? Thanks in advance!

    Read the article

  • Rails 3.1. Cocoon link_to_add_association example needed

    - by BazZy
    pls show any example of using Cocoon's 'link_to_add_association' with html_options. https://github.com/nathanvda/cocoon Documentation says: html_options: extra html-options (see link_to) There are two extra options that allow to conrol the placement of the new link-data: data-association-insertion-node : the jquery selector of the node data-association-insertion-position : insert the new data before or after the given node. But i can not understand what to do, if i want insert partial just before my "add element" link. Not just after parent's div begin. This not gonna work: <%= link_to_add_association "add element", f, :production_years, :position = "after_all" %

    Read the article

  • Delphi code example tab in MSDN

    - by Remko
    If you have checked out the new MSDN layout recently you will notice that there are tabs for example code: Do you see that there is room for F# (is there really anyone using that?) but not for Delphi! My question is: can we all ask Microsoft to add a Delphi tab and as a community take care off adding samples. If you agree please request Microsoft to add the Delphi tab (the more people, the more likely Microsoft will respond). I don't know if there's a web based feedback possible but this mail address is listed on msdn for feedback: [email protected]

    Read the article

  • Simple pygtk and threads example please.

    - by wtzolt
    Hello, Can someone give me a simple example involving threads in this manner, please. Problem with my code is that when I click button One, GUI freezes until its finished. I want buttons to stay responsive when def is being executed. How can i fix that? class fun: wTree = None def __init__( self ): self.wTree = gtk.glade.XML( "ui.glade" ) dic = { "on_buttonOne" : self.one, "on_buttonTwo" : self.two, } self.wTree.signal_autoconnect( dic ) gtk.main() def sone(self, widget): time.sleep(1) print "1" time.sleep(1) print "2" time.sleep(1) print "3" def stwo(self, widget): time.sleep(1) print "4" time.sleep(1) print "5" time.sleep(1) print "6" do=fun() Pretty please, help me.

    Read the article

  • i want to search my database for example i want to search the word "google yahoo"

    - by user2926370
    i want to search my database for example i want to search the word "google yahoo" and when i enter that i should able to look the rows which has google and yahoo. It is not required to be in the same order and google besides yahoo. No matter wherever it is in the line and give me a simple logic to it. i can able to query that thing.something like select * from table where column like("%google%yahoo%"). I want to develop this thing in php but how can i insert %. Do i need to use if statement so that i can insert % in between the words whenever i find spaces orelse is there any other logic to do it simpler?

    Read the article

  • Problems with http://wall.plasm.it/examples/example-the-wall/ - Images

    - by wolfau
    It is probably piece of cake for You, but I'm in the black hole now and I don't know what is the problem with The Wall. I would like to do something as www.wall.plasm.it/examples/example-the-wall/. Please - look at: www.megainstal.pl/ there is not any images. Could You help with fix it? I will be really grateful for any help/information. Short story: 1) I download the files from github: https://github.com/plasm/the-wall 2) I changed only 3 files: 01-wall.css, index.html, 01-wall.js (case: basic) 3) in 01-wall.js I declared images: var a = new Element("img[src=../../img/middle/"+counterFluid+".jpg]"); 4) images that are: 1 to 76.jpg Could you point me to where I making a mistake? If You going to see source files - I zip that's all in the one file: files.zip S. from Poland Thank You in advance!

    Read the article

  • What's wrong with this jQuery example?

    - by Sven Larson
    The following jQuery example should put some text into the div, but it doesn't. I tried Firefox, Google Chrome and Internet Explorer. <html> <head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" language="javascript"></script> <script language="javascript"> $(window).load(function() { $('adiv').html('<p>hello world</p>'); alert('done'); }); </script> </head> <body> <div id="adiv"> </div> </body> </html> Sorry, this might be stupid, but I'm stuck.

    Read the article

  • Build custom error messages in model files (example: using the 'pluralize' method)

    - by user502052
    I am using Ruby on Rails 3.0.7 and I would like to use the pluralize method in a my model file in order to properly build custom error messages. For example, I would like to do something like the following: NAME_MIN_LENGHT = 2 # Is 2 but I plan to change that (maybe dynamically... if it is possible) in future development validates :name, :length => { :minimum => NAME_MIN_LENGHT, :too_short => "is too short (minimum is #{pluralize(NAME_MIN_LENGHT, "character")})", }, How can I do that? Is it advisable? Why?

    Read the article

  • Sample/Example needed for a table/field setup

    - by acctman
    Can someone explain the statement below to me with a working sample/example. thanks in advance. You can not create duplicate fields, but simply add a single extra field, "coupleId", which would have a unique id for each couple; and two rows (one for each person) per couple; then JOIN the table against itself with a constraint like a.coupleId = b.coupleId AND a.id < b.id so that you can condense the data into a single result row for a given couple.

    Read the article

  • Tab widget example not running

    - by michbeck
    I'm trying to reproduce the tabwidget example (http://developer.android.com/resources/tutorials/views/hello-tabwidget.html). I'm not really sure what's the problem, I got no errors while compiling, but i cannot see the application on the emulators screen. It would be excellent if maybe anyone could have a look at my classes and tell me what's my mistake? I've packed my project here: http://etanto.com/TabTest.zip here's the console dump while the run: [2010-06-10 09:18:34 - TabTest] Launching a new emulator with Virtual Device 'Virtual1' [2010-06-10 09:18:35 - TabTest] New emulator found: emulator-5554 [2010-06-10 09:18:35 - TabTest] Waiting for HOME ('android.process.acore') to be launched... [2010-06-10 09:19:05 - TabTest] WARNING: Application does not specify an API level requirement! [2010-06-10 09:19:05 - TabTest] Device API version is 8 (Android 2.2) [2010-06-10 09:19:05 - TabTest] HOME is up on device 'emulator-5554' [2010-06-10 09:19:05 - TabTest] Uploading TabTest.apk onto device 'emulator-5554' [2010-06-10 09:19:05 - TabTest] Installing TabTest.apk... [2010-06-10 09:19:22 - TabTest] Success! [2010-06-10 09:19:22 - TabTest] \TabTest\bin\TabTest.apk installed on device [2010-06-10 09:19:22 - TabTest] Done!

    Read the article

  • Need example of how to create/manipulate image pixel data with iPhone SDK

    - by whiskeyspider
    Looking for a simple example or link to a tutorial. Say I have a bunch of values stored in an array. I would like to create an image and update the image data from my array. Assume the array values are intensity data and will be updating a grayscale image. Assume the array values are between 0 and 255 -- or that I will convert it to that range. This is not for purposes of animation. Rather the image would be updated based on user interaction. This is something I know how to do well in Java, but am very new to iPhone programming. I've googled some information about CGImage and UIImage -- but am confused as to where to start. Any help would be appreciated.

    Read the article

  • Android: i need password example

    - by user1475122
    I have long been looking for a functioning example of a password, but I have not found. can someone help me? Explained more clearly: I have a TextField named password and I want that when it is written in 123 and press the button it goes to another activity if it is written in 123 if not it would inform the "wrong password!" and that the password is found file, which is / sdcard / Android / password.txt if you understood :) SORRY FOR MY BAD ENGLISH! I'm Finnish, and a young coder :) ( I hope someone may be understood :D )

    Read the article

  • Help modifying QuartzDemo example application

    - by BittenApple
    Can anyone please, oh sweet pain, please take me out of my misery by writing a simple example on how the heck you pass a number (int value) which gets created in 1 .m file to another .m file. In the apple demo application called QuartzDemo, there is a file called QuartzImages.m This file has the following line of code: [CODE]CGPDFPageRef page = CGPDFDocumentGetPage(pdf, 1);[/CODE] Notice the (pdf, 1) in that line. This number should be replaced with an integer variable. Now, there is also a file called MainViewController.m. In that file, there is a method? called -(void)viewDidLoad In that method, I want to assign a number to the integer variable which would replace the damn "1" with whatever number I want. I have been pulling my hair trying to get this done, reading beginning iPhone 3 Development book, dev documentation and God knows what not, without results. Any help would be greatly appreciated... Sigh.

    Read the article

  • [solved] What's wrong with this jQuery example?

    - by Sven Larson
    The following jQuery example should put some text into the div, but it doesn't. I tried Firefox, Google Chrome and Internet Explorer. <html> <head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" language="javascript"></script> <script language="javascript"> $(window).load(function() { $('adiv').html('<p>hello world</p>'); alert('done'); }); </script> </head> <body> <div id="adiv"> </div> </body> </html> Sorry, this might be stupid, but I'm stuck.

    Read the article

  • Example of contravariance

    - by Misha
    I am thinking of the following example to illustrate why contravariance is useful. Let's consider a GUI framework with Widgets, Events, and Event Listeners. abstract class Event; class KeyEvent extends Event class MouseEvent extends Event trait EventListener[-Event] { def listen(e:Event) } Let Widgets define the following methods: def addKeyEventListener(listener:EventListener[KeyEvent]) def addMouseEventListener(listener:EventListener[MouseEvent]) These methods accept only "specific" event listeners, which is fine. However I would like to define also "kitchen-sink" listeners, which listen to all events, and pass such listeners to the "add listener" methods above. For instance, I would like to define LogEventListener to log all incoming events class LogEventListener extends EventListener[Event] { def listen(e:Event) { log(event) } } Since the trait EventListener is contravariant in Event we can pass LogEventListener to all those "add listener" methods without losing their type safety. Does it make sense ?

    Read the article

< Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >