Search Results

Search found 310 results on 13 pages for 'graham barnes'.

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

  • Empirical evidence for choice of programming paradigm to address a problem

    - by Graham Lee
    The C2 wiki has a discussion of Empirical Evidence for Object-Oriented Programming that basically concludes there is none beyond appeal to authority. This was last edited in 2008. Discussion here seems to bear this out: questions on whether OO is outdated, when functional programming is a bad choice and the advantages and disadvantages of AOP are all answered with contributors' opinions without reliance on evidence. Of course, opinions of established and reputed practitioners are welcome and valuable things to have, but they're more plausible when they're consistent with experimental data. Does this evidence exist? Is evidence-based software engineering a thing? Specifically, if I have a particular problem P that I want to solve by writing software, does there exist a body of knowledge, studies and research that would let me see how the outcome of solving problems like P has depended on the choice of programming paradigm? I know that which paradigm comes out as "the right answer" can depend on what metrics a particular study pays attention to, on what conditions the study holds constant or varies, and doubtless on other factors too. That doesn't affect my desire to find this information and critically appraise it. It becomes clear that some people think I'm looking for a "turn the crank" solution - some sausage machine into which I put information about my problem and out of which comes a word like "functional" or "structured". This is not my intention. What I'm looking for is research into how - with a lot of caveats and assumptions that I'm not going into here but good literature on the matter would - certain properties of software vary depending on the problem and the choice of paradigm. In other words: some people say "OO gives better flexibility" or "functional programs have fewer bugs" - (part of) what I'm asking for is the evidence of this. The rest is asking for evidence against this, or the assumptions under which these statements are true, or evidence showing that these considerations aren't important. There are plenty of opinions on why one paradigm is better than another; is there anything objective behind any of these?

    Read the article

  • Changing swappiness in sysctl.conf doesn't work for me

    - by Graham
    I'm using 12.04 LTS and can sudo sysctl to set swappiness to 10, but adding vm.swappiness=10 to sysctl.conf doesn't work for me - after I reboot, swappiness still reports 60 (default) I'd like to be able to reduce swaps to my SSD, but can't find a way to do so except manually per session. Modifying sysctl.conf seems to work for most - can anyone advise what I need to check / change to make it work for me too, please?

    Read the article

  • Need a PCIe desktop graphics card for dual-monitor

    - by Graham
    I have a mid-2008 workstation with two HD monitors supporting HDMI and DVI inputs. Since Ubuntu 11.10, I have experienced no end of trouble with my NVidia Quadro NVS 290 in TwinView dual-monitor output. Others have similar desktop TwinView woes. I want a new graphics card. Previously I asked for a graphics card recommendation and response was Nvidia Geforce GTS 450... but really I'm looking for someone who has actually got a working dual-monitor desktop to tell me what card they use so I can get something that is known to work. So please, people who have no-issues with their 64-bit Ubuntu 12.04 Unity 3D desktop spread across two HD-resolution external monitors (either DVI or HDMI connector), and who also run Google Chrome (which throws a spanner due to its own GPU compositing)... please let me know what graphics card you have so I can buy one. Gathering Options These seem to be the Nvidia cards featuring dual DVI. But they all seem to be gaming cards - what has dual-DVI, good support, but is not a massive gaming card? Nvidia GTS 450 (previously recommended) - 2x DVI Nvidia GTX 550 Ti (used by System76) - 2x DVI Nvidia GT 430 (used by System76) - 1xDVI, 1xHDMI Nvidia GT 640 (found on NVidia site) - 1xDVI, 1xHDMI (also GT 620, GT 630) Has anyone had a good desktop dual-monitor Unity 3D experience with ATI cards?

    Read the article

  • 3D Display Issue When Using Latest Java Runtime Versions - Patch now available...

    - by [email protected]
    Typically I focus my blog posts on Support process topics, and reserve most of the technical topics for the Support newsletter. This topic, however, warrants a quick mention in the blog since I know it's been affecting many users recently. For customers using the Client/Server Deployment of AutoVue, users that had upgraded their client Java Runtime Environment (JRE) to version 1.6.0_19 or later suddenly noticed that their 3D files were opening blank in AutoVue. This issue was due to a change in JRE version 1.6.0_19, and the AutoVue team now offers a patch to address the issue in AutoVue version 20.0.0. The patch number is 10268316, is available through the My Oracle Support portal, and is described further in KM Note 1104821.1. We'll mention it again in our next Support newsletter, and the AutoVue team will target to roll the same fix into the next available release of the product.

    Read the article

  • How do I boot Ubuntu Cloud images in vmware?

    - by Graham
    I want to run an Ubuntu cloud image on on VMWare. I've gotten pretty far but want to know how to set the OVF properties in a way that VMWare understands in order to pass parameters to cloud-init. This is what I've done: Install VMWare Player 4.0.4, using the vmware workstation 8.0.2 / player 4.0.2 fix for linux 3.2+ patch to get around the compilation failure for virtual ethernet module. Download precise-server-cloudimg-amd64.ovf, and also the QCOW2 .img file (220MB) Run qemu-img convert -O vmdk precise-server-cloudimg-amd64-disk1.img precise-server-cloudimg-amd64-disk1.vmdk to convert the image from QCOW2 to VMDK Edit the OVF to change the extension and ovf:size on the <File> element and set ovf:format="http://www.vmware.com/interfaces/specifications/vmdk.html#sparse" on the <Disk> element. Edit the OVF to remove all the <Property> elements because vmplayer was complaining about unrecognised elements. Run the OVF in vmplayer. Alternatively, run ovftool to convert to vmx and run the vmx. Unfortunately I can't log in as "ubuntu" at the prompt because the OVF properties haven't been provided to cloud-init. How should I do this?

    Read the article

  • AutoVue 20.2 for Agile Released

    - by Angus Graham
    Normal 0 false false false EN-CA X-NONE X-NONE MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Calibri","sans-serif";} Oracle’s AutoVue 20.2 for Agile PLM is now available on Oracle’s Software Delivery Cloud. This latest release allows Agile PLM customers to take advantage of new AutoVue 20.2 features in the following Agile PLM environments: 9.3.1.x; 9.3.0.  AutoVue 20.2 delivers improvements in the following areas. New Format Support: AutoVue 20.2 adds support for the latest versions of popular file formats including: ECAD: Cadence Concept HDL 16.5, Allegro Layout 16.5, Orcad Capture 16.5, Board Station ASCII Symbol Geometry, Cadence Cell Library MCAD: CATIA V5 R21, PTC Creo Parametric 1.0, Creo Element\Direct Modeling 17.10, 17.20, 17.25, 17.30, 18.00, SolidWorks 2012, SolidEdge ST3 & ST4, PLM XML 2D CAD: Creo Element/Direct Drafting 17.10 to 18.00 Office: MS Office 2010: Word, Excel, PowerPoint, Outlook Enhancements to AutoVue enterprise readiness: reliability and performance improvements, as well as security enhancements which adhere to Oracle’s Software Security Assurance standards Updated version of AutoVue Document Print Service offerings, which include the ability to select CAD layers for printing  For further details, check out the What’s New in AutoVue 20.2 datasheet

    Read the article

  • What one feature available in other IDEs should be added to Xcode? [closed]

    - by Graham Lee
    This is inspired by Which features from other IDEs/editors you wish you have in Visual Studio? Xcode is a very different tool from Visual Studio, with a different feature set. While some of its capabilities are very mature (it had RAD UI layout in Interface Builder since before most other platforms), it lacks some features that e.g. Visual Studio or Eclipse provide. If you could request one feature to be added to Xcode, which would it be? How would that feature help you write better code, or write the same code faster?

    Read the article

  • AutoVue 20.2.1 for Agile Released

    - by Angus Graham
    Oracle's AutoVue 20.2.1 for Agile PLM is now available on Oracle's Software Delivery Cloud.  This latest release allows Agile PLM customers to take advantage of new AutoVue 20.2.1 features in the following Agile PLM environments:  9.3.x, 9.2.2.x, 9.2.1.x. AutoVue 20.2.1 delivers improvements in the following areas: New Format Support: AutoVue 20.2 adds support for the latest versions of popular file formats including: 2D CAD: AutoCAD 2013 MCAD: Inventor 2013, AutoCAD Mechanical 2013, Unigraphics NX8, JT 9.2 through 9.5, CATIA v5-6 R2012, Creo Parametric 2.0 ECAD: Altium Designer New Platform Support:  Client and server support has been extended to the following platforms: Java 7 JVM Google Chrome Browser Oracle VM 2 virtualization environment Installer Improvements: Ensures ports used by AutoVue are not in use - if they are, the admin will be prompted to select alternate ports. Click here to access the latest AutoVue Format Support Sheet.

    Read the article

  • Context is Everything

    - by Angus Graham
    Normal 0 false false false EN-CA X-NONE X-NONE MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin-top:0cm; mso-para-margin-right:0cm; mso-para-margin-bottom:10.0pt; mso-para-margin-left:0cm; line-height:115%; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin;} Context is Everything How many times have you have you asked a question only to hear an answer like “Well, it depends. What exactly are you trying to do?”.  There are times that raw information can’t tell us what we need to know without putting it in a larger context. Let's take a real world example.  If I'm a maintenance planner trying to figure out which assets should be replaced during my next maintenance window, I'm going to go to my Asset Management System.  I can get it to spit out a list of assets that have failed several times over the last year.  But what are these assets connected to?  Is there any safety consequences to shutting off this pipeline to do the work?  Is some other work that's planned going to conflict with replacing this asset?  Several of these questions can't be answered by simply spitting out a list of asset IDs.  The maintenance planner will have to reference a diagram of the plant to answer several of these questions. This is precisely the idea behind Augmented Business Visualization. An Augmented Business Visualization (ABV) solution is one where your structured data (enterprise application data) and your unstructured data (documents, contracts, floor plans, designs, etc.) come together to allow you to make better decisions.  Essentially we're showing your business data into its context. AutoVue allows you to create ABV solutions by integrating your enterprise application with AutoVue’s hotspot framework. Hotspots can be defined for your document. Users can click these hotspots to trigger actions in your enterprise app. Similarly, the enterprise app can highlight the hotspots in your document based on its business data, creating a visual dashboard of your business data in the context of your document. ABV is not new. We introduced the hotspot framework in AutoVue 20.1 with text hotspots. Any text in a PDF or 2D CAD drawing could be turned into a hotspot. In 20.2 we have enhanced this to include 2 new types of hotspots: 3D and regional hotspots. 3D hotspots allow you to turn 3D parts into hotspots. Hotspots can be defined based on the attributes of the part, so you can create hotspots based on part numbers, material, date of delivery, etc.  Regional hotspots allow an administrator to define rectangular regions on any PDF, image, or 2D CAD drawing. This is perfect for cases where the document you’re using either doesn’t have text in it (a JPG or TIFF for example) or if you want to define hotspots that don’t correspond to the text in the document. There are lots of possible uses for AutoVue hotspots.  A great demonstration of how our hotspot capabilities can help add context to enterprise data in the Energy sector can be found in the following AutoVue movies: Maintenance Planning in the Energy Sector - Watch it Now Capital Construction Project Management in the Energy Sector  -  Watch it Now Commissioning and Handover Process for the Energy Sector  -  Watch it Now

    Read the article

  • How do I install the driver for my Linksys AE1200 Wireless-N USB Adapter?

    - by Lewis Graham
    I recently downloaded Ubuntu from the main website with the hopes of dual booting it with Windows. While the operating system works, it says that I need to install a driver for my graphics card. When I type in my password the installation fails. I figure it is because I need Internet access. I tried to install my WiFi USB adapter with the installation disc but Ubuntu doesn't seem to run the setup when I click the exe. What are my available solutions as I would really like to use Ubuntu from my programming and Windows for my gaming needs? The name as read on the box is: Linksys AE1200 Wireless- N USB Adapter The description reads as such: ID 13b1:0039 Linksys (a comma messed up format) ID 046d:0a0b Logitech, Inc. ClearChat Pro USB (headset)

    Read the article

  • "ODM" - One of the Support team's most valued acronyms

    - by graham.mckendry(at)oracle.com
    If you submit technical service requests (SRs) through the My Oracle Support portal, you may often see the term "ODM" used in updates from our Support team. ODM is an acronym for "Oracle Diagnostic Methodology", which defines a standard problem solving approach that all of Oracle Support uses for every technical SR. ODM provides a number of benefits to the SRs - both for the Support organization and for the customer - including a consistent approach, higher quality, justified solutions, and ultimately faster resolution. Screenshot: Example of an ODM "Issue Clarification" activity in a service request The Oracle Diagnostic Methodology applies to both categories of technical SRs: Consultative (question-answer topics) and Problem-Solution. There are a few KM Notes that describe the steps of ODM, however to keep things simple (and since those KM Notes appear to be a bit outdated), I'll summarize the ODM stages here as follows: Consultative ODM - Three mandatory stages: ODM Question: Clarification of the customer's exact question. ODM Answer: Thorough answer to the customer's question. ODM Knowledge Content: Reference to new or existing knowledge base content, or explanation why the particular SR does not necessarily require knowledge content. Problem-Solution ODM - Eight mandatory stages: ODM Issue Clarification: Clarification of the reported issue, including the symptoms, the steps to reproduce, and an outline of the business impact ODM Issue Verification: Confirmation of the issue being verified based on proof provided by the customer, such as screenshots, log files, or reproducing the issue during an Oracle Web Conference. ODM Cause Determination: Succinct outline of the root cause of the issue. ODM Cause Justification: Explanation as to why the root cause applies to this particular situation. ODM Proposed Solution(s): Succinct outline of the potential solution(s) to resolve the issue. ODM Proposed Solution(s) Justification: Explanation of why the proposed solution(s) will in fact resolve the issue. ODM Solution Action Plan: Detailed numbered instructions on how to execute the proposed solutions. ODM Knowledge Content: Reference to new or existing knowledge base content, or explanation why the particular SR does not necessarily require knowledge content. During these stages, you may see other optional ODM-related activities such as "ODM Data Collection", "ODM Action Plan", "ODM Research", and "ODM Test Case". Again, these structured tags help ensure a uniform methodology across your SRs. With this knowledge you should be able to develop better predictability of what's coming next in your SRs, as well as what you can do to help expedite the resolution process.

    Read the article

  • Sharding / indexing strategy for multi-faceted search

    - by Graham
    I'm currently thinking about our database structure and how we modify it for scale. Specifically, we're thinking about using ElasticSearch to provide our search functionality. One common pattern with ElasticSearch seems to be the 'user-routing' pattern; that is, using routing to ensure that any one user's data resides on the same shard. This is great for client-specific search e.g. Gmail. Our application has a constraint such that any user will have a maximum of a few thousand documents, so this pattern seems like a good candidate. However, our search needs to work across all users, as well as targeting a specific user (so I might search my content, Alice's content, or all content). Similarly, we need to provide full-text search across any timeframe; recent months to several years ago. I'm thinking of combining the 'user-routing' and 'index-per-time-interval' patterns: I create an index for each month By default, searches are aliased against the most recent X months If no results are found, we can search against previous X months As we grow, we can reduce the interval X Each document is routed by the user ID So, this should let us do the following: search by user. This will search all indeces across 1 shard search by time. This will search ~2 indeces (by default) across all shards Is this a reasonable approach, considering we may scale to multi-million+ documents? Or should I be denormalizing the data somehow, so that user searches are performed on a totally seperate index from date searches? Thanks for any pros-cons of the above scenario.

    Read the article

  • File doesn't exist when trying to change permissions following the avasys image scan manual

    - by Howard Graham
    I was finally able to connect to avasys.jp and downloaded and installed iscan_2.28.1-3.ltdl7_amd64.deb iscan-data_1.13.0-1_all.deb. The programs appeared to install correctly. I then ran sane-find-scanner and got back: found USB scanner (vendor=0x04b8, product=0x012d) at libusb:001:003 I then ran lsusb and got back: Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 003: ID 04b8:012d Seiko Epson Corp. Perfection V10/V100 (GT-S600/F650) Bus 001 Device 004: ID 03f0:4817 Hewlett-Packard Bus 002 Device 002: ID 093a:2510 Pixart Imaging, Inc. Optical Mouse the avasys image scan manual instructed me to run chmod 0666 /proc/bus/usb/001/003 which returned chmod: cannot access `/proc/bus/usb/001/003': No such file or directory In 12.04, no such directory exists. 12.04 appears to deal with USB in another way. What must I do to get the usb port 001/003 recognized by xsane and sane as the port where the scanner can be located? What must I do to continue installing the scanner?

    Read the article

  • Reflective practice in programming using keystroke playback

    - by Graham
    I'm thinking of applying Reflective Practice to improving my programming skills. To that end, I want to be able to watch myself writing code. In general, what is a good method for applying Reflective Practice to the craft of programming? In particular, if it's a good idea, is there an editor that records keystrokes then plays them back at a later time - possibly running the keys together without delays, or replaying at a 2x/4x/8x accelerated rate? Screencasting with RecordMyDesktop is an option, but has downsides of waiting for encoding and ending up with a big video file instead of a list of keystrokes.

    Read the article

  • How-To: AutoVue Bug Status Tracking & Email Notifications

    - by Graham McKendry
    I’ve posted a number of different Support process-related and tool-related blog entries over the past few years, and one common question I received back from various customers and partners is “How can I easily track AutoVue bugs & enhancements for status updates?” The capability to track bug status through the My Oracle Support (MOS) portal has existed in different forms for a while, although hasn’t necessarily been easy to find without going through specific segments of the extensive MOS training. Recently, the instructions were consolidated into the following highly recommended knowledge base article: KM Note 1298390.1 - How to Monitor a Bug from My Oracle Support The note covers various capabilities, including: How to add the new ‘Bug Tracker’ widget to your MOS dashboard How to add and manage bugs within the Bug Tracker and probably most interesting to MOS users... How to enable email notifications for bug status updates Make sure to pass this KM Note along to your MOS users in case they haven’t already configured this valuable feature.

    Read the article

  • How to make the members of my Data Access Layer object aware of their siblings

    - by Graham
    My team currently has a project with a data access object composed like so: public abstract class DataProvider { public CustomerRepository CustomerRepo { get; private set; } public InvoiceRepository InvoiceRepo { get; private set; } public InventoryRepository InventoryRepo { get; private set; } // couple more like the above } We have non-abstract classes that inherit from DataProvider, and the type of "CustomerRepo" that gets instantiated is controlled by that child class. public class FloridaDataProvider { public FloridaDataProvider() { CustomerRepo = new FloridaCustomerRepo(); // derived from base CustomerRepository InvoiceRepo = new InvoiceRespository(); InventoryRepo = new InventoryRepository(); } } Our problem is that some of the methods inside a given repo really would benefit from having access to the other repo's. Like, a method inside InventoryRepository needs to get to Customer data to do some determinations, so I need to pass in a reference to a CustomerRepository object. Whats the best way for these "sibling" repos to be aware of each other and have the ability to call each other's methods as-needed? Virtually all the other repos would benefit from having the CustomerRepo, for example, because it is where names/phones/etc are selected from, and these data elements need to be added to the various objects that are returned out of the other repos. I can't just new-up a plain "CustomerRepository" object inside a method within a different repo, because it might not be the base CustomerRepository that actually needs to run.

    Read the article

  • C# find a value from an object column using a string from another column

    - by Graham
    I have 2 list in foreach loops.. I currently use a 'switch' statement on the m.columnname and then assign the value of that column to another var map as per below.. If m.columnname = 'DocHeading' then v.docheading is assigned to map.value.. There will always be a match on m.columnname to a column in the var v. is there a way to get the value from the var v using the string from m.columnname? The reason is that the users will want to add and change column names and I dont want to have to change this code all the time.. Hope this makes sense List spreadMapping = new List(); foreach (var m in mappings) { foreach (var v in hvalues) { SpreadMappings map = new SpreadMappings(); switch (m.ColumnName) { case “DocHeading”: map.ColumnX = m.ColumnX; map.ColumnY = m.ColumnY; map.ColumnValue = v.DocHeading; map.ColumnName = m.ColumnName; map.ColumnId = v.Id; map.ColumnSheetName = sheetName; spreadMapping.Add(map); break;

    Read the article

  • Can too many 301 redirects cause a DNS error?

    - by Graham
    For a site http://imageocd.com that I just set up I initially spelled the category "automobiles" as "autimobiles"... I know it's rediculous. I then set up over 10,000 pages behind that category e.g. http://imageocd.com/automobiles/hillman-minx-cabrio-pictures-and-wallpapers. So, I set up over 10,000 301 url redirects to change the spelling on automobiles. I just checked my Google Webmasters report and got an error saying: http://www.imageocd.com/: Googlebot can't access your siteSep 7, 2012 Over the last 24 hours, Googlebot encountered 2 errors while attempting to retrieve DNS information for your site. The overall error rate for DNS queries for your site is 66.7%. Could the overabundance of 301 redirects be causing this? I host 13 sites on this dedicated server and all sites are running fine. I also contacted GoDaddy and they said the server is running fine. Any ideas on what might be going on? Also, I have "canonical" set up for every URL. Could this be part of the error? Thanks.

    Read the article

  • If C-Panel Indexing Manager sets a folder to "No Indexing" can it be crawled by a webcrawler?

    - by Graham
    People are able to view directories / folders on my site right now. So, they could go to mysite.com/images and see the full index. To prevent this, C-Panel offers an option to set a directory / folder to "No Indexing" under the "Index Manager." Will this option allow webcrawlers to crawl / index the images? Or, is there a simpler alternative to block access to all folders directly while still having it SEO friendly? My old server restricted direct access to folders by default. But, the new one does not. Any ideas on this? Thanks!

    Read the article

  • Is there an imperative language with a Haskell-like type system?

    - by Graham Kaemmer
    I've tried to learn Haskell a few times over the last few years, and, maybe because I know mainly scripting languages, the functional-ness of it has always bothered me (monads seem like a huge mess for doing lots of I/O). However, I think it's type system is perfect. Reading through a guide to Haskell's types and typeclasses (like this), I don't really see a reason why they would require a functional language, and furthermore, they seem like they would be perfect for an industry-grade object-oriented language (like Java). This all begs the question: has anyone ever taken Haskell's typing system and made a imperative, OOP language with it? If so, I want to use it.

    Read the article

  • Objective C loop logic

    - by Graham
    Hi guys, I'm really new to programming in Obj-C, my background is in labview which is a graphical programming language, I've worked with Visual Basic some and HTML/CSS a fair amount as well. I'm trying to figure out the logic to create an array of data for the pattern below. I need the pattern later to extract data from another 2 arrays in a specific order. I can do it by referencing a = 1, b = 2, c = 3 etc and then creating the array with a, b, c but I want to use a loop so that I don't have 8 references above the array. These references will be used to generate another generation of data so unless I can get help figuring out the logic I'll actually end up with 72 references above the array. // This is the first one which gives the pattern 0 0 0 0 (etc) // 1 1 1 1 // 2 2 2 2 NSMutableArray * expSecondRef_one = [NSMutableArray array]; int a1 = 0; while (a1 < 9) { int a2 = 0; while (a2 < 8) { NSNumber * a3 = [NSNumber numberWithInt:a1]; [expSecondRef_one addObject:a3]; a2++; } a1++; } // This is the second one which I'm stumbling over, I am looking for the pattern 1 2 3 4 5 6 7 8 // 0 2 3 4 5 6 7 8 // 0 1 3 4 5 6 7 8 // 0 1 2 4 5 6 7 8 // etc to -> // 0 1 2 3 4 5 6 7 If you run it in a line every 9th number is -1 but I don't know how to do that over a pattern of 8. Thanks in advance! Graham

    Read the article

  • Opening a xul file in response to a toolbar extension button click

    - by Graham
    I'm currently building my first Firefox extension, and am having a little difficulty with one piece of functionality. I'd like to open a new browser tab in response to a button click on the toolbar. The new tab should contain the contents of a webpage, together with some extra buttons. At the moment I've created a separate xul file for the contents of the new tab: <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <window id="myapp-report-window" title="Example 4.5.1" xmlns:html="http://www.w3.org/1999/xhtml" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <script type="application/x-javascript" src="chrome://myapp/content/main.js" /> <toolbox> <toolbar id="nav-toolbar"> <toolbarbutton label="This-is-going-to-do-some-stuff"/> </toolbar> </toolbox> <iframe id="myapp-report-frame" flex="1"/> <script type="text/javascript"> function loadPage(url){ document.getElementById('myapp-report-frame').setAttribute('src',url); } </script> </window> This xul file is launched via this javascript, referenced from the main myapptoolbar.xul: gBrowser.selectedTab = gBrowser.addTab('chrome://myapp/content/report.xul'); var newTabBrowser = gBrowser.getBrowserForTab(gBrowser.selectedTab); newTabBrowser.addEventListener("load", function(){ loadPage('http://www.somedynamicallysetwebsite.com'); }, true); The problem that I'm having is that the loadPage function is not being found, so the src attribute of the iframe is never set. I'm sure it's some silly scoping problem, but I'm very new to firefox extensions (day 2!) so any help would be much appreciated. Thanks for looking! Graham

    Read the article

  • sqlite no such table

    - by Graham B
    can anyone please help. I've seen many people with the same problem and looked at all suggestions but still cannot get this to work. I have tried to unistall the application and install again, I have tried to change the version number and start again. I've debugged the code and it does go into the onCreate function, but when I go to make a select query it says the users table does not exist. Any help would greatly be appreciated. Thanks guys DatabaseHandler Class public class DatabaseHandler extends SQLiteOpenHelper { // Variables protected static final int DATABASE_VERSION = 1; protected static final String DATABASE_NAME = "MyUser.db"; // Constructor public DatabaseHandler(Context context) { super(context, DATABASE_NAME, null, DATABASE_VERSION); } // Creating Tables @Override public void onCreate(SQLiteDatabase db) { // Create the Users table // NOTE: I have the column variables saved above String CREATE_USERS_TABLE = "CREATE TABLE IF NOT EXISTS Users(" + KEY_PRIMARY_ID + " " + INTEGER + " " + PRIMARY_KEY + " " + AUTO_INCREMENT + " " + NOT_NULL + "," + USERS_KEY_EMAIL + " " + NVARCHAR+"(1000)" + " " + UNIQUE + " " + NOT_NULL + "," + USERS_KEY_PIN + " " + NVARCHAR+"(10)" + " " + NOT_NULL + ")"; db.execSQL(CREATE_USERS_TABLE); } // Upgrading database @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { db.execSQL("DROP TABLE IF EXISTS Users"); onCreate(db); } UserDataSource class public class UserDataSource { private SQLiteDatabase db; private DatabaseHandler dbHandler; public UserDataSource(Context context) { dbHandler = new DatabaseHandler(context); } public void OpenWriteable() throws SQLException { db = dbHandler.getWritableDatabase(); } public void Close() { dbHandler.close(); } // Validate the user login with the username and password provided public void ValidateLogin(String username, String pin) throws CustomException { Cursor cursor = db.rawQuery( "select * from Users where " + DatabaseHandler.USERS_KEY_EMAIL + " = '" + username + "'" + " and " + DatabaseHandler.USERS_KEY_PIN + " = '" + pin + "'" , null); ........ } Then in the activity class, I'm calling UserDataSource uds = new UserDataSource (this); uds.OpenWriteable(); uds.ValidateLogin("name", "pin"); Any help would be great, thanks very much Graham The following is the attached log from the error report 11-23 17:47:46.414: I/SqliteDatabaseCpp(26717): sqlite returned: error code = 1, msg = no such table: Users, db=/data/data/prometric.myitemwriter/databases/MyUser.db 11-23 17:47:57.085: D/AndroidRuntime(26717): Shutting down VM 11-23 17:47:57.085: W/dalvikvm(26717): threadid=1: thread exiting with uncaught exception (group=0x40bec1f8) 11-23 17:47:57.171: D/dalvikvm(26717): GC_CONCURRENT freed 575K, 8% free 8649K/9351K, paused 2ms+6ms 11-23 17:47:57.179: E/AndroidRuntime(26717): FATAL EXCEPTION: main 11-23 17:47:57.179: E/AndroidRuntime(26717): java.lang.IllegalStateException: Could not execute method of the activity 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.view.View$1.onClick(View.java:3091) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.view.View.performClick(View.java:3558) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.view.View$PerformClick.run(View.java:14152) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.os.Handler.handleCallback(Handler.java:605) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.os.Handler.dispatchMessage(Handler.java:92) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.os.Looper.loop(Looper.java:137) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.app.ActivityThread.main(ActivityThread.java:4514) 11-23 17:47:57.179: E/AndroidRuntime(26717): at java.lang.reflect.Method.invokeNative(Native Method) 11-23 17:47:57.179: E/AndroidRuntime(26717): at java.lang.reflect.Method.invoke(Method.java:511) 11-23 17:47:57.179: E/AndroidRuntime(26717): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:790) 11-23 17:47:57.179: E/AndroidRuntime(26717): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:557) 11-23 17:47:57.179: E/AndroidRuntime(26717): at dalvik.system.NativeStart.main(Native Method) 11-23 17:47:57.179: E/AndroidRuntime(26717): Caused by: java.lang.reflect.InvocationTargetException 11-23 17:47:57.179: E/AndroidRuntime(26717): at java.lang.reflect.Method.invokeNative(Native Method) 11-23 17:47:57.179: E/AndroidRuntime(26717): at java.lang.reflect.Method.invoke(Method.java:511) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.view.View$1.onClick(View.java:3086) 11-23 17:47:57.179: E/AndroidRuntime(26717): ... 11 more 11-23 17:47:57.179: E/AndroidRuntime(26717): Caused by: android.database.sqlite.SQLiteException: no such table: Users: , while compiling: select * from Users where email = '' and pin = '' 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteCompiledSql.native_compile(Native Method) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteCompiledSql.<init>(SQLiteCompiledSql.java:68) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteProgram.compileSql(SQLiteProgram.java:143) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteProgram.compileAndbindAllArgs(SQLiteProgram.java:361) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteProgram.<init>(SQLiteProgram.java:127) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteProgram.<init>(SQLiteProgram.java:94) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteQuery.<init>(SQLiteQuery.java:53) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:47) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1685) 11-23 17:47:57.179: E/AndroidRuntime(26717): at android.database.sqlite.SQLiteDatabase.rawQuery(SQLiteDatabase.java:1659) 11-23 17:47:57.179: E/AndroidRuntime(26717): at projectname.database.UserDataSource.ValidateLogin(UserDataSource.java:73) 11-23 17:47:57.179: E/AndroidRuntime(26717): at projectname.LoginActivity.btn_login_Click(LoginActivity.java:47) 11-23 17:47:57.179: E/AndroidRuntime(26717): ... 14 more

    Read the article

  • Access Home Network Server via External Address (DSL vs Cable)

    - by Dominic Barnes
    For the last few months, I've been using a server on my home network for basic backups and hosting some small websites. Up until this past week, I've been using Comcast (cable) as an ISP and now that I've moved into an apartment, I'm using AT&T. (DSL) I've set up dynamic DNS and I can verify it works externally. However, I can't seem to access the public address from within the local network. Is there something DSL does differently from Cable that makes this frustration possible?

    Read the article

  • Access Home Network Server via External Address (DSL vs Cable)

    - by Dominic Barnes
    For the last few months, I've been using a server on my home network for basic backups and hosting some small websites. Up until this past week, I've been using Comcast (cable) as an ISP and now that I've moved into an apartment, I'm using AT&T. (DSL) I've set up dynamic DNS and I can verify it works externally. However, I can't seem to access the public address from within the local network. Is there something DSL does differently from Cable that makes this frustration possible?

    Read the article

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