Search Results

Search found 10841 results on 434 pages for 'air native extension'.

Page 49/434 | < Previous Page | 45 46 47 48 49 50 51 52 53 54 55 56  | Next Page >

  • java.lang.OutOfMemoryError: unable to create new native thread for multiple threads

    - by Kaustubh Ranjan Singh
    static class solver implements Runnable { static calculator(problem){ //Some code if(condition) {solver s = new solver(newproblem); new Thread(s).start();} } Public solver(int newproblem) { this.problem = newproblem ; } public void run() { // TODO Auto-generated method stub calculator(promblem); } } i am having a big array maze of 100x100 and i am trying to solve it and i am getting an error java.lang.OutOfMemoryError: unable to create new native thread(after running a code for some times). How can solve this , How can i use ExecutorService i think that will solve the problem or i want something like thisIf Number of generated threads4K then stop the first 100 threads

    Read the article

  • Behaviour to simulate an enum implementing an interface

    - by fearofawhackplanet
    Say I have an enum something like: enum OrderStatus { AwaitingAuthorization, InProduction, AwaitingDespatch } I've also created an extension method on my enum to tidy up the displayed values in the UI, so I have something like: public static string ToDisplayString(this OrderStatus status) { switch (status) { case Status.AwaitingAuthorization: return "Awaiting Authorization"; case Status.InProduction: return "Item in Production"; ... etc } } Inspired by the excellent post here, I want to bind my enums to a SelectList with an extension method: public static SelectList ToSelectList<TEnum>(this TEnum enumObj) however, to use the DisplayString values in the UI drop down I'd need to add a constraint along the lines of : where TEnum has extension ToDisplayString Obviously none of this is going to work at all with the current approach, unless there's some clever trick I don't know about. Does anyone have any ideas about how I might be able to implement something like this?

    Read the article

  • how to convert big-endian numbers to native numbers delphi

    - by steve0
    hi all i want to know how to convert big endian numbers to native numbers in delphi i am porting some c++ code in that i came accross this part unsigned long blockLength = *blockLengthPtr++ << 24; blockLength |= *blockLengthPtr++ << 16; blockLength |= *blockLengthPtr++ << 8; blockLength |= *blockLengthPtr; unsigned long dataLength = *dataLengthPtr++ << 24; dataLength |= *dataLengthPtr++ << 16; dataLength |= *dataLengthPtr++ << 8; dataLength |= *dataLengthPtr; i am not familiar with c++ ,so i didnt understand what those operators doing can any one help ? regards

    Read the article

  • How Android 2.2 interacting with Flash 10.1 (how to use flash from my app)?

    - by zxcat
    Hi! I'm searched adobe and android developers sites, but can't find any details on this. Is it possible to use Flash as a part of my app? E.g. like a widget/GUI element? Or it's integrated in browser only and can't be simple accessible? I know, Adobe AIR apps are supported as standalone .apk. So it must be some API/SDK (from Google) to connect with Flash player. Is there any details, how to program it (more clear: launch swf from my app and interact with it)? Thank you!

    Read the article

  • Need new method for linking to native mapping from mobile web app

    - by Carter
    My mobile web apps use a map button which automatically starts the mapping features of Android and iPhone by simply linking to http://maps.google.com/maps?q=New+York. iOs 6 comes out, the links stop working, because Apple wants us to use "maps.APPLE.com". Turns out ANYTHING you send to "maps.apple.com" gets forwarded to "maps.google.com". So now I have to specially detect iOs 6 and swap out links just so Apple can forward everything back to Google anyway. Is there a clean way to open the device/native mapping app from a mobile web app that works on Android, iOs 6, and iOs pre-6, since iOs 6 nerfed it? Recently updated documentation on Apple dev site... http://developer.apple.com/library/ios/#featuredarticles/iPhoneURLScheme_Reference/Articles/MapLinks.html#//apple_ref/doc/uid/TP40007894-SW1 Both these links go to the same place http://maps.google.com/maps?q=New+York http://maps.apple.com/maps?q=New+York

    Read the article

  • Trying to re-create UI object from the native iPhone Calendar Notes

    - by FrankOS
    Probably a lame question for a start but i'm trying to re-create the ui object that's used in Apple's native Calendar to create notes. It's the basic text-field but with multiple lines. Sort of a text-area. Now i know that anything from the calendar in terms of ui objects isn't available but i have seen this in quite few apps so i'm guessing it's some sort of standard component. I must be dumb but i just cannot find it. Help please... Thx :)

    Read the article

  • Access WindowedApplication from package class.

    - by Senling
    Hi, I'm developing an AIR application, where i need to access WindowedApplication's function from the package class. This is the Main application (Partial code) import mx.events.CloseEvent; import messages.MessageWindow public function undock():void { stage.nativeWindow.visible = true; stage.nativeWindow.orderToFront(); //Clearing the bitmaps array also clears the applcation icon from the systray NativeApplication.nativeApplication .icon.bitmaps = []; } ]] Package: (Partial code) package messages { public class MessageWindow extends NativeWindow { public function MessageWindow():void { stage.addEventListener(MouseEvent.MOUSE_DOWN,onClick); } private function onClick(event:MouseEvent):void { ****** Need to call the undock method from here. ***** } } } Is it possible to call this way or suggest any other solution Thanks in advance Senling.

    Read the article

  • DLL Load Failed: %1 is not a valid win32 application

    - by glittershark
    So I have a situation where I need to make binary patches and then be able to apply them from within python. I found bsdiff which looks like a great algorithm and has a python extension module, but that extension module doesn't have a windows installer past Python 2.5 Alright, so having never even written C seriously, let alone attempted a python extension module, I set out to compile it myself. After a few hours of bashing my head against a DLL load error with MinGW32, I managed to get it compiled and built using the setup.py provided in the source of the project. However, upon importing the resulting bsdiff module, I get: ImportError: DLL load failed: %1 is not a valid Win32 application. Any advice?

    Read the article

  • ActionScript - One Button Limit (Exclusive Touch) For Mobile Devices?

    - by TheDarkIn1978
    two years ago, when i was developing an application for the iPhone, i used the following built-in system method on all of my buttons: [button setExclusiveTouch:YES]; essentially, if you had many buttons on screen, this method insured that the application wouldn't be permitted do crazy things when several button events firing at the same time. problematic: ButtonA and ButtonB are available. each button has a mouse up event which fire a specific reorganization/layout of the UI. if both button's events are fired at the same time, their events will likely conflict, causing a strange new layout, perhaps a runtime error. solution: application buttons cancel any current pending mouse up events when said button enters mouse down. private function mouseDownEventHandler(evt:MouseEvent):void { //if other buttons are currently in a mouse down state ready to fire //a mouse up event, cancel them all here. } of course it's simple to manually handle this if there are only a few buttons on stage, but managing buttons becomes more and more complicated / bug-prone if there are several / many buttons available. is there a convenience method available in AIR specifically for this functionality?

    Read the article

  • Log4net RollingFileAppender Size rollingStyle file extension

    - by BrettRobi
    I am using the RollingFileAppender and the Size rollingStyle. By default it creates backup files with a numbered extension, this drives me nuts. Is it possible to change it so it always uses a defined extension (say .txt or .log) and inserts the number as part of the file name. For example: myapp.log myapp.1.log myapp.2.log myapp.3.log Here is my current configuration: <appender name="RollingFileAppender" type="log4net.Appender.RollingFileAppender"> <file value="myapp.log"/> <appendToFile value="true"/> <rollingStyle value="Size"/> <maximumFileSize value="1MB"/> <maxSizeRollBackups value="10"/> <staticLogFileName value="true"/> <layout type="log4net.Layout.PatternLayout"> <conversionPattern value="%date{ISO8601} [%3thread] %-5level %logger{3}: %message%newline" /> </layout> </appender>

    Read the article

  • Cross-site json rpc : Python server side and Mozilla extension using Javascript client side

    - by jknair
    hello, I am building a mozilla extension that contacts a python application on a remote server to send and receive data. The python application can be used using xml-rpc from a python console.I am given the task to design a json-rpc that would contact the same application.Making the python server side has been easy which can be accesed using python console but making the mozilla extension to connect to the python serverside is what i am not understanding howto ??? how do i make cross site json rpc calls i have gone through a lot of libraries that i can find on googling but none of them seem to work i am not sure if it is because of same origin policy or my server side not able to process the data ??? ANY HELP

    Read the article

  • Error installing php extension OAuth via pecl

    - by hookedonwinter
    I'm trying to install the php extension OAuth in my local environment. php.net suggests it's super easy. You just run pecl install oauth. I tried this, and here is the output in terminal: downloading oauth-1.0.0.tgz ... Starting to download oauth-1.0.0.tgz (42,834 bytes) ............done: 42,834 bytes 6 source files, building running: phpize grep: /usr/include/php/main/php.h: No such file or directory grep: /usr/include/php/Zend/zend_modules.h: No such file or directory grep: /usr/include/php/Zend/zend_extensions.h: No such file or directory Configuring for: PHP Api Version: Zend Module Api No: Zend Extension Api No: Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. Then, rerun this script. ERROR: `phpize' failed Any tips on how to fix the errors and install OAuth succesfully? Thanks!

    Read the article

  • Help installing Zorba (XQUERY) PHP Extension on windows

    - by Davey
    Hi, I'm trying to install zorba php extension on windows and I am having all sorts of problems. I have installed the zorba binaries on my computer, but when I try to install the PECL package (pecl install zorba-alpha) I get the following error "ERROR: the DSP zorba.dsp does not exist". I've tried searching for zorba_api.dll or zorba_api.so in order to just bypass the pecl install process, but no luck. If anyone can tell me how to get the zorba extension installed on my windows php I will be eternally grateful. Alternately, if someone knows of another xquery solution for PHP that I can install, I will be equally excited and appreciative. Thank you! Davey

    Read the article

  • PHP pecl/memcached extension slow when setting option for consistent hashing

    - by HarryF
    Using the newer PHP pecl/memcached extension. Calls to Memcached::setOption() like; $m = new Memcached(); $m->setOption(Memcached::OPT_DISTRIBUTION, Memcached::DISTRIBUTION_CONSISTENT); are costing between 150 to 500ms - just in making the call to setOption() and as we're not using persistent connections but rather doing this on every request, it hurts. Delving deeper, setting Memcached::OPT_DISTRIBUTION to Memcached::DISTRIBUTION_CONSISTENT ends up calling update_continuum() in libmemcached which appears to be fairly intensive, although we're only passing a list of 15 memcached servers in, so somewhat surprising to see it take between 150 to 500ms to rebuild the continuum data structure. Could it be setting this option is only suitable for persistent connections, where it's called only once while making the initial connection? Or is this a bug libmemcached? Using the newer pecl/memcached extension 1.0.1 with libmemcached 0.38 Thanks.

    Read the article

  • Max length of a USB Cable?

    - by Click Ok
    I want to use a very long USB cable to, for example, place a webcam in a different room. The max length that I found was 5 meters. What the max length of a USB cable and... What the max length that I can get using USB extension cables? Thanks in advance!

    Read the article

  • IE and Content-disposition inline vs. extension-token

    - by pinkgothic
    Preamble So IE does Mime-Type sniffing. That part's old news. Suggestions of how to combat it tend to be along the lines of 'supply a content-type IE trusts' (i.e. anything that isn't text/plain or application/octet-stream) or 'add extraneous data at the start of the file that is definitely of the type you're serving'. Now, I'm working on an application that has to allow message attachments (like in e-mails), and we want to close up XSS vectors. IE's mime sniffing is one of those vectors - a text/plain file with html content will trigger as html. Recoding isn't an option at this point, changing the attachments the user has provided can only happen if there is absolutely no doubt about the maliciousness of the file - and someone might want to send HTML as text. Now, Microsoft's MSDN article implies the situation might be easier to fix than advertised: If Internet Explorer knows the Content-Type specified and there is no Content-Disposition data, Internet Explorer performs a "MIME sniff," [...] Great! Except I don't have IE nor current means to reliably install it (I realise this is a fairly sad state for a webdeveloper to be in, I hope to fix this soon) and this is grey theory that I can't quite seem to get confirmed one way or the other. Local sources say that line is hogwash - IE will mime sniff anything that is Content-Disposition: inline / <default> and not specific enough for its tastes in -Type. But what about x-* ('extension-token' in the RFC)? Trying to google for how browsers handle Content-Disposition: <extension-token> hasn't yielded anything (though I may just be doing it wrong, my understanding of Google is seriously slipping lately). I found one question that looked promising, but turned out to be a misunderstanding on side of the thread author, meaning that the train of thought was never actually addressed there. Question(s) Does IE really Mime sniff if you expressly pass Content-Disposition: inline? If so: Does anyone here know how browsers handle Content-Disposition: <extension-token>? If they do this in a way that is for my purposes benign, by presuming it to be synonymous with the default (effectively 'inline', though I hear it's not defined anywhere?), is it specific enough for IE not to Mime sniff? Or am I actually shooting myself in the foot by thinking of pursuing this avenue?

    Read the article

  • ASP.Net MVC 404 errors when route contains an .svc extension

    - by Kragen
    I have an ASP.Net MVC 2 site set up under IIS7 using the integrated pipeline with the following route: routes.MapRoute( "MyRoute", "mycontroller/{name}/{*path}", new { controller = "MyController", action = "Index", path = UrlParameter.Optional } ); There are no other routes above this route, but whenever I try and access the above route with a path value that has an .svc extension, for example: http://localhost/MyVirtualDirectory/mycontroller/test/somepath.svc ASP.Net returns a 404 error without executing my controller (I have a log message call at the start of the action method). If I change the extension to something benign (like .txt) it works perfectly, so seems that somewhere along the line ASP.Net is interpreting the request as a standard ASP.Net call to a web service that doesn't exist - this is definitely an ASP.Net 404 response (not an IIS response). What could be causing this, and how do I stop it from happening?

    Read the article

  • how to make a NEWS -Reader app

    - by exiang
    hey, I'm a beginner and I'm trying to make a NEWS reader app. My idea is to make an app just like N.Y Times. The question is : how do I access the news database and display on my native app ? If I make an RSS reader kinda thing, will I be able to display the contents of the news feed on my native app itself ? Please, I'v been reading and trying different tactics but not really getting anywhere close to what I want. A simple tip from you guys could really help me. thx

    Read the article

  • C# CF: How to open specific file extension with my program

    - by nuttynibbles
    Hi, Im developing a mobile application in dot net Compact framework. I managed to edit the registry HKEY_CLASSES_ROOT so that a click on file with .xyz extension will open my application. basically, i need to do some operation on this file when it's clicked. however, i realise that if i do that the first time, it reaches program.cs at static void Main. but when the program is running and i click on the file with .xyz extension again, it doesnt loads the program static void Main. i tried setting breakpoints at the form that is currently running but still nothing. so where does it go to? how can i detect file .xyz is clicked and do something??

    Read the article

  • Link to another file in chrome extension

    - by Hintswen
    I want to have a link in the popup.html file for my extension that loads another file (which will be included with the extension) how can I do this? or will I need to keep it in the same page? I tried using this code: <a href="/mail.html"> <img id="newmail_icon" src="" width="16" height="16" /> <span id="newmail">loading</span><br /> </a> But when I click the link nothing happens. I just found out that adding target="_blank" to the link will make it work and open in a new tab, but I can't get it to open in the popup. I have tried target="_self" but it didn't do anything.

    Read the article

< Previous Page | 45 46 47 48 49 50 51 52 53 54 55 56  | Next Page >