Search Results

Search found 512 results on 21 pages for 'toby allen'.

Page 6/21 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • dynamic model is not loading fields

    - by Toby Justus
    I am using a dynamic model found on the forum of sencha. function modelFactory(name, fields) { alert(fields); return Ext.define(name, { extend: 'Ext.data.Model', fields: fields }); } I placed the alert(fields) to check what happens with the field because it was not working. I get this: [object Object],[object Object],[object Object] How can i change this into a correct way to use it in the fields? Is there a way to check if the model has been created? With Firebug or something? EDIT: i get this in firebug: [Object { name="ccuDesignation", type=null}, Object { name="wanNumber", type=null}, Object { name="carrierName", type=null}, Object { name="dataPackageName", type=null}, Object { name="simIccid", type=null}, Object { name="expiryTime", type=null}, Object { name="bytesRx", type=null}, Object { name="bytesTx", type=null}]

    Read the article

  • Managing project configurations in VS 2010

    - by Toby
    I'm working on a solution with multiple projects (class libraries, interop, web application, etc) in VS2010. For the web application, I would like to take advantage of the config transformations in VS2010, so at one point I added configurations for each of our environments: Development, Test, Production, and so on. Some time later, after having rearranged the project layout, I noticed that some projects show all of the configurations in the properties page dropdown. Some projects (added since I did that setup) show only the standard Debug & Release configurations. Once I realized that this was going to make build configurations worse, not better, I decided to remove all of the extra configurations I had added. I've removed all of the various configuration options from the solution, but the projects that had the alternate configuration options still have them, and I can't figure out how to get rid of them in individual projects. Also, now that I see that not all projects have to have the same configurations, I would like to create my environmental configurations at the solution level, and in the web application project (for the config transforms), but leave all of the class libraries with the basic Debug/Release configurations. I've been unable to find any tool in the UI, or any information on the 'Net, concerning how to set up such a thing. So, in short, what's the best/easiest way to manage configurations at the project level in VS2010?

    Read the article

  • Integrating WebSockets with Rails using Rack and Event Machine

    - by Toby Hede
    I have created an Asynchronous version of Rails 3 that I would like to integrate with a WebSocket implementation. I am using EventMachine, Ruby 1.9, Fibers and various em-flavoured libraries as documented by the wickedly good Ilya Grigorik. I have been looking at em-websocket as the handler for WebSocket connections but unsure of the best approach for hooking this into a Rails app. Ideally, this would work in a similar fashion to node.js with Express and Socket.io - incoming connections should be detected and dispatched to the WebSocket handler or the regular rails stack as indicated by the HTTP headers & etc. TL;DR WebSocket handler that plugs into an existing Rails application Transparently dispatch incoming WebSocket requests to endpoints in the app

    Read the article

  • casting BSTR as char* in a dll; different results depnding on VB/C# caller.

    - by Toby Wilson
    I have a dll function that takes BSTR parameters. These are casted as char* before being used for other things. When the dll is called from VB code this works fine. However, when it is called from C# code, only the first character is pointed to. Both of these are excel addIns for Pre-2007 and 2007+ versions of Office, which call into a faster C++ AddIn. They actually call it directly, not through Excel. The VB function declaration looks like this: Private Declare Function Test Lib "ExcelAddIn.xll" (ByVal param As String) As String The C# function declaration looks like this: [DllImport("ExcelAddIn.xll", CharSet=CharSet.Ansi)] [return:MarshalAs(UnmanagedType.BStr)] private static extern string Test([MarshalAs(UnmanagedType.BStr)] string param); When debugging the dll and watching the input BSTR values, they appear to be correct from both; just the C# one only casts the first character. Charset=CharSet.Unicode makes no difference. Any ideas anyone?

    Read the article

  • Using Selenium IDE with random values

    - by Toby Hede
    Is it possible to create Selenium tests using the Firefox plugin that use randomly generated values to help do regression tests? The full story: I would like to help my clients do acceptance testing by providing them with a suite of tests that use some smarts to create random (or at least pseudo-random) values for the database. One of the issues with my Selenium IDE tests at the moment is that they have predefined values - which makes some types of testing problematic.

    Read the article

  • What is the current state of the art in HTML canvas JavaScript libraries and frameworks?

    - by Toby Hede
    I am currently investigating options for working with the canvas in a new HTML 5 application, and was wondering what is the current state of the art in HTML canvas JavaScript libraries and frameworks? In particular, are there frameworks that support the kind of things needed for game development - complex animation, managing scene graphs, handling events and user interactions? Also willing to consider both commercial and open source products.

    Read the article

  • Objective-C memory management issue

    - by Toby Wilson
    I've created a graphing application that calls a web service. The user can zoom & move around the graph, and the program occasionally makes a decision to call the web service for more data accordingly. This is achieved by the following process: The graph has a render loop which constantly renders the graph, and some decision logic which adds web service call information to a stack. A seperate thread takes the most recent web service call information from the stack, and uses it to make the web service call. The other objects on the stack get binned. The idea of this is to reduce the number of web service calls to only those appropriate, and only one at a time. Right, with the long story out of the way (for which I apologise), here is my memory management problem: The graph has persistant (and suitably locked) NSDate* objects for the currently displayed start & end times of the graph. These are passed into the initialisers for my web service request objects. The web service call objects then retain the dates. After the web service calls have been made (or binned if they were out of date), they release the NSDate*. The graph itself releases and reallocates new NSDates* on the 'touches ended' event. If there is only one web service call object on the stack when removeAllObjects is called, EXC_BAD_ACCESS occurs in the web service call object's deallocation method when it attempts to release the date objects (even though they appear to exist and are in scope in the debugger). If, however, I comment out the release messages from the destructor, no memory leak occurs for one object on the stack being released, but memory leaks occur if there are more than one object on the stack. I have absolutely no idea what is going wrong. It doesn't make a difference what storage symantics I use for the web service call objects dates as they are assigned in the initialiser and then only read (so for correctness' sake are set to readonly). It also doesn't seem to make a difference if I retain or copy the dates in the initialiser (though anything else obviously falls out of scope or is unwantedly released elsewhere and causes a crash). I'm sorry this explanation is long winded, I hope it's sufficiently clear but I'm not gambling on that either I'm afraid. Major big thanks to anyone that can help, even suggest anything I may have missed?

    Read the article

  • JRuby-friendly method for parallel-testing Rails app

    - by Toby Hede
    I am looking for a system to parallelise a large suite of tests in a Ruby on Rails app (using rspec, cucumber) that works using JRuby. Cucumber is actually not too bad, but the full rSpec suite currently takes nearly 20 minutes to run. The systems I can find (hydra, parallel-test) look like they use forking, which isn't the ideal solution for the JRuby environment.

    Read the article

  • Handling JSON and HTML templates in jQuery

    - by Toby Hede
    I have an ajax-enabled site that presents a lot of dynamic content by interpolating JSON values with HTML. This all works fine. BUT it means I have significant amounts of HTML all through my JavaScript. For example: var template = "<div>Foo: {bar}</div><div>Blah: {vtha}</div>"; template.interpolate({bar:"bar",blah:"vtha"}); I have cut this down a fair bit - some of my dynamic elements have quite a lot of HTML and a lot going on. I am using jQuery and I am building on Rails, so if there is something smart in either framework, that would be great. For reference, the String interpolation function used above is: String.prototype.interpolate = function (o) { return this.replace(/{([^{}]*)}/g, function (a, b) { var r = o[b]; return typeof r === 'string' || typeof r === 'number' ? r : a; } ); };

    Read the article

  • Getting Database Data to the client side.

    - by Toby Allen
    I'm sure this has been asked a million times, but what is the accepted approach to this? I have been writing php code for a while and up until recently I only copied+pasted javascript code, but now with help from YUI I've begun to understand javascript and want to use it more in an existing web app I have. I want to get various amounts of data from databases etc to the clientside javascript. I have access to this data in my php pages when loading. What is the correct way to get this data to my client side script. Generate clientside javascript in my php or smarty template files inserting the data where I need it? Use an Ajax call to retrieve the information I need from a php file - returning JSON data? Generate a JSON data construct of the data needed by the page and either return it via a script inclusion or dumping it to the generated page? Something really obvious I haven't thought of.

    Read the article

  • PHP: How to forward on $_FILES using cURL

    - by Toby
    Hi. I'm trying to use cURL to forward on a http request from a form in a web application I'm developing. Essentially I need to submit the same form twice on different servers, for the second server I'm adding some security measures to the post data. I can receive $_POST information on the second form perfectly fine, however I'm having major troubles with my $_FILES - I've tried separating the two so there's a separate request for post and files data but still no luck. Is this possible?

    Read the article

  • Data format for content heavy iPhone app - Plist or XML?

    - by Toby
    Hello, I'm building an iPhone app that is essentially a book, it will be bundled with a lot of text-heavy content. I considered bundling the data as XML and load it when the application starts but the XML would contain a lot of nested structures and be a bit of a pain to parse. Would it be better to use a plist? I'm concerned about memory usage and plists are loaded entirely into memory - can they be parsed in chunks? Is there a maximum size to a plist and how efficient are they? I'm not sure how big the bundled content is going to be yet but I should imagine it could be anywhere from 500k to 4MB. Thanks in advance.

    Read the article

  • A tool for finding duplicate code in PHP

    - by Toby
    Are there any tools available that can scan multiple .php files and report back duplicated lines/chunks of code? It doesn't have to be really smart but basically give me a starting point for manual scans to improve the codebase of some of my apps.

    Read the article

  • Magento: Add (and retrieve) custom database field for CMS pages

    - by Toby H
    I want to assign custom parameters to CMS pages in Magento (i.e. 'about', 'customer service', etc), so they can be grouped. The end goal is to use the parameters for each page to show (or hide) them in a nav menu. Writing a quick method in the page/html block to retrieve the pages (active only) for the menu was easy, but I can't figure out how to group them so that 'testimonials', 'history', and 'contact' are associated with 'about', and 'return policy', 'shipping', and 'contact' are associated with 'customer service'. Any help to point me in the right direction would be greatly appreciated. Thanks!

    Read the article

  • Recreating http request with cURL incl. files

    - by Toby
    I consistently get the error 'failed creating formpost data' from the below code, the same thing works perfectly on my local testing server, but on my shared host it throws the error. The sample part is just to simulate building the array with both files and non-file data. Essentially all I'm trying to do here is redirect the same http request to another server, but I'm running into so many troubles. $count=count($_FILES['photographs']['tmp_name']); $file_posts=array('samplesample' => 'ladeda'); for($i=0;$i<$count;$i++) { if(!empty($_FILES['photographs']['name'][$i])) { $fn = genRandomString(); $file_posts[$fn] = "@".$_FILES['photographs']['tmp_name'][$i]; } } $ch = curl_init(); curl_setopt($ch,CURLOPT_URL,"http://myurl/wp-content/plugins/autol/rec.php"); curl_setopt($ch,CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"); curl_setopt($ch,CURLOPT_HEADER,TRUE); curl_setopt($ch,CURLOPT_POST,TRUE); curl_setopt($ch,CURLOPT_POSTFIELDS,$file_posts); curl_exec($ch); print curl_error($ch); curl_close($ch);

    Read the article

  • Preserve name of file using cURL to transfer files

    - by Toby
    I'm transferring files from an existing http request using cURL like so... $postargs = array( 'nonfilefield' =>'nonfilevalue', 'fileentry' => '@'.$_FILES['thefile']['tmp_name'][0] ); $ch = curl_init('http://localhost/curl/rec.php'); curl_setopt($ch,CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"); curl_setopt($ch,CURLOPT_RETURNTRANSFER, true); curl_setopt($ch,CURLOPT_POST,TRUE); curl_setopt($ch,CURLOPT_POSTFIELDS,$postargs); curl_exec($ch); curl_close($ch); The only way I can get this to work is using the tmp_name, without this it won't send. However, I then lose the name value for when I want to name the file later. Is there some way to do this preserving the $_FILES array as it normally would be without curl? I'm also using an array of file fields in my script, so at the moment I have to convert my multidimensional array into a single dimension for this to work

    Read the article

  • How to convert the amount of indentation in a source code file?

    - by toby
    I find that I now often work with code bases that have different amounts of indentation. Some use 2 spaces, some use 4 space, some even use tabs! Once in a while, I have to share code between these codebases, or, sometimes I use an incorrect amount of indentation by mistake. Is there a tool or a text editor feature that will convert between different amounts of indentation?

    Read the article

  • PHP - Patterns within Arrays

    - by Toby
    I am trying to create a function which maps a recurring pattern of integers using an array. As an example if I have a starting array of (0,1,3) and I know that I want to stop the pattern when I hit 15. The pattern gets incremented by a fixed integer each time (lets say 4) so my final pattern should be.. 0 1 3 4 (0 + 4) 5 (1 + 4) 7 (2 + 4) 8 (4 + 4) 9 (5 + 4) 11(7 + 4) 12(8 + 4) 13(9 + 4) 15(11+ 4) Does anyone have any pointers on how this can be achieved? My current implementation works but is stupidly inefficient which something like this... $array = array(0,1,3); $inc = 4; $end = end($array); $final = 15; while($end < $final) { $tmp = array(); foreach($array AS $row) { $tmp = $row + $inc; } $array = merge($tmp, $array); $end = end($array); }

    Read the article

  • array multiplication task

    - by toby
    I am tying to get around how you will multiply the values in 2 arrays (as an input) to get an output. The problem I have is the how to increment the loops to achieve the task shown below #include <iostream> using namespace std; main () { int* filter1, *signal,fsize1=0,fsize2=0,i=0; cout<<" enter size of filter and signal"<<endl; cin>> fsize1 >> fsize2; filter1= new int [fsize1]; signal= new int [fsize2]; cout<<" enter filter values"<<endl; for (i=0;i<fsize1;i++) cin>>filter1[i]; cout<<" enter signal values"<<endl; for (i=0;i<fsize2;i++) cin>>signal[i]; /* the two arrays should be filled by users but use the arrays below for test int array1[6]={2,4,6,7,8,9}; int array2[3]={1,2,3}; The output array should be array3[9]={1*2,(1*4+2*2),(1*6+2*4+3*2),........,(1*9+2*8+3*7),(2*9+3*8),3*9} */ return 0; } This is part of a bigger task concerning filter of a sampled signal but it is this multiplication that i cant get done.

    Read the article

  • change USB vendor id / product id

    - by Hugh Allen
    Under Windows, is there any easy way to change or forge the vendor and product id of a USB device? Say for example there's a useful program which expects a particular (but ubiquitous and generic) device but you think it will probably work with the device that you actually have. I've done lots of Googling and apparently you can do it under Linux so it occurs to me to run Windows in a VM under Linux, but that would be a bit inconvenient.

    Read the article

  • Can't delete C:\Config.Msi\75ce84f.rbf

    - by Hugh Allen
    I can't delete C:\Config.Msi\75ce84f.rbf It's not causing any problems but it's a mystery I'd like to solve, preferably before the next reboot because it's scheduled for deletion then (see pendmoves). it's not readonly, system or hidden it's not in use by another process (according to Process Explorer) the NT security permissions aren't the problem either - I am the owner and have Full Control ; as a double-check, the Effective Permissions tab shows that I have permission to delete. Yet trying to delete the file gives "Access is Denied" from both Explorer and cmd. I can however rename it or move it to another folder on the same drive. I can also read it and Virustotal says it's clean which is what I would expect (it's just a Windows Installer temp file - a copy of some DLL I think). The relevant line from Process Monitor is: 6:52:14.3726983 PM 112 Explorer.EXE SetDispositionInformationFile C:\Config.Msi\75ce84f.rbf CANNOT DELETE Delete: True Write 1232 Background: I'm using XP SP2. I recently repaired my Adobe Reader installation to make it the default browser plugin again instead of Foxit. (there seems to be no UI to do it otherwise?) So the installer did its thing and then asked to reboot. As is my habit when rebooting is inconvenient I declined the offer and ran pendmoves to find out what files the installer had scheduled to move / delete. It wanted to delete two files with .rbf extension (rollback files) located in C:\Config.msi\. (this applies to both even though I've been speaking about one). So I tried to delete them manually and couldn't. Does anyone have any ideas what could be preventing deletion? (and I don't think it's malware even though I'm not running AV at the moment)

    Read the article

  • Windows Web Server 2008 R2 Server Core local password complexity

    - by Dennis Allen
    How can I disable the local user account password complexity settings on Windows 2008 R2 "Server Core"? I am trying to migrate our windows 2003 web server to windows 2008 R2. I am trying to see if I can use the "Server Core" install, and it has been a very internet search intensive experience. What I can't find out how to do is to find out how to disable password complexity for local user accounts. While our user account generator currently creates nice strong passwords, there was a time when this was not the case and unfortunately forcing the users to change their password is not an option at this time. Any help greatly appreciated. Dennis

    Read the article

  • Migrating from DD-WRT to Tomato

    - by Collin Allen
    Is it possible to switch to the latest version of Tomato on a router that's already running DD-WRT? Using the default Linksys firmware on my WRT54GL v1.1, I had to upload a micro version of DD-WRT first. I imagine that, since I'm now running third-party firmware, I won't have to do that again to make the switch, but I thought I should check so as not to brick it. This router is taking a back seat to a new AirPort Extreme (for the 'n' capability), but I still want to have the soon-to-be-Tomato device sit between the AirPort Extreme and my modem for the superior traffic graphing.

    Read the article

  • How do I install an HP home-use printer on Windows Home Server (Windows Server 2003)

    - by Rob Allen
    I have an HP DeskJet F4210 printer that I would like to share on my network via Windows Home Server. Unfortunately, the driver installation checks for supported OS's, detects Home Server as Windows Server 2003 and exits. The driver install supports WinXP, W2k, Vista, and Win98SE. In theory, drivers for XP or Windows 2000 should work fine with Home Server. When using the "Install Printer" tool in Home Server I am only able to select .inf files (there are serveral on the install media) but the driver folders for XP and 2000 have .sys and .dll files. How can I bypass HP's short-sighted install program and get this printer up and running on Home server? I'll be happy with basic print functionality and will save the task of enabling scanning for another time.

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >