Search Results

Search found 3846 results on 154 pages for 'life sciences'.

Page 93/154 | < Previous Page | 89 90 91 92 93 94 95 96 97 98 99 100  | Next Page >

  • What features of interpreted languages can a compiled one not have?

    - by sub
    Interpreted languages are usually more high-level and therefore have features as dynamic typing (including creating new variables dynamically without declaration), the infamous eval and many many other features that make a programmer's life easier - but why can't compiled languages have these as well? I don't mean languages like Java that run on a VM, but those that compile to binary like C(++). I'm not going to make a list now but if you are going to ask which features I mean, please look into what PHP, Python, Ruby etc. have to offer. Which common features of interpreted languages can't/don't/do exist in compiled languages? Why?

    Read the article

  • PHP Linefeeds (\n) Not Working

    - by dosboy
    For some reason I can't use \n to create a linefeed when outputting to a file with PHP. It just writes "\n" to the file. I've tried using "\\n" as well, where it just writes "\n" (as expected). But I can't for the life of me figure out why adding \n to my strings isn't creating new lines. I've also tried \r\n but it just appends "\r\n" to the line in the file. Example: error_log('test\n', 3, 'error.log'); error_log('test2\n', 3, 'error.log'); Outputs: test\ntest2\n Using MAMP on OSX in case that matters (some sort of PHP config thing maybe?). Any suggestions?

    Read the article

  • RoR app running on mongrel development but not production

    - by ANaimi
    Hello all, This is my first stab at Ruby on Rails. Just deployed a very simple app to Heroku. The thing is that my app runs flawlessly on mongrel development; When I run it with "mongrel_rails start -e production" however, I get the error "We're sorry, but something went wrong." For the life of me, I couldn't debug this. Heroku logs is not returning anything, the Exceptional addon in Heroku is not returning anything, and I cannot find mongrel.log on my Windows machine (when I run mongrel using: mongrel_rails start -e production -d" I'm using Rails 2.3.5 and sqlite3 with bundler to pack my gems. I was told that probably rails is not booting up correctly. I can't find any other way to diagnose this. Any ideas? Thanks, ANaimi

    Read the article

  • Changing UINavigationBar font in Swift

    - by dcgoss
    I have a UINavigationBar with a title in the middle. I have added a custom font ("Comic_Andy.ttf") to my app (I have checked info.plist to make sure it's listed, and I have checked the Copy Bundle Resources to make sure it has been added), and I would like the title of the UINavigationBar to be displayed in that font. From what I can gather it seems as though I'm supposed to use this in my ViewController: myNavigationBar.titleTextAttributes = [NSFontAttributeName: UIFont(name: "Comic_Andy", size: 22)] I placed that method in the viewDidLoad function of the ViewController. I have also tried this in the didFinishLaunchingWithOptions function of the AppDelegate: UINavigationBar.appearance().titleTextAttributes = [NSFontAttributeName: UIFont(name: "Comic_Andy", size: 22)] I am programming in Swift, in XCode 6 Beta 6. Many resources regarding this task have mentioned using a method called setTitleTextAttributes, which is nowhere to be seen. I can't figure it out for the life of me - I've probably spent close to 3 hours on it by now - I have checked every StackOverflow answer, every website, so please do not mark this as a duplicate. Many thanks in advance!

    Read the article

  • Making form submissions unique using PHP and HTML

    - by canadiancreed
    Hello all I'm currently developing a page where the user fills out a form, and when submitted they are taken to the next page. When on the next page, I want to have it so that if the user went back to the previous page using the back button, or hit refresh, the submission will not be saved into the DB. Now I recall reading somewhere that if you had a way to make each submission unique, this issue is averted, but after screwing around for hours on end, for the life of me I cannot recall how this could be done (using PHP), so long story short has anyone ran into this, and if so, what was your solution?

    Read the article

  • MSBuild Starter Kits - i.e. Copy and just start modding...

    - by vdh_ant
    Hi guys Just wondering if anyone knows if there are any MSBuild starter kits out there. What I mean by starter kits is that from the looks of it most builds to kinda the same sort of steps with minor changes here and there (i.e. most builds would run test, coverage, zip up the results, produce a report, deploy etc). Also what most people in general want from a CI build, test build, release build is mostly the same with minor changes here and there. Now don't get me wrong i think that most scripts are fairly different in the end. But I can't help but think that most start out life being fairly similar. Hence does anyone know of any "starter kits" that have like a dev/CI/test/release build with the common tasks that most people would want that you can just start changing and modifying? Cheers Anthony

    Read the article

  • Cant set drop down list selected value in page load

    - by Ben
    Hi, I'm trying to set the selected value of a ddl during page load ie. before databind. This causes "selected value does not exist" errors. So I force a databind, and add a new element if it does not exist in the data source. However it looks like when the databind is performed later in the page lifecycle that my added element(s) are removed/overwritten. Am I setting the values in the wrong part of the life cycle? what I'm doing seems rather hackish and I think im going about this the wrong way... is there a better way to do this?

    Read the article

  • What's the VB.NET equivalent of this C# code for wiring up and declaring an event?

    - by Ben McCormack
    I'm working on a tutorial to build a media player in Silverlight and am trying to wire up an EventHandler to the timer.Tick event of a DispatchTimer object so that the time of the video is synced with a Slider object. The sample code is in C# and I can't for the life of me figure out the proper syntax in VB.NET with RaiseEvent and/or Handles to wire up the event. Below is the relevant C# code. I'll include comments on where I'm getting stuck. private DispatchTimer timer; public Page() { //... timer = new DispatchTimer(); timer.Interval = TimeSpan.FromMilliseconds(50); timer.Tick += new EventHandler(timer_Tick); // <== I get stuck here b/c // I can't do "timer.Tick += ..." in VB.NET } void timer_Tick(object sender, EventArgs e) { if (VideoElement.NaturalDuration.TimeSpan.TotalSeconds > 0) { sliderScrubber.Value = VideoElement.Position.TotalSeconds / VideoElement.NaturalDuration.TimeSpan.TotalSeconds; } }

    Read the article

  • How much do politics/office intrigue interfere with your day to day tasks at work?

    - by Michael Dorgan
    I'm currently blessed to be employed at a location where politics are pretty much non-existant and management overhead is nearly nil. As I've only worked at this one location for my entire, lengthy career, I have very little frame of reference outside of an occasional Dilbert comic or offhand comment from others about just how bad office politics and management interference get in the way of getting your code done elsewhere. While I'm not actively looking for a new job, this one point has made me quite reluctant to even look seriously elsewhere. My question is, just how much are politics a way of life in larger companies - in or out of the game industry and how much does it affect your day to day satisfaction?

    Read the article

  • Rails Model multiple column uniqueness

    - by Jty.tan
    I am making a Viewer model with belongs_to :users belongs_to :orders that joins the models Users and Orders with a :has_many :through => :viewers. And the Viewer model has the attributes of user_id and order_id. How would I set it up so that new viewers are only accepted if both user_id and order_id are unique in the same row? I remember in MySQL being able to do so with a flag (although I can't for the life of me remember what it was), but I'm not sure how to do it with Rails. Can I do something like (for Viewer.rb) validates_uniqueness_of :user_id, :scope => :order_id?

    Read the article

  • Keep a reference to an NSThread around and message its objects?

    - by RickiG
    Hi I am a bit uncertain on how to do this: I start a "worker-thread" that runs for the duration of my apps "life". [NSThread detachNewThreadSelector:@selector(updateModel) toTarget:self withObject:nil]; then - (void) updateModel { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; BackgroundUpdate *update = [[BackgroundUpdate alloc] initWithTimerInterval:5]; [[NSRunLoop currentRunLoop] run]; //keeps it going 'forever' [update release]; [pool release]; } Now the thread "wakes" up every 5 seconds(initWithTimerInterval) to see if there are any tasks it can do. All the tasks in the BackGroundUpdate Class are only time dependent for now. I would like to have a few that were "event dependent". e.g. I would like to call the Background Object from my main thread and tell it to "speedUp", "slowDown", "reset" or any method on the object. To do this I guess I need something like performSelectorOnThread but how to get a reference to the NSthread and the Background Object?

    Read the article

  • In a web app, is it wise to give log files ".txt" suffix?

    - by Pekka
    I am building a logging mechanism in a web application. Being a Windows man, I tend to give files with textual content the .txt ending. The suffix is automatically registered to be opened in a text editor in any Windows environment, and is just a nice convention. The app is going to be redistributed, and running mostly on Linux, though. The Linux convention for log files is .log. Is there any good reason on the Linux end, besides convention, why I should use .log? Any filters, real-life applications that could become relevant and that will work only with a .log suffix? Or can I merrily call it error_log.txt?

    Read the article

  • Mobile web on nokia devices not displaying centain elements

    - by Jan de Jager
    So i have a site which is rendered with our in-house portal engine. It resizes images and adjusts style-sheets automatically in real-time. Issue is that some html elements are inexplicably disappearing due to what only can be described as HTML compatibility. But the problem is not consistent. And only seems to be an issue on some nokia devices. I have tried to install the Nokia Mobile Browser Emulator... but its the worst piece of software i have seen in my life... after 4 hours of installing and uninstalling different versions of JRE, i still can't get it to install. EDIT: Problem now residing at http://wiseguy.mobi/?PageID=657

    Read the article

  • HTML5: dragover(), drop(): how get current x,y coordinates?

    - by Pete Alvin
    How does one determine the (x,y) coordinates while dragging "dragover" and after the drop ("drop") in HTML5 DnD? I found a webpage that describes x,y for dragover (look at e.offsetX and e.layerX to see if set for various browsers but for the life of me they ARE NOT set). What do you use for the drop(e) function to find out WHERE in the current drop target it was actually dropped? I'm writing an online circuit design app and my drop target is large. Do I need to drop down to mouse-level to find out x,y or does HTML5 provided a higher level abstraction?

    Read the article

  • Best computer-science universities in Europe?

    - by Tom
    I am in 11th grade and only one year left when I finish my school. I am sure I want to dedicate my life to programming. In my country the education's level is not so high as in Europe, so I want to emigrate and study not just for a diploma, but for knowledge too. So, what universities would you suggest me which has subject Computer-Science? I prefer web programming. Please do not delete this message though it is quite offtopic, but it's the best place for me to get suggestions from advanced programmers who have already finished their university. And I hope here comes also teenagers who can make the best decision choosing university. Thank you. Please read the whole my message before voting to close this thread, thanks.

    Read the article

  • Genetic programming in c++, library suggestions?

    - by shuttle87
    I'm looking to add some genetic algorithms to an Operations research project I have been involved in. Currently we have a program that aids in optimizing some scheduling and we want to add in some heuristics in the form of genetic algorithms. Are there any good libraries for generic genetic programming/algorithms in c++? Or would you recommend I just code my own? I should add that while I am not new to c++ I am fairly new to doing this sort of mathematical optimization work in c++ as the group I worked with previously had tended to use a proprietary optimization package. We have a fitness function that is fairly computationally intensive to evaluate and we have a cluster to run this on so parallelized code is highly desirable. So is c++ a good language for this? If not please recommend some other ones as I am willing to learn another language if it makes life easier. thanks!

    Read the article

  • Data scheme question

    - by Matt
    I am designing a data model for a local city page, more like requirements for it. So 4 tables: Country, State, City, neighbourhood. Real life relationships is: Country owns multiple State which owns multiple cities which ows multiple neighbourhoods. In the data model: Do we link these with FK the same way or link each with each? Like in each table there will even be a Country ID, State ID, CityID and NeighbourhoodID so each connected with each? Other wise to reach neighbourhood from country we need to join 2 other tables in between? There are more tables I need to maintain for IP addess of cities, latitude/longitude, etc.

    Read the article

  • Desktop application validity

    - by Umesh
    I am creating a desktop application using AIR. In that application user is allowed to download some resources which have life span of 2 days. I am storing the date when the user is downloaded. But how can i check whether the date is passed 2 days or not? Right now I am checking with the current system date.But when the user changes the system date to back, it will start to work which i dont want. How the desktop applications say like flex builder and all having trial period.? How are they tracking the dates remaining? ~Umesh

    Read the article

  • jQuery/Asp.Net mvc username lookup

    - by MD_Oppenheimer
    OK, for the life of me I can't uderstand why the follwing code is always returning false?? I have debugged with firefox to see what going on, but the function seems to always return false even when the condition username taken is 0(false), here is the jquery code: function CheckAvailability() { showLoader(); $.post("/Account/CheckUsernameAvailability", { userName: $(profile_username).val() }, function(data) { var myObject = eval('(' + data + ')'); var newid = myObject; if (newid == 0) { profile_username_error.removeClass("field_not_valid"); profile_username_error.addClass("field_valid"); $("#validUserName_msg").html("<font color='green'>Available</font>") return true; } else { profile_username_error.addClass("field_not_valid"); profile_username_error.removeClass("field_valid"); $("#validUserName_msg").html("<font color='red'>Taken</font>") return false; } }); } I'm using the /Account/CheckUsernameAvailability to check if a given name is take or not, it not taken(0) should return true, false otherwise.

    Read the article

  • php.ini not being read with windows 7 installation

    - by Kyle
    I have installed php successfully on a Windows 7 machine but I can not for the life of me get it to read the php.ini file. I have uncommented out the line for php to use mysql and when I run phpinfo(), it never shows up. I have checked to make sure there is only one php.ini file on my entire c:\ drive and it's sitting in my c:\windows folder. has anyone else run into this and know of a solution to get php to read the .ini so that I can enable some extensions (mysql etc)?

    Read the article

  • Designing software interface for various screen sizes

    - by Tower
    Hi, Nowadays we have screens like 1920x1200 and 1680x1050 in popular use and some even use 2560x1600 resolution while some older systems still rely on a 800x600 resolution. I am writing a software that looks good on a 1680x1050, but too small on a 1920x1200 and too large on a 1024x768. Do you have suggestions how to go for designing an application for various screen sizes? Things were a lot simpler before when we had little differences in resolutions, but now it seems there's no good way of handling this. I know this question is more about designing / layout than programming, but I bet this is more or less part of programmers life so I made this post here.

    Read the article

  • Unable to locate the Bug

    - by tzenes
    I was recently on The Daily WTF when I came across this old post. In it the author mentions that one of the programmers changed this code: int main (int argc, char **argv) { int x; char data_string[15]; ... x = 2; strcpy(data_string,"data data data"); ... } To this code: int main (int argc, char **argv) { int x = 2; char data_string[15] = "data data data"; ... } The author goes on to mention: [the coder] changed every single variable to be initiated on the stack For the life of me I cannot see how this change could be harmful, and I am worried that it is a lapse in my C knowledge. What is the WTF?

    Read the article

  • Gruber URL Regex tweak to capture "domain.com"

    - by mootymoots
    I found an updated version of John Gruber's regex for url matching in this post by user GianPac, which states it's been adapted to recognize url without protocol or the www part: (?i)\b((?:[a-z][\w-]+:(?:/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.-]+[.][a-z]{2,4}/?)(?:[^\s()<]+|(([^\s()<]+|(([^\s()<]+)))))(?:(([^\s()<]+|(([^\s()<]+))))|[^\s`!()[]{};:'\".,<?«»“”‘’])) Whilst this works in most cases, I found it does not match "google.com". It does match "google.comm" and "google.co.uk", so this must be a small oversight. The trouble is, I literally hate regex. It's the bane of my life. I just want to try and tweak this one more time to allow for "google.com" - can anyone throw me a pointer? I (think) it's something to do with this part of the code: +[.][a-z]{2,4}/?) ?

    Read the article

  • Disabling mouse movement and clicks altogether in c#

    - by ThaNerd
    At work, i'm a trainer. I'm setting up lessons to teach people how to "do stuff" without a mouse... Ever seen people click "login" textbox, type, take the mouse, click "password", type their password, then take the mouse again to click the "connect" button beneath ? So i'll teach them how to do all that without a mouse (among many other things, of course) At the end of the course, i'll make them pass a sort of exam. So i'm building a little wizard based app in which i present some simili-real-life examples of forms to fill in, but i want to disable their mouse programatically while they do this test. However, further in the wizard, i'll have to let them use their mouse again. Is there a -- possibly easy -- way to just disable the mouse for a while, and re-enable it later on? I'm on C# 2.0, programming under VC# 2k5, if that matters

    Read the article

  • How do you get "in the zone"?

    - by Wayne Werner
    Hi, I've just started my first real programming job and am pleased to discover that this is exactly what I want to do for the rest of my life. When it comes round to ~1 hour before it's time to go home and I think "Man, do I have to go home already?" I'd say that's A Good Thing(tm). One thing I've discovered though is that it takes a little while for my brain to get "in gear" or "in the Zone", so I'm curious what other folks do to get programming at their prime. My current flow is when I get here I visit SO and look at the interesting problems - I find it helps get my brain moving. After 20-30 minutes I start looking at my code/specs/etc to decide what I want/need to work on first. So how do you get started?

    Read the article

< Previous Page | 89 90 91 92 93 94 95 96 97 98 99 100  | Next Page >