Search Results

Search found 210 results on 9 pages for 'wayne molina'.

Page 7/9 | < Previous Page | 3 4 5 6 7 8 9  | Next Page >

  • Why does Custom UITableViewCell *sometimes* cause an NSInvalidArgumentException?

    - by Wayne Hartman
    I have created a custom UITableViewCell, but when I dequeue the cell, sometimes it throws an NSInvalidArgumentException: [UITableViewCell nameLabel]: unrecognized selector sent to instance 0x3b4e7f0 Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[UITableViewCell nameLabel]: unrecognized selector sent to instance 0x3b4e7f0' Now, my custom UITableViewCell does have an attribute nameLabel, so I am confused why it is throwing this error. Below is the code I use to dequeue the cell: - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { NSUInteger row = [indexPath row]; CTMenuItemVO* key = [[[self retrieveCartItems] allKeys] objectAtIndex:row]; NSNumber* quantity = [[self retrieveCartItems] objectForKey:key]; static NSString* SectionsTableIdentifier = @"SectionsTableIdentifier2"; OrderItemCell* cell = (OrderItemCell*)[tableView dequeueReusableCellWithIdentifier: SectionsTableIdentifier]; if (cell == nil) { NSArray* topLevelObjects = [[NSBundle mainBundle] loadNibNamed:@"OrderItemCell" owner:nil options:nil]; for(id currentObject in topLevelObjects) { if ([currentObject isKindOfClass:[UITableViewCell class]]) { cell = (OrderItemCell*) currentObject; break; } } } cell.nameLabel.text = key.Name; cell.qtyLabel.text = [quantity stringValue]; return cell; }

    Read the article

  • ASP.NET MVC Render Ajax / Standard View

    - by Wayne
    I am a little confused and making it alot more complicated than this needs to be! Here is what I have... A view which displays a drop down of US States. When the user chooses a state it loads a list of data from a database and returns the results (populates the View Model) and the View renders the information. What I wanted to do was have have the dropdown trigger an Ajax event which performs the data load, but also wanted it to depreciate if the user didn't have Javascript enabled. How would I go about rendering the view with AND without javascript / ajax? Hope that makes sense. Thanks for your help.

    Read the article

  • Refactoring an ASP.NET 2.0 app to be more "modern"

    - by Wayne M
    This is a hypothetical scenario. Let's say you've just been hired at a company with a small development team. The company uses an internal CRM/ERP type system written in .NET 2.0 to manage all of it's day to day things (let's simplify and say customer accounts and records). The app was written a couple of years ago when .NET 2.0 was just out and uses the following architectural designs: Webforms Data layer is a thin wrapper around SqlCommand that calls stored procedures Rudimentary DTO-style business objects that are populated via the sprocs A "business logic" layer that acts as a gateway between the webform and database (i.e. code behind calls that layer) Let's say that as there are more changes and requirements added to the application, you start to feel that the old architecture is showing its age, and changes are increasingly more difficult to make. How would you go about introducing refactoring steps to A) Modernize the app (i.e. proper separation of concerns) and B) Make sure that the app can readily adapt to change in the organization? IMO the changes would involve: Introduce an ORM like Linq to Sql and get rid of the sprocs for CRUD Assuming that you can't just throw out Webforms, introduce the M-V-P pattern to the forms Make sure the gateway classes conform to SRP and the other SOLID principles. Change the logic that is re-used to be web service methods instead of having to reuse code What are your thoughts? Again this is a totally hypothetical scenario that many of us have faced in the past, or may end up facing.

    Read the article

  • Problem with thumbnails after newly added - PHP on-the-fly method

    - by Wayne
    Hey again... to those that may have read my previous question that got solved a couple minutes ago .< The on-the-fly php script works perfectly, but when I went to upload new images into a gallery which I made myself, the images are resized to 150 x 150 for what I wanted... however, when it comes to new images being added it is all black... As you can see the three black images that were uploaded to the folder and the directory added to the database. What is causing this? If I view the source, the code is fine... the while loop in the PHP generates an output like this: <div class="view-wrap" id="photo-10"> <div class="view-icon"> <div class="img-label"> <a href="#" id="10" class="delete"><img src="img/small-delete.png" /> Delete</a> </div> <a href="img/events/Paintballing/24251_1395408043148_1170626626_1204038_5382765_n.jpg"> <img src="image.php?dir=img/events/Paintballing/24251_1395408043148_1170626626_1204038_5382765_n.jpg" alt="" width="110" height="110" /> </a> </div> </div> An example of one block. If I view the source (in Firefox) and click on the image.php?dir=img/events/Paintballing/24251_1395408043148_1170626626_1204038_5382765_n.jpg by exmaple, I can see the thumbnail at it's 150 x 150 size but in the layout, it shows a black thumbnail... Does anyone know why this is happening?

    Read the article

  • Execute a dll function in ASP.Net Bin not working, II7.

    - by Wayne Lo
    I am developing a remote control application where a client (aspx page in a browser) can request a server to "launch a notepad" (for testing purpose, for real life, turning off a light bulb, etc). So I created a dll with a simple function for launching the notepad (on the server side) and dropped this dll in the root bin folder. It worked fine when the aspx page is running under ASP.NET development server (launched from Visual Studio). But when I tested the same aspx page under a FireFox browser, it did not work (launch the notepad) even though it did call for the same function (I stepped through in debugger). Is this a permission issue? How do I set this up in IIS manager, or even better in web.config? Please help.

    Read the article

  • ASP.NET server data persistence

    - by Wayne Werner
    Hi, I'm not really sure exactly how the question should be phrased, so please be patient if I ask the wrong thing. I'm writing an ASP.NET application using VB as the code behind language. I have a data access class that connects to the DB to run the query (parameterized, of course), and another class to perform the validation tasks - I access this class from my aspx page. What I would like is to be able to store the data server side and wait for the user to choose from a few options based on the validity of the data. But unless my understanding is completely off, having persistent data objects on the server will give problems when multiple users connect? My ultimate goal is that once the data has been validated the end user can't modify it. Currently I'm validating the data, but I still have to retrieve it from the web form AFTER the user says OK, which obviously leaves open the possibility of injecting bad data either accidentally (unlikely) or on purpose (also unlikely for the use, but I'd prefer not to take the chance). So am I completely off in my understanding? If so, can someone point me to a resource that provides some instructions on keeping persistent data on the server, or provide instruction? Thanks!

    Read the article

  • Click to make body text larger | JavaScript

    - by Wayne
    Please note this is just an example: <img src="img/normal-font.png" onclick="javascript:document.body.style.fontSize = '13px';" /> &nbsp; <img src="img/medium-font.png" onclick="javascript:document.body.style.fontSize = '14px';" /> &nbsp; <img src="img/large-font.png"onclick="javascript:document.body.style.fontSize = '15px';" /> The body text does indeed enlarge if I choose one of them, but what I like to include is remembering what option you've chosen by reading cookies. In fact, I have no experience in creating cookies in JS, only in PHP. Could someone come up with an example of how to make cookies the simpliest way remembering my option, but whenever someone clicks another one, it should get rid of the cookie that was last set, e.g. Cookie value has 15px, then should update it or remove it with a new cookie with a new value of 13px and so on. Thanks :)

    Read the article

  • Selections and radioing - JavaScript

    - by Wayne
    I have a list like this: <ul> <li id="adm-thumb" onclick="javascript:addBanner('bowling.jpg');"> <div class="adm-tick"></div> <img src="img/banners/bowling.jpg" /></li> <li id="adm-thumb" onclick="javascript:addBanner('kcc.jpg');"> <div class="adm-tick"></div> <img src="img/banners/kcc.jpg" /></li> <li id="adm-thumb" onclick="javascript:addBanner('paintballing.png');"> <div class="adm-tick"></div> <img src="img/banners/paintballing.png" /></li> </ul> <input id="bannername" type="text" /> When one item is clicked, the value inside the addBanner() will be added to the input field, however, I want one list to be selected (which is done by css to make it look like it has) when it is equal to the value of the input value. If the value is equals to the value in the addBanner value then the clicked item should have a red background. e.g. function addBanner(label) { var Field = document.getElementById('bannername'); Field.value = label; if(Field.value != label) { // I have no idea what to put here } } Something like a div button that acts like a radio button.

    Read the article

  • Insert into textarea | JavaScript

    - by Wayne
    I'm trying to insert the image url where the point of the is to be when editing the textarea value. function addImageURL() { var imageurl = prompt("Enter image URL", "Your name") var post = document.getElementById("message-put").value; document.getElementById('message-put').value = post + '[img]' + imageurl + '[/img]'; } This code grabs the value inside the adds the image url next to it which I don't want, I need it to insert it where the point was when editing the textarea Thanks

    Read the article

  • XPath selection from path in XML content

    - by Wayne Robinson
    I have the following XML: <root> <name>The name</name> <long> <path> <value>Some Value</value> </path> </long> <field>/root/name</field> <field>/root/long/path/value</field> </root> and I want to select these paths in the field tags however, when I try the following: <xsl:value-of select="/root/field[1]" /> all I get is the text value of the field. Is there a way of selecting the correct node from those values?

    Read the article

  • How do I create a right click context menu in Java Swing?

    - by Wayne
    I'm working on a school project and we want to implement a right click pop-up menu in the gui. Currently we are doing something like creating a JMenu on right click and setting its location to that of the mouse's position... This seems really ugly and is very buggy, is there any better way of doing this? I'm sure there must be.

    Read the article

  • Rails is not passing the "commit" button parameter

    - by Wayne M
    Reinstalling a Rails app on a new server. Part of the app can fork in one of two directions based on the button the user selects. This part isn't working, and when I look at the log I see the values that I gave the form, execept for the commit portion of the params hash. This seems to be why the app isn't working as expected (since there's nothing in params[:commit], but I have no idea why commit would not be passed in; the request is definitely a POST request, and all of the other parameters are there.

    Read the article

  • jQuery and MySQL

    - by Wayne
    I have taken a jQuery script which would remove divs on a click, but I want to implement deleting records of a MySQL database. In the delete.php: <?php $photo_id = $_POST['id']; $sql = "DELETE FROM photos WHERE id = '" . $photo_id . "'"; $result = mysql_query($sql) or die(mysql_error()); ?> The jQuery script: $(document).ready(function() { $('#load').hide(); }); $(function() { $(".delete").click(function() { $('#load').fadeIn(); var commentContainer = $(this).parent(); var id = $(this).attr("id"); var string = 'id='+ id ; $.ajax({ type: "POST", url: "delete.php", data: string, cache: false, success: function(){ commentContainer.slideUp('slow', function() {$("#photo-" + id).remove();}); $('#load').fadeOut(); } }); return false; }); }); The div goes away when I click on it, but then after I refresh the page, it appears again... How do I get it to delete it from the database? Thanks :) EDIT: Woopsie... forgot to add the db.php to it, so it works now .<

    Read the article

  • PHP Redirect location with htaccess

    - by Wayne
    In one of the page I have is where administrators are allowed, however, I use if the session isn't set, the header will redirect them to index.php and that method works. If I replace index.php with home which is for the htaccess which changes it to index.php but it gives an error in the browser This works: if(!isset($_SESSION['MEMBER'])){ header("Location: index.php"); } This does not work: if(!isset($_SESSION['MEMBER'])){ header("Location: home"); } htaccess: RewriteRule ^home$ index.php The error in Firefox: The page isn't redirecting properly Firefox has detected that the server is redirecting the request for this address in a way that will never complete. This problem can sometimes be caused by disabling or refusing to accept cookies. What's wrong with it? How do I get this method to work?

    Read the article

  • Anything like Heroku for PHP or .NET?

    - by Wayne M
    In my area PHP is very widespread, so is .NET. Ruby not so much; most places have never heard of it. For some personal things I am "forced" to choose Rails because I want to take advantage of Heroku - the ability to deploy and scale on the cloud very easily is the main reason. Also, they offer a small FREE plan that I can use for demo sites or, in this case, for my business' static page; as a totally bootstrapped startup I have maybe $50 or so in initial capital and cannot afford to pay monthly fees while I'm getting started. Are there any similar offerings for other languages? Specifically, I really like the small, 5MB site for free that Heroku offers - is there anything like that for PHP and/or .NET? I'm not even that concerned about the "cloud" part, but that would be a nice bonus. If there is, I might be able to kill two birds with one stone and pick up a useful skill as I'm doing my own thing instead of using something that nobody else knows or cares about. I should add I'm specifically interested in something that offers a free plan. As I said, Heroku has a 5mb plan that you can have as many as you want for free; I have yet to find anything similar for any other platform, and to be honest I'm not too thrilled about using Ruby on Rails for everything simply to take advantage of this.

    Read the article

  • What is the "right" way to make a modular ASP.NET page?

    - by Wayne Werner
    Hi, I'm writing an internal program using ASP.NET (Visual Studio 2008). The basic premise is that folks will connect to the page through their web browser, put in some data (which will be validated and sanitized of course), click "submit" and then a query will be run on a database. I told you that story so I can tell you this story - I want to make my program modular for the likelihood that this program will be updated later on, and probably extended. My initial thought is to compile the database handler as a dll and then use its functionality on my page (see my little diagram). But I can't figure out how to hook the dll into my page - My Google-fu has failed which leads me to my questions: 1) Is creating a dll the "right" solution? If so, continue to question 2, if not, what should I be doing? Any resources/tutorial links would be appreciated. 2) How do I attach a dll? Visual Studio tells me I can't Imports from an .aspx page, and I've tried <%@ Import namespace="MyDllName" % and a few other variations, none of which worked. Thanks!

    Read the article

  • When using emacs do you rebind caps-lock to CTRL?

    - by Wayne Werner
    This question is, as indicated, for those who use Emacs. When you do, do you rebind the caps-lock key to CTRL, or do you use the "normal" ctrl key? I've recently learned some Emacs commands and was using the Visual Studio 2008 emacs commands for a while, and of course I used a caps-rebind tool, but I'm curious how many other people do. On a side note, the emacs bindings for VS are severely incomplete :(

    Read the article

  • HTML and jQuery anchoring

    - by Wayne
    Whenever the url contains the div id, it would obviously go down to the div when the URL has: http://domain.com.faq.php#1 <div id="1">Bla bla bla</div> But what I like is to have same feature of Stackoverflow, when you click on an answer in your messages, it will scroll down to the page and has that fadeOut effect on the answer. How do I do this?

    Read the article

  • Defining Views Based On Selection

    - by Wayne
    Well the title isn't very descriptive but I'm not exactly sure how to explain but here goes! I have a web application (can use either MVC or standard web forms) which a user signs in to. If the user has signed up for more than one product they will have the option to switch between them. For the sakes of this example lets say User1 signs in and has access to Product1, Product2 and Product3. Now, each product will be very different and offer different functionally. What I want is the main view to be focused around the product they have selected and not redirected to a sub domain. What I don't want to have to do is get them to go to www.mysite.com/product1 or www.mysite.com/product2 but simply www.mysite.com regardless of the product they have selected and have the site render the views etc for that product. Wow does any of that make any sense? I was thinking mabe the use of sessions or something and URL rewriting? Are there any sample apps out there that make use of the same kind of functionallity that I could take a look at? Thanks for any help I appreciate it!

    Read the article

  • Receiving integers, but also want to test for char.

    - by Wayne Haworth
    Say I am looking to receive a series of numeric values and read them into an int, but I also want to test if the user hit key 'x'. I am sure I am missing something obvious, and have tried a few things but seem to be stuck. This is what I have so far... cout << endl << "Enter key (or 'x' to exit): "; cin key; if (key == 'x') { cout << "exiting";} // continue on...

    Read the article

< Previous Page | 3 4 5 6 7 8 9  | Next Page >