Search Results

Search found 378 results on 16 pages for 'gordon carpenter thompson'.

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

  • How To Call Javascript In Ajax Response? IE: Close a form div upon success...

    - by B.Gordon
    I have a form that when you submit it, it sends the data for validation to another php script via ajax. Validation errors are echo'd back in a div in my form. A success message also is returned if validation passes. The problem is that the form is still displayed after submit and successful validation. I want to hid the div after success. So, I wrote this simple CSS method which works fine when called from the page the form is displayed on. The problem is that I cannot seem to call the hide script via returned code. I can return html like echo "<p>Thanks, your form passed validation and is being sent</p>"; So I assumed I could simply echo another line after that echo "window.onload=displayDiv()"; inside script tags (which I cannot get to display here)... and that it would hide the form div. It does not work. I am assuming that the problem is that the javascript is being returned incorrectly and not being interpreted by the browser... How can I invoke my 'hide' script on the page via returned data from my validation script? I can echo back text but the script call is ineffective. Thanks! This is the script on the page with the form... I can call it to show/hide with something like onclick="displayDiv()" while on the form but I don't want the user to invoke this... it has be called as the result of a successful validation when I write the results back to the div... function displayDiv() { var divstyle = new String(); divstyle = document.getElementById("myForm").style.display; if(divstyle.toLowerCase()=="block" || divstyle == "") { document.getElementById("myForm").style.display = "none"; } else { document.getElementById("myForm").style.display = "block"; } } PS: I am using the mootools.js library for the form validation if this matters for the syntax..

    Read the article

  • javan-whenever not writing crontab with Capistrano deploy

    - by Gordon Isnor
    I’ve been trying to get whenever running on an ec2 instance that was created with ec2 on rails. When I deploy with Capistrano it indicates that the crontab was written, but when I log into the server and run crontab -l it does not seem to have been changed. If I go into the release folder and manually run whenever --write-crontab then run crontab -l - it gets updated properly. Any ideas what could be causing this? Capistrano is not indicating any errors so not sure how to debug, have tried a billion permutations and combinations and nothing changes.

    Read the article

  • Android Graphics Memory Limits

    - by Gordon
    I am creating an android game using opengl and a cocos2d port (http://code.google.com/p/cocos2d-android-1). I am targeting a wide range of devices and want to ensure that it performs well. I only test on a nexus one and am hoping to get some input from people with experience on slower devices. Currently the game uses two 1024x1024 textures as well as two 256x256 textures. Is this within the limits of most devices? Anyone have any rule of thumb or experience with graphics memory limits in these cases? If gfx memory is exceeded does it page to normal memory?

    Read the article

  • Change Sequence to Choice

    - by Gordon
    In my Schema File I defined a Group with a Sequence of possible Elements. <group name="argumentGroup"> <sequence> <element name="foo" type="double" /> <element name="bar" type="string" /> <element name="baz" type="integer" /> </sequence> </group> I then reference this Group like this: <element name="arguments"> <complexType> <group ref="my:argumentGroup"/> </complexType> </element> Is it possible to reference the Group at some other point but restrict it so it's a Choice instead of a Sequence. The position where I want to reuse it would only allow one of the Elements within. <element name="argument" minOccurs="0" maxOccurs="1"> <complexType> <group name="my:argumentGroup"> <! -- Somehow change argumentGroup sequence to choice here --> </group> <complexType> </element>

    Read the article

  • MVC 3 Nested EditorFor Templates

    - by Gordon Hickley
    I am working with MVC 3, Razor views and EditorFor templates. I have three simple nested models:- public class BillingMatrixViewModel { public ICollection<BillingRateRowViewModel> BillingRateRows { get; set; } public BillingMatrixViewModel() { BillingRateRows = new Collection<BillingRateRowViewModel>(); } } public class BillingRateRowViewModel { public ICollection<BillingRate> BillingRates { get; set; } public BillingRateRowViewModel() { BillingRates = new Collection<BillingRate>(); } } public class BillingRate { public int Id { get; set; } public int Rate { get; set; } } The BillingMatrixViewModel has a view:- @using System.Collections @using WIP_Data_Migration.Models.ViewModels @model WIP_Data_Migration.Models.ViewModels.BillingMatrixViewModel <table class="matrix" id="matrix"> <tbody> <tr> @Html.EditorFor(model => Model.BillingRateRows, "BillingRateRow") </tr> </tbody> </table> The BillingRateRow has an Editor Template called BillingRateRow:- @using System.Collections @model IEnumerable<WIP_Data_Migration.Models.ViewModels.BillingRateRowViewModel> @foreach (var item in Model) { <tr> <td> @item.BillingRates.First().LabourClass.Name </td> @Html.EditorFor(m => item.BillingRates) </tr> } The BillingRate has an Editor Template:- @model WIP_Data_Migration.Models.BillingRate <td> @Html.TextBoxFor(model => model.Rate, new {style = "width: 20px"}) </td> The markup produced for each input is:- <input name="BillingMatrix.BillingRateRows.item.BillingRates[0].Rate" id="BillingMatrix_BillingRateRows_item_BillingRates_0__Rate" style="width: 20px;" type="text" value="0"/> Notice the name and ID attributes the BillingRate indexes are handled nicely but the BillingRateRows has no index instead '.item.'. From my reasearch this is because the context has been pulled out due to the foreach loop, the loop shouldn't be necessary. I want to achieve:- <input name="BillingMatrix.BillingRateRows[0].BillingRates[0].Rate" id="BillingMatrix_BillingRateRows_0_BillingRates_0__Rate" style="width: 20px;" type="text" value="0"/> If I change the BillingRateRow View to:- @model WIP_Data_Migration.Models.ViewModels.BillingRateRowViewModel <tr> @Html.EditorFor(m => Model.BillingRates) </tr> It will throw an InvalidOperationException, 'model item passed into the dictionary is of type System.Collections.ObjectModel.Collection [BillingRateRowViewModel] but this dictionary required a type of BillingRateRowViewModel. Can anyone shed any light on this?

    Read the article

  • Usage of setInfoClass() on DirectoryIterator vs on RecursiveDirectoryIterator

    - by Gordon
    I've ran into an inconsistent behavior when using setInfoClass to set a custom SplFileInfo class to a DirectoryIterator versus setting it to a RecursiveIterator. The method description states: Use this method to set a custom class which will be used when getFileInfo and getPathInfo are called. The class name passed to this method must be derived from SplFileInfo. Consider this custom SplFileInfo class A extends SplFileInfo { public function test() { printf("I am of class %s\n", __CLASS__); } } and my iterators $iterator = new DirectoryIterator('.'); and $iterator = new RecursiveDirectoryIterator('.'); Now I'd expect those two to behave the same when I do $iterator->setInfoClass('A'); foreach($iterator as $file) { $file->test(); } and output 'I am of A' for each $file encountered and in fact, the RecursiveDirectoryIterator will do that. But the DirectoryIterator will raise Fatal error: Call to undefined method DirectoryIterator::test() so apparently the InfoClass does not get applied when iterating over the files. At least not directly, because when I change the code in the foreach loop to $file->getPathInfo()->test(); it will work for the DirectoryIterator. But then the RecursiveDirectoryIterator will raise Fatal error: Call to undefined method SplFileInfo::test() Like I said, I'd expect those two to behave the same, but apparently getFileInfo and getPathInfo don't get called in the DirectoryIterator, which I consider a bug. So if there is any Iterator experts out there, please help me understand this. Thanks.

    Read the article

  • Can I force MySQL to output results before query is completed?

    - by Gordon Royle
    I have a large MySQL table (about 750 million rows) and I just want to extract a couple of columns. SELECT id, delid FROM tbl_name; No joins or selection criteria or anything. There is an index on both fields (separately). In principle, it could just start reading the table and spitting out the values immediately, but in practice the whole system just chews up memory and basically grinds to a halt. It seems like the entire query is being executed and the output stored somewhere before ANY output is produced... I've searched on unbuffering, turning off caches etc, but just cannot find the answer. (mysqldump is almost what I want except it dumps the whole table - but at least it just starts producing output immediately)

    Read the article

  • Prevent Erroneous Property Assignment

    - by Gordon
    Porting android applications to iphone applications always gives me the following pattern that I accidentally create: - (void) myFunc:(id)prop { self.property = property; } Which instead should be: - (void) myFunc:(id)prop { self.property = prop; } This always causes my program to quietly break because property gets reset to its existing value rather than being set to the new value, 'prop'. I cannot name the parameter 'prop' to 'property' since the compile complains that the parameter masks the instance variables visibility. Is there a good way to avoid this situation? There are no compiler warnings. Is there a way to make xcode prevent this? I cannot see very many situations where you would set a property to the value of its underlying instance variable (maybe to trigger a KVO binding?), but I don't see myself doing that in majority of cases. I understand the above code is synthetic and should be done with @synthesize, but I am just using it as a simplified example to illustrate my point.

    Read the article

  • Query decendants in XML to Linq

    - by Gordon
    I have the following xml data: <portfolio> <item> <title>Site</title> <description>Site.com is a </description> <url>http://www.site.com</url> <photos> <photo url="http://www.site.com/site/thumbnail.png" thumbnail="true" description="Main" /> <photo url="http://www.site.com/site/1.png" thumbnail="false" description="Main" /> </photos> </item> </portfolio> In c# I am using the following link query: List list = new List(); XDocument xmlDoc = XDocument.Load(HttpContext.Current.Server.MapPath("~/app_data/portfolio.xml")); list = (from portfolio in xmlDoc.Descendants("item") select new PortfolioItem() { Title = portfolio.Element("title").Value, Description = portfolio.Element("description").Value, Url = portfolio.Element("url").Value }).ToList(); How do I go about querying the photos node? In the PortfolioItem class I have a property: List Photos {get;set;} Any ideas would be greatly appreciated!

    Read the article

  • Any way to assign terminal output to variable with python?

    - by Gordon Fontenot
    I need to grab the duration of a video file via python as part of a larger script. I know I can use ffmpeg to grab the duration, but I need to be able to save that output as a variable back in python. I thought this would work, but it's giving me a value of 0: cmd = 'ffmpeg -i %s 2>&1 | grep "Duration" | cut -d \' \' -f 4 | sed s/,//' % ("Video.mov") duration = os.system(cmd) print duration Am I doing the output redirect wrong? Or is there simply no way to pipe the terminal output back into python?

    Read the article

  • Is there a way to pass a regex capture to a block in Ruby?

    - by Gordon Fontenot
    I have a hash with a regex for the key and a block for the value. Something like the following: { 'test (.+?)' => { puts $1 } } Not exactly like that, obviously, since the block is being stored as a Proc, but that's the idea. I then have a regex match later on that looks a lot like this hash.each do |pattern, action| if /#{pattern}/i.match(string) action.call end end The idea was to store the block away in the hash to make it a bit easier for me to expand upon in the future, but now the regex capture doesn't get passed to the block. Is there a way to do this cleanly that would support any number of captures I put in the regex (as in, some regex patterns may have 1 capture, others may have 3)?

    Read the article

  • jQuery UI Tabs Plugin Broke

    - by Warren J Thompson
    We are using the jquery ui tabs arrow plugin from this fiddle: http://jsfiddle.net/dECtZ/282/, but like many plugins, it breaks with the latest version of jQuery. We were able to get the csscur to work, but still get the following error in the jquery core (line 353): Uncaught TypeError: Cannot assign to read only property 'length' of function (e,t){if(!this._createWidget)return new o(e,t);arguments.length&&this._createWidget(e,t)} Code is as follows: (function($, undefined) { if (!$.xui) { $.xui = {}; } var tabs = $.extend({}, $.ui.tabs.prototype), _super = { _create: tabs._create, _destroy: tabs._destroy, _update: tabs._update }; $.xui.tabs = $.extend(tabs, { options: $.extend({}, tabs.options, { scrollable: false, changeOnScroll: false, closable: false, resizable: false, resizeHandles: "e,s,se" }), _create: function() { var self = this, o = self.options; _super._create.apply(self); if (o.scrollable) { self.element.addClass("ui-tabs-scrollable"); var scrollContainer = $('<div class="ui-tabs-scroll-container"></div>').prependTo(this.element); self.header = $('<div class="ui-tabs-nav-scrollable ui-widget-header ui-corner-all"></div>').prependTo(scrollContainer); var nav = self.element.find(".ui-tabs-nav:first").removeClass("ui-widget-header ui-corner-all").appendTo(this.header); var arrowsNav = $('<ol class="ui-helper-reset ui-helper-clearfix ui-tabs-nav-arrows"></ol>').prependTo(self.element); var navPrev = $('<li class="ui-tabs-arrow-previous ui-state-default ui-corner-bl ui-corner-tl" title="Previous"><a href="#"><span class="ui-icon ui-icon-carat-1-w">Previous tab</span></a></li>').prependTo(arrowsNav).hide(), navNext = $('<li class="ui-tabs-arrow-next ui-state-default ui-corner-tr ui-corner-br" title="Next"><a href="#"><span class="ui-icon ui-icon-carat-1-e">Next tab</span></a></li>').appendTo(arrowsNav).hide(); var scrollTo = function(to, delay) { var navWidth = 0, arrowWidth = navPrev.outerWidth(), marginLeft = -(parseInt(nav.css("marginLeft"), 10)), hwidth = self.header.width(), newMargin = 0; nav.find("li").each(function() { navWidth += $(this).outerWidth(true); }); if (to instanceof $.Event) { } else { newMargin = marginLeft+to; if (newMargin > (navWidth-hwidth)) { newMargin = (navWidth-hwidth); } else if (newMargin < 0) { newMargin = 0; } nav.stop(true).animate({ marginLeft: -(newMargin) }, delay, function(){ $(window).trigger("resize.tabs"); }); } } var holdTimer = false; navPrev.add(navNext).bind({ "click": function(e) { var isNext = this === navNext[0]; e.preventDefault(); if (o.changeOnScroll) { self.select(self.options.selected + (isNext ? 1 : -1)); } else { if (!holdTimer) scrollTo(isNext ? 150 : -150, 250); } }, "mousedown": function(e){ if (!o.changeOnScroll) { var isNext = this === navNext[0], duration = 10, pos = 15, timer; if (holdTimer) clearTimeout(holdTimer); holdTimer = setTimeout(timer = function(){ scrollTo(isNext ? pos : -(pos), duration); holdTimer = setTimeout(arguments.callee, duration); }, 150); } }, "mouseup mouseout": function(e){ if (!o.changeOnScroll) { clearTimeout(holdTimer); holdTimer = false; nav.stop(); } } }); self.header.bind('mousewheel', function(e, d, dX, dY) { e.preventDefault(); if (d === -1) { navNext.click(); } else if (d === 1) { navPrev.click(); } }); $(window).bind("resize.tabs", function(e) { var navWidth = 0; var arrowWidth = navPrev.outerWidth(); nav.find("li").each(function() { navWidth += $(this).outerWidth(true); }); var marginLeft = -(parseInt(nav.css("marginLeft"), 10)), hwidth = self.header.width(); if (navWidth > (hwidth+marginLeft)) { self.header.addClass("ui-tabs-arrow-r"); navNext.show("fade"); if (marginLeft > 0) { self.header.addClass("ui-tabs-arrow-l"); navPrev.show("fade"); } else { self.header.removeClass("ui-tabs-arrow-l"); navPrev.hide("fade"); } } else { self.header.removeClass("ui-tabs-arrows ui-tabs-arrow-l"); navNext.hide("fade"); if (marginLeft > 0) { self.header.addClass("ui-tabs-arrow-l"); navPrev.show("fade"); } else { self.header.removeClass("ui-tabs-arrow-l"); navPrev.hide("fade"); } } }).trigger("resize.tabs"); arrowsNav.find("li").bind({ "mouseenter focus": function(e) { $(this).addClass("ui-state-hover"); }, "mouseleave blur": function(e) { $(this).removeClass("ui-state-hover"); } }); this.anchors.bind("click.tabs", function(){ var li = $(this).parent(), arrowWidth = navPrev.outerWidth(), width = li.outerWidth(true), hwidth = self.header.width(), pos = li.position().left, marginLeft = -(parseInt(nav.stop(true,true).css("marginLeft"),10)), newMargin = -1; if (li.index() === 0) { newMargin = 0; } else if ((pos+width) >= (hwidth+marginLeft)) { newMargin = pos-hwidth+width; if ((li.index()+1) < nav.find("li").length) { newMargin += arrowWidth; } } else if (pos < marginLeft) { newMargin = pos-arrowWidth; } if (newMargin > -1) { nav.animate({ marginLeft: -(newMargin) }, 250, function(){ $(window).trigger("resize.tabs"); }); } }); } return self; }, _update: function(){ console.log(arguments); _super._update.apply(this); } }); $.widget("xui.tabs", $.xui.tabs); })(jQuery); $(function() { $("#tabs").tabs({ scrollable: true, changeOnScroll: false, closable: true }); $("#switcher").themeswitcher(); });

    Read the article

  • jQuery in sharepoint retruning Object Expected

    - by Simon Thompson
    When I add jquery to sharepoint 2007 (MOSS) and try and use it on a page no matter what I write on the client i get an "object expected" at the line/column where the "$" appears. I have used fiddler to check that the client is downloading the query JS (which it is) But its like its being ignore and therefor eth "$" is not understood. Searching google everybody is saying its the selector not finding the elements but see code below I do not see how it can not find my very simple example. In master page in header <script type="text/javascript" src="jquery.min.js"></script> version 1.4.2 On a page <a href="javascript:abc();">Testing</a> <script> function abc(){ $("#simon").css("border","3px solid red"); } </script> <div id="simon">

    Read the article

  • Are PackageMaker installations with preinstall scripts broken on Snow Leopard?

    - by Stu Thompson
    Everything worked on 10.5, but now my PackageMaker installation project is broken. I've been fighting a problem for a few days now, and either Snow Leopard (OS X 10.6.1) has broken PackageMaker installations I am lacking a very, very basic tidbit of knowledge To narrow down the problem, I've gotten to this point: Create a new PackageMaker installation Have it install a jpeg image into my home directoy Define a preinstall script that does nothing #/bin/sh exit 0 Run the above...and watch it fail with the below error message like clock work Sep 14 15:09:45 manoa installd[5620]: PackageKit: ----- Begin install ----- Sep 14 15:09:45 manoa installd[5620]: PackageKit: request=PKInstallRequest <1 packages, destination=/> Sep 14 15:09:45 manoa installd[5620]: PackageKit: packages=(\n "PKLeopardPackage <file://localhost/Users/stu/Desktop/asdf.pkg>"\n) Sep 14 15:09:46 manoa installd[5620]: PackageKit: Extracting /Users/stu/Desktop/asdf.pkg (destination=/var/folders/Hb/HbXJFyEpFaupt5QyLN-pTk+++TI/-Tmp-/PKInstallSandbox-tmp/Root/~, uid=501) Sep 14 15:09:46 manoa installd[5620]: PackageKit: Executing script "./preinstall" in /private/tmp/PKInstallSandbox.cmlS2H/Scripts/test.test.5year_header.pkg.PFrHNB Sep 14 15:09:46 manoa installd[5620]: PackageKit: *** launch path not accessible Sep 14 15:09:46 manoa installd[5620]: PackageKit: Install Failed: PKG: pre-install scripts for "test.test.5year_header.pkg"\nError Domain=PKInstallErrorDomain Code=112 UserInfo=0x100149430 "An error occurred while running scripts from the package “asdf”." {\n NSFilePath = "./preinstall";\n NSLocalizedDescription = "An error occurred while running scripts from the package \U201casdf\U201d.";\n NSURL = "file://localhost/Users/stu/Desktop/asdf.pkg";\n PKInstallPackageIdentifier = "test.test.5year_header.pkg";\n} Sep 14 15:09:46 manoa Installer[5614]: install:didFailWithError:Error Domain=PKInstallErrorDomain Code=112 UserInfo=0x1195917c0 "An error occurred while running scripts from the package “asdf”." Sep 14 15:09:46 manoa Installer[5614]: Install failed: The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance. Sep 14 15:09:47 manoa Installer[5614]: IFDInstallController 144040 state = 7 Sep 14 15:09:47 manoa Installer[5614]: Displaying 'Install Failed' UI. Sep 14 15:09:47 manoa Installer[5614]: 'Install Failed' UI displayed message:'The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.'. There is no file in /private/tmp/PKInstallSandbox.cmlS2H/Scripts/test.test.5year_header.pkg.PFrHNB/, which makes me think the problem is with PackageMaker, and not me. But I'm new to the world of OS X software installation, so doubts remain. So, the question: Is PackageMaker with a preinstall script broken on OS X 10.6? Or is there some requirement regarding preinstall scripts that I do not understand?

    Read the article

  • iPhone UIControl and Subview

    - by Jack Thompson
    I currently have a UIControl, which has a number of subviews (image, label). Unfortunately when I use addTarget etc. It doesn't detect touches on the subviews. [myCustomView addTarget:self action:@selector(touchedView:) forControlEvents:UIControlEventTouchUpInside]; Is it possible for the UIControl to detect touches on subviews or should i be approaching it differently.

    Read the article

  • Ideas for networking project

    - by Chris Thompson
    Hi all, I'm a graduating senior in computer science taking a computer networks class and I'm trying to figure out my final project. I normally am not at a loss for ideas but be it senioritis or straight burn out, I've got nothing. I've done some fun stuff in the past, but I just can't seem to come up with a good idea. Given the mass of brilliance on this site, I figured it would be a good place to request some suggestions. To give you an idea of scope, it's due in about a month and I would consider myself proficient with mobile architectures like Android (although I have no iPhone experience) along with Java, C++, etc. If you can suggest an idea, I'd be happy to make it work in whatever language I know. Like I said, I'm a senior and will be graduating so I'd rather not take on something that would kill me... Also, I'd be happy to make it open source if it's an idea you'd always wanted to work on but didn't have the time to start. Thanks in advance for the help! Chris Edit 1: Thanks so much for the suggestions everyone! Unfortunately I've actually already written a chat client (for a network security class) and I think I'd run into some honor code issues if I did that again, although that's always a great option. I like the game idea and that's actually something I've never attempted before (in any capacity) although given that, I'm a little scared about time...

    Read the article

  • Will html5 change everything for designers?

    - by Sean Thompson
    What impact do you think html5 will have on the workflow/way graphic design is done for the web? Right now most designers stay in an Adobe tool, doing most of the design work there, and implement some elements with graphics and some with code. Checking out http://www.apple.com/html5/ it seems that almost everything done in a graphic can be done in code. Will designers have to learn very advanced levels of html5 and do the actual design work in the browser or do you see a more "designer friendly" gui being made for html/graphics work? Will tools like photoshop evolve in a way that handles this new lack of image files?

    Read the article

  • MooseX::Types declaration issue, tight test case :)

    - by TJ Thompson
    So after an embarrassing amount of time debugging, I've finally stripped this issue ([http://stackoverflow.com/questions/4621589/perl-moose-typedecorator-error-how-do-i-debug][1]) down to a simple test case. I would humbly request some help understanding why it's failing :) Here is the error message I'm getting: plxc16479 $h2/tmp/tmp18.pl This method [new] requires a single argument. at /nfs/pdx/disks/nehalem.pde.077/perl/5.12.2/lib64/site_perl/MooseX/Types/TypeDecorator.pm line 91 MooseX::Types::TypeDecorator::new('MooseX::Types::TypeDecorator=HASH(0x655b90)') called at /nfs/pdx/disks/nehalem.pde.077/projects/lib/Program-Plist-Pl/lib/Program/Plist/Pl.pm line 10 Program::Plist::Pl::BUILD('Program::Plist::Pl=HASH(0x63d478)', 'HASH(0x63d220)') called at generated method (unknown origin) line 29 Program::Plist::Pl::new('Program::Plist::Pl') called at /nfs/pdx/disks/nehalem.pde.077/tmp/tmp18.pl line 10 Wrapper test script: use strict; use warnings; BEGIN {push(@INC, split(':', $ENV{PERL_TEST_LIBS}))}; use Program::Plist::Pl; my $obj = Program::Plist::Pl->new(); Program::Plist::Pl file: package Program::Plist::Pl; use Moose; use namespace::autoclean; use Program::Types qw(Pattern); # <-- Removing this fixes error use Program::Plist::Pl::Pattern; sub BUILD { my $pattern_obj = Program::Plist::Pl::Pattern->new(); } __PACKAGE__->meta->make_immutable; 1; Program::Types file: package Program::Types; use MooseX::Types -declare => [qw(Pattern)]; class_type Pattern, {class => 'Program::Plist::Pl::Pattern'}; 1; And the Program::Plist::Pl::Pattern file: package Program::Plist::Pl::Pattern; use Moose; use namespace::autoclean; __PACKAGE__->meta->make_immutable; 1; Notes: While I don't need the Pattern type from Program::Types in the above code, I do in other code that is stripped out. The PERL_TEST_LIBS env var I'm pulling INC paths from only contains paths to the project modules. There are no other modules loaded from these paths. It appears the MooseX::Types definition for Pattern is causing problems, but I'm not sure why. Documentation shows the syntax I am using, but it's possible I'm misusing class_type as there isn't much said about it. Intent is to be able to use Pattern for type checking via MooseX::Params::Validate to verify the argument is a 'Program::Plist::Pl::Program' object. I've found that removing the intervening class Program::Plist::Pl from the equation by directly calling Pattern-new from the tmp18.pl wrapper results in no error, even when the Program::Types Pattern type is imported.

    Read the article

  • Group by and order by

    - by Simon Thompson
    using LINQ to NHibernate does anybody know how to use group by and order by in the same expression. I am having to execute the group by into a list and then order this, seem that I am missing soemthing here ??? Example:- Private function LoadStats(...) ... Dim StatRepos As DataAccess.StatsExtraction_vwRepository = New DataAccess.StatsExtraction_vwRepository return (From x In StatRepos.GetAnswers(Question, Questionnaire) _ Group x By xData = x.Data Into Count() _ Select New ChartData With {.TheData = xData, .TheValue = xData.Count} ).ToList.OrderBy(Function(x) x.TheData) End Sub

    Read the article

  • Multiple comosite applications on same WSDL endpoint with OPEN-ESB

    - by Simon Thompson
    Just learning how Open-ESB (GlassFishESB) works and evaluating it for a project. One point I do not understand is that if I have a Composite application bound to an incoming web service (hosted on the glassfish server) can I get muple composite applications to consume this message ? If so is it done by A) simply deploying the multiple composite applications each referencing the save URL and same WSDL B) include each JBI module in the CASA editor and deploy a single composite application with all parts included (will this reduce scaling?) C) create a new composite application which has a BPEL process to send the in message to new endpoints for each compisite applciation . My feeling is that option A should work?

    Read the article

  • How to manipulate and print a chart in MS Excel from AppleScript?

    - by Stu Thompson
    With an existing chart in a MS Excel for Mac 2008, in AppleScript, I am trying to do two things: Rotate a 3D chart 1° Save the chart as a image (png) From what I've found on the Intertubes, it seems possible. But AppleScript's awkward verbosity and the lack of non-trivial MS Excel AppleScript examples on the web are too much for me to overcome. Just for the saving part, this is what I have so far: tell application "Microsoft Excel" activate object worksheet "iozone-16" set cht to chart object 1 of active sheet tell cht #save as chart object [picture type enumeration] [file name Unicode text] #Argh!!! end tell end tell The 'rotate 1°' task seems to involve "internal objects", but that is as far as I've gotten.

    Read the article

  • Is there any way to access files in your source tree in Android?

    - by Chris Thompson
    Hi all, This is a bit unorthodox but I'm trying to figure out if there's a way to access files stored in the src tree of my applications apk in Android. I'm trying to use i-Jetty (Jetty implementation for Android) and rather than use it as a separate application and manually download my war file, I'd rather just bake i-jetty in. However, in order to use (easily) standard html/jsp I need to be able to give it a document root, preferably within my application's apk file. I know Android specifically works to prevent you from accessing (freely) the stuff on the actual system so this may not be possible, but I'm thinking it might be possible to access something within the apk. One option to work around this would be to have all of the files stored in the res directory and then copy them to the sdcard on startup but this wouldn't allow me to automatically remove the files on uninstall. To give you an idea of what I've tried, currently, the html files are stored in org.webtext.android Context rootContext = new Context(server_, "/", Context.SESSIONS); rootContext.setResourceBase("org/webtext/webapp"); Returns a 404 error. final URL url = this.getClassLoader().getResource("org/webtext/webapp"); Context html = new WebAppContext(url.toExternalForm(), "/"); Blows up with a NullPointerException because no URL is returned from the getResource call. Any thoughts would be greatly appreciated! Thanks, Chris

    Read the article

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