Search Results

Search found 20869 results on 835 pages for 'things i hate'.

Page 98/835 | < Previous Page | 94 95 96 97 98 99 100 101 102 103 104 105  | Next Page >

  • Best practice: How to persist simple data without a database in django?

    - by Infinity
    I'm building a website that doesn't require a database because a REST API "is the database". (Except you don't want to be putting site-specific things in there, since the API is used by mostly mobile clients) However there's a few things that normally would be put in a database, for example the "jobs" page. You have master list view, and the detail views for each job, and it should be easy to add new job entries. (not necessarily via a CMS, but that would be awesome) e.g. example.com/careers/ and example.com/careers/77/ I could just hardcode this stuff in templates, but that's no DRY- you have to update the master template and the detail template every time. What do you guys think? Maybe a YAML file? Or any better ideas? Thx

    Read the article

  • I've failed at PHP several times. Is Ruby the Cure? [closed]

    - by saltcod
    Extremely, extremely subjective question here, but its something I've been struggling with for quite a while. I've seriously tried to become a reasonable PHP coder for the past several years. But I've really failed every time. I hate to describe myself as a beginner, b/c I've been designing websites (using WordPress, Drupal, etc) for years, but still I just can't seem get better at programming. Could it be that I have some kind of allergy to PHP? I went through Chris Pine's awesome into to Ruby about a week ago (for about the fifth time), and though it did all all seem much clearer to me than PHP, I wondered if I was just switching languages to find an easy way out? The things I struggle with in PHP all seem elementary—when to use a function, how to return database queries in foreach/while statements, when to turn those queries into reusable functions, adding arguments to functions, etc, etc. And all the OOP stuff that I keep seeing these days just files over my head. I guess my question(s) are: Am I going about learning how to program in the wrong way? Do I have some aversion to PHP that's preventing me from catch on? If I keep pushing at Ruby/Rails, will it just eventually 'click'. Or, the one I fear, am I just unlikely to ever be a programmer? Honesty appreciated. Terry

    Read the article

  • Am i using too much jquery? When i'm crossing the line?

    - by Andrea
    Lately i find myself using jquery and javascript a lot, often to do the same things that i did before using css. For example, i alternate table rows color or create buttons and links hover effects using javascript/jquery. Is this acceptable? Or should i keep using css for these kind of things? So the real question is: When i'm using too much jquery? How can i understand when i'm crossing the line? Thanks.

    Read the article

  • How to Print reports in Silvelright 4

    - by lightmeetsdark
    I am wondering if there is anything built in to Silverlight, or possibly c# to allow for printing reports? I'd be happy with any number of methods: exporting files to a pdf format and printing from there, exporting as a text document of some sort and printing from there, or just simply showing the print dialog from the web application itself. I know there are ways to do this in C#, but the c# code-behind is different for many things in Silverlight applications and I can't seem to find anything that will work. So if anyone has any ideas on things I could try it would be very much appreciated! Thank you!

    Read the article

  • C# Timer counter in xx.xx.xx format

    - by Darkshadw
    I have a counter that counts up every 1 second and add 1 to an int. Question How can I format my string so the counter would look like this: 00:01:23 Instead of: 123 Things I've tried Things I've tried so far: for (int i = 0; i < 1; i++) { _Counter += 1; labelUpTime.Text = _Counter.ToString(); } My timer's interval is set to: 1000 (so it adds 1 every second). I did read something about string.Format(""), but I don't know if it is applicable. Thanks if you can guide me through this :D!

    Read the article

  • What is so great about Visual Studio?

    - by Paperflyer
    In my admittedly somewhat short time as programmer, I have used many development environments on many platforms. Most notably, Eclipse/Linux, XCode/OSX, CLI/editor/Linux, VisualDSP/Blackfin/Windows and MSVC/Windows. (I used each one for several months) There are neat features in pretty much all of them. But somehow, I just can't find any in MSVC. Then again, so many people really seem to like it, so I am probably missing something here. So please tell me: What is so great about Visual Studio? Things I like: Refactoring tools in Eclipse Build error highlighting in XCode and Eclipse Edit-all-in-Scope in XCode Profiler in XCode Flexibility of Eclipse and CLI/editor Data plotting in VisualDSP Things I don't like Build error display in MSVC (not highlighted in code) Honestly, this is not meant to be a rant. Of course I am a Mac-head and biased as hell, but I have to use MSVC on the job, so I really want to like it.

    Read the article

  • Using an ActiveX object from an Outlook hosted webpage - possible?

    - by Nic Wise
    I'm trying to do the following: We have an outlook plugin, written in .NET (and C++). It does various things, and is manually installed on the end users machines (usually via AD deployment or similar) We are changing our search to use a webpage-based search, but from within outlook. That part is ok, however we want to communicate from the webpage to the surrounding outlook application. We can call into outlook by exposing an ActiveX object from our plugin, however we get security warnings, even if it's signed and marked as safe for scripting. Is this even possible? Has anyone done it? Anyone have a better way of doing it? We only need to pass in a small amount of data (a message id), and only from the webpage to outlook [update]: This is the error: automation server can't create object. We can get around it a bit by turning things off in IE, but thats not a good way to do it! Thanks

    Read the article

  • Using Multiple Databases

    - by sergiuoala
    A company is hired by another company for helping in a certain field. So I created the following tables: Companies: id, company name, company address Administrators: (in relation with companies) id, company_id, username, email, password, fullname Then, each company has some workers in it, I store data about workers. Hence, workers has a profession, Agreement Type signed and some other common things. Now, the parent tables and data in it for workers (Agreement Types, Professions, Other Common Things) are going to be the same for each company. Should I create 1 new database for each company? Or store All data into the same database? Thanks.

    Read the article

  • How to deal with the Hibernate hql multi-join query result in an Object-Oriented Way?

    - by EugeneP
    How to deal with the Hibernate hql multi-join query result in an Object-Oriented Way? As I see it returns a list of Objects. yes, it is tricky and only you who write the query know what should the query return (what objects). But are there ways to simplify things, so that it returned specific objects with no need in casting Object to a specific class according to its position in the query ? Maybe Spring can simplify things here? It has the similar functionality for JDBC, but I don't see if it can help in a similar way with Hibernate.

    Read the article

  • Ruby forwarding method calls

    - by JP
    I have an instance of a master class which generates instances of a subclass, these subclasses need to forward some method calls back to the master instance. At the moment I have code looking something like this, but it feels like I should be able to do the same thing more efficiently (maybe with method_missing?) class Master def initalize(mynum) @mynum = mynum end def one_thing(subinstance) "One thing with #{subinstance.var} from #{@mynum}" end def four_things(subinstance) "Four things with #{subinstance.var} from #{@mynum}" end def many_things(times,subinstance) "#{times} things with #{subinstance.var} from #{@mynum}" end def make_a_sub(uniqueness) Subthing.new(uniqueness,self) end class Subthing def initialize(uniqueness,master) @u = uniqueness @master = master end # Here I'm forwarding method calls def one_thing master.one_thing(self) end def four_things master.four_things(self) end def many_things(times) master.many_things(times,self) end end end m = Master.new(42) s = m.make_a_sub("very") s.one_thing === m.one_thing(s) s.many_things(8) === m.many_things(8,s) I hope you can see what's going on here. I would use method_missing, but I'm not sure how to cope with the possibility of some calls having arguments and some not (I can't really rearrange the order of the arguments to the Master methods either) Thanks for reading!

    Read the article

  • How does ‘Servers’ view work underlying in Eclipse?

    - by Michael Lu
    ‘Servers’ is built-in view in Eclipse. We could integrate jee server into Eclipse easily. It could start/stop server both in normal and debug modes. Moreover, we could even set timeout and deployment path, things like that. Various types of server tomcat, jboss, websphere are supported, no intrusive to server. I am just curious about how these cool things happen behind the scene. The complete mechanism is large and complex, so I just want to know general mechanism about it, an article also could be fine for me. Thank you!

    Read the article

  • What do you wish you could've learned sooner?

    - by Industrial
    What things, methods, workflows, etc. can you not live without today and wish you had learned of a long time ago? For example, learning some basic Ubuntu and using my debugger properly in the IDE have made a huge difference to me and are together probably the two things that I most wish I had done a long time ago. Using a debugger just seems like common sense now to many of us, but to those that are in a early stage of their career it might not. (I'm a good example of that.)

    Read the article

  • Declaration and initialization of local variables - what is most C++ like?

    - by tuergeist
    Hi, I did not find any suitable questions answered yet, so I'd like to know what is "better" C++ style in the mean of performance and/or memory. Both codes are inside a method. The question is: When to declare long prio? And what are the implications? Code 1 while (!myfile.eof()) { getline(myfile, line); long prio = strtol(line); // prio is declared here // put prio in map... // some other things } Code 2 long prio; // prio is declared here while (!myfile.eof()) { getline(myfile, line); prio = strtol(line); // put prio in map... // some other things }

    Read the article

  • Best practices to keep up a diverging branch of code

    - by JS_is_bad
    I'm in a situation where some minor patches I've submitted to an open-source project were ignored or explicitly not accepted. I consider them useful, but more important is that I need the functionality they implement. I don't want to push my ideas and suggestions anymore to the main contributors, because I don't want to turn this into an ego issue. I've decided that my best bet would be just to use what I wrote for my own purposes. I don't want to fork the whole source code tree because I like how things are generally working, I'm just not happy with details. But I do realize that the project will evolve and I would like to use the new features that will eventually appear. I understand that I'll have to merge all new things into my own source tree. Are there any best practices for this scenario?

    Read the article

  • Dynamically changing databases in SQL Server 2000

    - by spuppett
    At work we have a number of databases that we need to do the same operations on. I would like to write 1 SP that would loop over operations and set the database at the beginning of the loop (example to follow). I've tried sp_executesql('USE ' + @db_id) but that only sets the DB for the scope of that stored procedure. I don't really want to loop with hard coded database names because we need to do similar things in many different places and it's tough to remember where things need to change if we add another DB. Any thoughts Example: DECLARE zdb_loop CURSOR FAST_FORWARD FOR SELECT distinct db_id from DBS order by db_id OPEN zdb_loop FETCH NEXT FROM zdb_loop INTO @db_id WHILE @@FETCH_STATUS = 0 BEGIN USE @db_id --Do stuff against 3 or 4 different DBs FETCH NEXT FROM zdb_loop INTO @db_id END CLOSE zdb_loop DEALLOCATE zdb_loop

    Read the article

  • Refactoring FAT client legacy application

    - by Paul
    I am working on a fat client legacy C++ application which has a lot of business logic mixed in with the presentation side of things. I want to clean things out and refactor the code out completely, so there is a clear seperation of concerns. I am looking at MVC or some other suitable design pattern in order to achieve this. I would like to get recommendations from people who have walked this road before - Do I use MVP or MVC (or another pattern)? What is/are the best practices for undertaking something like this (i.e. useful steps/checks) ?

    Read the article

  • question about Littles Law

    - by davit-datuashvili
    I know that Little's Law states (paraphrased): the average number of things in a system is the product of the average rate at which things leave the system and the average time each one spends in the system, or: n=x*(r+z); x-throughput r-response time z-think time r+z - average response time now i have question about a problem from programming pearls: Suppose that system makes 100 disk accesses to process a transaction (although some systems require fewer, some systems will require several hundred disk access per transaction). How many transactions per hour per disk can the system handle? please help

    Read the article

  • WPF/C# - Sometimes my dropdowns/datepickers will stop functioning?

    - by BlargINC
    Q: Where should I check to track this down? Issue: Opening a view model in my application sometimes makes dropdowns/datepickers nonfunctional. ie. dropdown won't drop and the datepicker calendar won't come up I suspect a binding issue but don't see one. Dropdowns have normal things like strings, numbers. One drop has a list of mini views. Datepickers are bound to nullable dates set in the constructor of the viewmodel. Note: These same things work in other viewmodels/views. I can paste code, I'm just not sure what code is relevant here. Thank you for helping me :)

    Read the article

  • Sometimes my dropdowns/datepickers will stop functioning?

    - by BlargINC
    Q: Where should I check to track this down? Issue: Opening a view model in my application sometimes makes dropdowns/datepickers nonfunctional. ie. dropdown won't drop and the datepicker calendar won't come up I suspect a binding issue but don't see one. Dropdowns have normal things like strings, numbers. One drop has a list of mini views. Datepickers are bound to nullable dates set in the constructor of the viewmodel. Note: These same things work in other viewmodels/views. I can paste code, I'm just not sure what code is relevant here.

    Read the article

  • Is object clearing/array deallocation really necessary in VB6/VBA (Pros/Cons?)

    - by Oorang
    Hello, A lot of what I have learned about VB I learned from using Static Code Analysis (Particularly Aivosto's Project Analyzer). And one one of things it checks for is whether or not you cleared all objects and arrays. I used to just do this blindly because PA said so. But now that I know a little bit more about the way VB releases resources, it seems to me that these things should be happening automatically. Is this a legacy feature from pre VB6, or is there a reason why you should explicitly set objects back to nothing and use Erase on arrays?

    Read the article

  • Growing your VirtualBox Virtual Disk

    - by Fat Bloke
    Don't you just hate it when this happens: Fortunately, if you're running inside VirtualBox, you can resize your virtual disk and magically make your guest have a bigger disk very easily. There are 2 steps to doing this... 1. Resize the virtual disk Use the VBoxManage command line tool to extend the size of the Virtual Disk, specifying the path to the disk and the size in MB: VBoxManage modifyhd <uuid>|<filename> [--type normal|writethrough|immutable|shareable| readonly|multiattach] [--autoreset on|off] [--compact] [--resize <megabytes>|--resizebyte <bytes>]   If you booted up your guest at this point, the extra space is seen as an unformatted area on the disk, like this: So we now need to tell the guest about the extra space available. 2. Extend the guest's partition to use the extra space How you do this step depends on you guest OS type and the tools you have available. Linux guests often include the excellent gparted partition editor, whereas Windows 7 and 8 provide the Computer Management tool which can resize partitions. Unfortunately, my Windows XP vm has no such tool. But I do have a couple of other options: Most Linux installable .isos include the aforementioned gparted tool, so I could simply attach, say, an Ubuntu.iso as a Virtual CD/DVD in my Windows XP vm and boot off that. Then use gparted to extend the Windows XP partition, before finally rebooting. But I took another route and attached my resized virtual disk to a Windows Server 2012 vm I had lying around. Then I used the Computer Management tool in Windows Server 2012 to extend the partition of the Windows XP disk, before shutting down, unplugging the disk and reattaching to my Windows XP vm. (Note that if your vm's use different disk controllers, Windows will check the disks on booting). When I finally boot up my Windows XP guest I see the available disk space and all is well. At least until the next time - FB 

    Read the article

  • Users and roles in context

    - by Eric W.
    I'm trying to get a sense of how to implement the user/role relationships for an application I'm writing. The persistence layer is Google App Engine's datastore, which places some interesting (but generally beneficial) constraints on what can be done. Any thoughts are appreciated. It might be helpful to keep things very concrete. I would like there to be organizations, users, test content and test administrations (records of tests that have been taken). A user can have the role of participant (test-taker), contributor of test material or both. A user can also be a member of zero or more organizations. In the role of participant, the user can see the previous administrations of tests he or she has taken. The user can also see a test administration of another participant if that participant has given the user authorization. The user can see test material that has been made public, and he or she can see restricted content as a participant during a specific administration of a test for which that user has been authorized by an organization. As a member of an organization, the user can see restricted content in the role of contributor, and he or she might or might not also be able to edit the content. Each organization should have one or more administrators that can determine whether a member can see and edit content and determine who has admin privileges. There should also be one or more application-wide superusers that can troubleshoot and solve problems. Members of organizations can see the administrations of tests that the participants concerned have authorized them to see, and they can see anonymous data if no authorization has been given. A user cannot see the test results of another user in any other circumstances. Since there are no joins in the App Engine datastore, it might be necessary to have things less normalized than usual for the typical SQL database in order to ensure that queries that check permissions are fast (e.g., ones that determine whether a link is to be displayed). My questions are: How do I move forward on this? Should I spend a lot of time up front in order to get the model right, or can I iterate several times and gradually roll in additional complexity? Does anyone have some general ideas about how to break things up in this instance? Are there any GAE libraries that handle roles in a way that is compatible with this arrangement?

    Read the article

< Previous Page | 94 95 96 97 98 99 100 101 102 103 104 105  | Next Page >