Search Results

Search found 1114 results on 45 pages for 'robert gould'.

Page 28/45 | < Previous Page | 24 25 26 27 28 29 30 31 32 33 34 35  | Next Page >

  • make include directive and dependency generation with -MM

    - by Robert S. Barnes
    I want a build rule to be triggered by an include directive if the target of the include is out of date or doesn't exist. Currently the makefile looks like this: program_NAME := wget++ program_H_SRCS := $(wildcard *.h) program_CXX_SRCS := $(wildcard *.cpp) program_CXX_OBJS := ${program_CXX_SRCS:.cpp=.o} program_OBJS := $(program_CXX_OBJS) DEPS = make.deps .PHONY: all clean distclean all: $(program_NAME) $(DEPS) $(program_NAME): $(program_OBJS) $(LINK.cc) $(program_OBJS) -o $(program_NAME) clean: @- $(RM) $(program_NAME) @- $(RM) $(program_OBJS) @- $(RM) make.deps distclean: clean make.deps: $(program_CXX_SRCS) $(program_H_SRCS) $(CXX) $(CPPFLAGS) -MM $(program_CXX_SRCS) > make.deps include $(DEPS) The problem is that it seems like the include directive is executing before the rule to build make.deps which effectively means make either getting no dependency list if make.deps doesn't exist or always getting the make.deps from the previous build and not the current one. For example: $ make clean $ make makefile:32: make.deps: No such file or directory g++ -MM addrCache.cpp connCache.cpp httpClient.cpp wget++.cpp > make.deps g++ -c -o addrCache.o addrCache.cpp g++ -c -o connCache.o connCache.cpp g++ -c -o httpClient.o httpClient.cpp g++ -c -o wget++.o wget++.cpp g++ addrCache.o connCache.o httpClient.o wget++.o -o wget++

    Read the article

  • Have to login twice. PHP sessions and login troubles with Chrome and Opera.

    - by Robert
    The problem I am encountering is that for my login form I have to login twice for the session to register properly, but only in Chrome (my version is 4.0.249.89) and Opera (my version is 10.10). Here is the stripped down code that I am testing on: Login Page: session_start(); $_SESSION['user_id'] = 8; $_SESSION['user_name'] = 'Jim'; session_write_close(); header('Location: http://www.my-domain-name.com/'); exit(); Home Page: session_start(); if ( isset($_SESSION['user_id']) ) { echo "You are logged in!"; } else { echo "You are NOT logged in!"; } Logout Page: session_start(); session_unset(); session_destroy(); header('Location: http://www.my-domain-name.com/'); exit(); Currently, under a fresh load with no cookies, if I go to my-domain-name.com/login/ it will redirect to the home page and say "You are NOT logged in!" but if I go there again it will say "You are logged in!". Any ideas? Thanks for your help.

    Read the article

  • Unboxing to unknown type

    - by Robert
    I'm trying to figure out syntax that supports unboxing an integral type (short/int/long) to its intrinsic type, when the type itself is unknown. Here is a completely contrived example that demonstrates the concept: // Just a simple container that returns values as objects struct DataStruct { public short ShortVale; public int IntValue; public long LongValue; public object GetBoxedShortValue() { return LongValue; } public object GetBoxedIntValue() { return LongValue; } public object GetBoxedLongValue() { return LongValue; } } static void Main( string[] args ) { DataStruct data; // Initialize data - any value will do data.LongValue = data.IntValue = data.ShortVale = 42; DataStruct newData; // This works if you know the type you are expecting! newData.ShortVale = (short)data.GetBoxedShortValue(); newData.IntValue = (int)data.GetBoxedIntValue(); newData.LongValue = (long)data.GetBoxedLongValue(); // But what about when you don't know? newData.ShortVale = data.GetBoxedShortValue(); // error newData.IntValue = data.GetBoxedIntValue(); // error newData.LongValue = data.GetBoxedLongValue(); // error } In each case, the integral types are consistent, so there should be some form of syntax that says "the object contains a simple type of X, return that as X (even though I don't know what X is)". Because the objects ultimately come from the same source, there really can't be a mismatch (short != long). I apologize for the contrived example, it seemed like the best way to demonstrate the syntax. Thanks.

    Read the article

  • Find if id of a link equals id of parent container

    - by Robert Lawson
    Hi guys needing a bit of help. I am creating a one page personal site. Each section has a menu in it to jump to another section, however i want to have a class added to menu for the current section: i.e. if you are in about the about link would have a class 'current'. This is how it looks. <section id="about"> <nav> <li><a href="#" id ="about">About</a></li> <li><a href="#" id ="contact">About</a></li> <li><a href="#" id ="blog">About</a></li> </nav> New to jquery so i am struggling to find out how to do this. Any help will be greatly appreciated. Thanks

    Read the article

  • GNUPlot: change axis labels

    - by Robert
    Dear Guys, I have used the following statement to get the GNUPlot plot a grah for me: plot "force.dat" using 1:2 title "Detroit" with lines, \ "force.dat" u 1:3 t "US Avergae" w linepoints and the "force.dat" looks like 2005 0 0 2006 104 51 2007 202 101 It draws nice graph for me. However, I don't like the X-axis, because it is labelled as 2005, 2005.5, 2006, 2006.5, 2007 etc.. However, those are year identifiers, I only want the 2005, 2006, 2007 etc., how could I get rid of the 2005.5, 2006.5 etc. labels in my GNUPlot graph? Thank you very much for your ideas.

    Read the article

  • LINQ expression precedence with Skip(), Take() and OrderBy()

    - by Robert Koritnik
    I'm using LINQ to Entities and display paged results. But I'm having issues with the combination of Skip(), Take() and OrderBy() calls. Everything works fine, except that OrderBy() is assigned too late. It's executed after result set has been cut down by Skip() and Take(). So each page of results has items in order. But ordering is done on a page handful of data instead of ordering of the whole set and then limiting those records with Skip() and Take(). How do I set precedence with these statements? My example (simplified) var query = ctx.EntitySet.Where(/* filter */).OrderBy(/* expression */); int total = query.Count(); var result = query.Skip(n).Take(x).ToList();

    Read the article

  • Automatic VM deployment

    - by Robert Wilson
    I have an idea to streamline deployments of prototypes within our team using VMs. The idea would be that a developer would be able to deploy their artifacts to Maven, then use a Web interface to pull them onto a development VM for integration/regression testing. They would then be able to to push those artifacts to a reference system, and finally onto production. I'm currently thinking of doing this myself using the vSphere Java API ( http://vijava.sourceforge.net/ ), and some simple scripting to grab artifacts from the Maven repository, configuration from SVN, and then start up a JBoss server. It feels like the kind of thing that may already be available though, has anyone heard of something similar?

    Read the article

  • ICalendar parser in PHP that supports timezones

    - by Vincent Robert
    I am looking for a PHP class that can parse an ICalendar (ICS) file and correctly handle timezones. I already created an ICS parser myself but it can only handle timezones known to PHP (like 'Europe/Paris'). Unfortunately, ICS file generated by Evolution (default calendar software of Ubuntu) does not use default timezone IDs. It exports events with its a specific timezone ID exporting also the full definition of the timezone: daylight saving dates, recurrence rule and all the hard stuff to understand about timezones. This is too much for me. Since it was only a small utility for my girlfriend, I won't have time to investigate further the ICalendar specification and create a full blown ICalendar parser myself. So is there any known implementation in PHP of ICalendar file format that can parse timezones definitions?

    Read the article

  • Is Form validation and Business validation too much?

    - by Robert Cabri
    I've got this question about form validation and business validation. I see a lot of frameworks that use some sort of form validation library. You submit some values and the library validates the values from the form. If not ok it will show some errors on you screen. If all goes to plan the values will be set into domain objects. Here the values will be or, better said, should validated (again). Most likely the same validation in the validation library. I know 2 PHP frameworks having this kind of construction Zend/Kohana. When I look at programming and some principles like Don't Repeat Yourself (DRY) and single responsibility principle (SRP) this isn't a good way. As you can see it validates twice. Why not create domain objects that do the actual validation. Example: Form with username and email form is submitted. Values of the username field and the email field will be populated in 2 different Domain objects: Username and Email class Username {} class Email {} These objects validate their data and if not valid throw an exception. Do you agree? What do you think about this aproach? Is there a better way to implement validations? I'm confused about a lot of frameworks/developers handling this stuff. Are they all wrong or am I missing a point? Edit: I know there should also be client side kind of validation. This is a different ballgame in my Opinion. If You have some comments on this and a way to deal with this kind of stuff, please provide.

    Read the article

  • how to refresh list of photos after uploadify jquery

    - by robert
    hello, I want to do a sort of photo editor, i use uploadify to upload images here are my files: http://www.mediafire.com/?nddjyzyygj5 the problem is: after upload the images i dinamicaly generate a thumb .. When I click on it it show me the large pictures in another page, i want to show the picture in a div or a paragraf! after I refresh the page is working! why? from my php script i recive only the image name (response) after UploadifyComplete i append this: jQuery("#" + jQuery(this).attr('id') + ID).html('<a href="uploads/' + response + '"><img width="60px" height="60px" src="uploads/' + response + '" alt="' + response + '" /></a>'); to this: jQuery(queue).append('<li class="uploadifyQueueItem">\ <span class="fileName">' + fileName + ' (' + byteSize + suffix + ')</span>\ <div class="uploadifyProgress">\ <div id="' + jQuery(this).attr('id') + ID + 'ProgressBar" class="uploadifyProgressBar"><!--Progress Bar--></div>\ </div>\ </li>'); } and the result will be: <div class="uploadifyQueue"> <ul id="mainftpQueue"> <li class="uploadifyQueueItem"> <a href="uploads/Winter.jpg"><img height="60px" width="60px" alt="Winter.jpg" src="uploads/Winter.jpg"></a> </li> </ul> </div> i putt all the images in 1 php array after all images uploaded i want to refresh the div where this code is: <div class="uploadifyQueue"> <?php if ($_SESSION['files']){ print '<ul id="mainftpQueue">'."\n"; foreach($_SESSION['files'] as $image ): print '<li class="uploadifyQueueItem">'."\n"; print '<a href="uploads/'.$image.'"><img height="60px" width="60px" alt="'.$image.'" src="uploads/'.$image.'"></a>'."\n"; print "</li>\n"; endforeach; print "</ul>\n"; } ?> </div> i try with: $('#mainftpQueue').load(location.href+" #mainftpQueue>*",""); $('#mainftpQueue').load("/ #mainftpQueue li"); buth no succes sorry 4 my bad english.. if any 1 can edit this thanks

    Read the article

  • How to use SendMessage to another form in same app

    - by Robert Frank
    I've been trying to get this to work for some time now and can't figure it out. Probably obvious once you know it. I simply want a non-modal form (or perhaps an instantiated non-TForm class) to send a message to the application's main form. I can make the main form send a message to itself and receive (announcing with a beep) But, I can't seem to have other objects send messages to the main form. I'm using WM_MY_MESSAGE = WM_APP + 200; What should the first argument of the SendMessage be to send a message to the main form? Even sending it to Application.MainForm.Handle doesn't seem to work. The reason I need to do this is that the modal form has a slider that another form (#2) needs to know when it changes. Notifying the other form via a callback procedure was making it sluggish as form #2 did some work before returning from the call. Is having a modal form send a windows message to the main form a reasonable way to avoid this?

    Read the article

  • What should I call a class that contains a sequence of states

    - by Robert P
    I have a GUI tool that manages state sequences. One component is a class that contains a set of states, your typical DFA state machine. For now, I'll call this a StateSet. However, I have another class that has a collection (possibly partially unordered) of those state sets, and lists them in a particular order. and I'm trying to come up with a good name for it - not just for internal code, but for customers to refer to it. I've got: Sequence (maybe) StateSetSet (reasonable for code, but not for customers) Any other suggestions or ideas?

    Read the article

  • Programmatically controlled virtual drive

    - by Robert Lin
    How would I go about creating a virtual drive with which I can programmatically and dynamically change the contents? For instance, program A starts running and creates a virtual drive. When program B looks in the drive, it sees an error log and starts reading/processing it. In the middle of all this program A gets a signal from somewhere and decides to add to the log. I want program B to be unaware of the change and just keep on going. Program B should continue reading as if nothing happened. Program A would just report a rediculously large file size for the log and then fill it in as appropriate. Program A would fill the log with tags if program B tries to read past the last entry. I know this is a weird request but there's really no other way to do this... I basically can't rewrite program B so I need to fool it. How do I do this in windows? How about OSX?

    Read the article

  • "How to: Multiple jQuery Image Swap Galleries on the Same Page?" / ASAP

    - by Robert
    I have multiple image galleries that use the following code (simply view the demo at the following link). http://www.sohtanaka.com/web-design/fancy-thumbnail-hover-effect-w-jquery/ However, when one clicks on the thumbnails of one gallery to change the large image preview - all the galleries change automatically to that large preview as well. In short, the question is: "How do I seperate each gallery from each other so when the user clicks on the thumbnails of one specific gallery the large image preview of that gallery changes and not any other?"

    Read the article

  • "Socket operation on non-socket" error due to strange syntax

    - by Robert S. Barnes
    I ran across the error Socket operation on non-socket in some of my networking code when calling connect and spent a lot of time trying to figure out what was causing it. I finally figured out that the following line of code was causing the problem: if ((sockfd = socket( ai->ai_family, ai->ai_socktype, ai->ai_protocol) < 0)) { See the problem? Here's what the line should look like: if ((sockfd = socket( ai->ai_family, ai->ai_socktype, ai->ai_protocol)) < 0) { What I don't understand is why the first, incorrect line doesn't produce a warning. To put it another way, shouldn't the general form: if ( foo = bar() < baz ) do_something(); look odd to the compiler, especially running with g++ -Wall -Wextra? If not, shouldn't it at least show up as "bad style" to cppcheck, which I'm also running as part of my compile?

    Read the article

  • How to use client side code in Visual studio ASP.NET

    - by Robert
    I am a quite new to web development and I am trying to do some small form updates without causing a postback. For example making a control visible when a drop down list is changed. I have so far come across some features that achieve this like the RequiredFieldValidator inside an update panels. However, these are specific to a single task. What are my options to achieve these client side updates in Visual Studio? At the moment I don't know any JavaScript, so I would prefer another solution if it exists.

    Read the article

  • How to add a Page to Frame using code in WPF

    - by Robert Höglund
    I have a Window where I have put a Frame. I would like to add a Page to the Frame when I click a button that is also on the Window but not in the Frame. There are several buttons in the Window and each click on a button should load a different Page in the Frame. Since I'm a total newbie on this WPF stuff it's quite possible that this approach is not the best and I have thought about replacing the Frame with a Canvas and then make UserControls instead of Pages that will be added to the Canvas. I welcome any ideas and suggestions on how to best solve this. I aiming for a functionality that is similar to the application Billy Hollis demonstrated in dnrtv episode 115. (http://dnrtv.com/default.aspx?showID=115).

    Read the article

  • Web development: Haskell or Scheme

    - by Robert E. Lester
    I would like to to choose one of these languages for building web applications. I'm not interested in framework per say, but have the following needs: Rapid development. Easy to scale. Strong community for the web. Quick and easy to deploy. I'm very familiar with Haskell, and have some familiarity with scheme (in particular PLT). Scheme appeals to me as good candidate for web development due to it's simple syntax which is homogenous across libraries. I state this despite my subjective opinion that Haskell is a 'cleaner' language. Haskell web apps seem to require learning and building a patchwork of different combinator libraries. On the plus side, I realise this can be quite expressive, although I'd prefer to eliminate impedance mismatches where possible. While scheme-plt looks to be a good fit, I can find but one example of it being used in the "real world". Haskell doesn't seem to fair too much better here, but there seems to be a bigger community behind the web side. Please help me make up my mind. For the most part I'm interested in real-world use cases.

    Read the article

  • Postback not working with ASP.NET Routing (Validation of viewstate MAC failed)

    - by Robert
    Hi. I'm using the ASP.NET 3.5 SP1 System.Web.Routing with classic WebForms, as described in http://chriscavanagh.wordpress.com/2008/04/25/systemwebrouting-with-webforms-sample/ All works fine, I have custom SEO urls and even the postback works. But there is a case where the postback always fails and I get a: Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster. Here is the scenario to reproduce the error: Create a standard webform mypage.aspx with a button Create a Route that maps "a/b/{id}" to "~/mypage.aspx" When you execute the site, you can navigate http://localhost:XXXX/a/b/something the page works. But when you press the button you get the error. The error doen't happen when the Route is just "a/{id}". It seems to be related to the number of sub-paths in the url. If there are at least 2 sub-paths the viewstate validation fails. You get the error even with EnableViewStateMac="false". Any ideas? Is it a bug? Thanks

    Read the article

  • PHP edit unique row in table

    - by Robert
    I currently have a PHP form that uses AJAX to connect to MySQL and display records matching a user's selection (http://stackoverflow.com/questions/2593317/ajax-display-mysql-data-with-value-from-multiple-select-boxes) As well as displaying the data, I also place an 'Edit' button next to each result which displays a form where the data can be edited. My problem is editing unique records since currently I only use the selected values for 'name' and 'age' to find the record. If two (or more) records share the same name and age, I am only able to edit the first result.

    Read the article

  • How to control the order of module initialization in Prism

    - by Robert Taylor
    I'm using Prism V2 with a DirectoryModuleCatalog and I need the modules to be initialized in a certain order. The desired order is specified with an attribute on each IModule implementation. This is so that as each module is initialized, they add their View into a TabControl region and the order of the tabs needs to be deterministic and controlled by the module author. The order does not imply a dependency, but rather just an order that they should be initialized in. In other words: modules A, B, and C may have priorities of 1, 2, and 3 respectively. B does not have a dependency on A - it just needs to get loaded into the TabControl region after A. So that we have a deterministic and controllable order of the tabs. Also, B might not exist at runtime; so they would load as A, C because the priority should determine the order (1, 3). If i used the ModuleDependency, then module "C" will not be able to load w/o all of it's dependencies. I can manage the logic of how to sort the modules, but i can't figure out where to put said logic.

    Read the article

  • PowerShell PSCX Read-Archive: Cannot bind parameter... problem

    - by Robert
    I'm running across a problem I can't seem to wrap my head around using the Read-Archive cmdlet available via PowerShell Community Extensions (v2.0.3782.38614). Here is a cut down sample used to exhibit the problem I'm running into: $mainPath = "p:\temp" $dest = Join-Path $mainPath "ps\CenCodes.zip" Read-Archive -Path $dest -Format zip Running the above produces the following error: Read-Archive : Cannot bind parameter 'Path'. Cannot convert the "p:\temp\ps\CenCodes.zip" value of type "System.String" to type "Pscx.IO.PscxPathInfo". At line:3 char:19 + Read-Archive -Path <<<< $dest -Format zip + CategoryInfo : InvalidArgument: (:) [Read-Archive], ParameterBindingException + FullyQualifiedErrorId : CannotConvertArgumentNoMessage,Pscx.Commands.IO.Compression.ReadArchiveCommand If I do not use Join-Path to build the path passed to Read-Archive it works, as in this example: $mainPath = "p:\temp" $path = $mainPath + "\ps\CenCodes.zip" Read-Archive -Path $path -Format zip Output from above: ZIP Folder: CenCodes.zip#\ Index LastWriteTime Size Ratio Name ----- ------------- ---- ----- ---- 0 6/17/2010 2:03 AM 3009106 24.53 % CenCodes.xls Even more confusing is if I compare the two variables passed as the Path argument in the two Read-Archive samples above, they seem identical: This... Write-Host "dest=$dest" Write-Host "path=$path" Write-Host ("path -eq dest is " + ($dest -eq $path).ToString()) Outputs... dest=p:\temp\ps\CenCodes.zip path=p:\temp\ps\CenCodes.zip path -eq dest is True Anyone have any ideas as to why the first sample gripes but the second one works fine?

    Read the article

  • .NET Framework - Possible memory-leaky classes?

    - by Robert Fraser
    Just the other day I was investigating a memory leak that was ballooning the app from ~50MB to ~130MB in under two minutes. Turns out that the problem was with the ConcurrentQueue class. Internally, the class stores a linked list of arrays. When an item is dequeued from the ConcurrentQueue, the index in the array is bumped, but the item remains in the array (i.e. it's not set to null). The entire array node is dropped after enough enqueues/dequeues, so it's not technically a leak, but if storing only a few large objects in the ConcurrentQueue, this can get out of hand fast. The documentation makes no note of this danger. I was wondering what other potential memory pitfalls are in the Base Class Library? I know about the Substring one (that is, if you call substring and just hold onto the result, the whole string will still be in memory). Any others you've encountered?

    Read the article

< Previous Page | 24 25 26 27 28 29 30 31 32 33 34 35  | Next Page >