Daily Archives

Articles indexed Thursday January 6 2011

Page 9/36 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • How can I limit CD drive speed while on the live CD to avoid drive noise?

    - by iugamarian
    I sometimes disconect my harddisks for the weeks while only using the internet and I use the Ubuntu Live CD. But every time it needs something while in live desktop it accelerates and makes a lot of noise, also the acceleration takes too long. I want lower drive speed than acceleration lags, because acceleration lags stop me completly exactly when I need something. How can I lower the CD drive speed, say to maximum 16x, without restarting? I can't restart because I only use the CD drive, no harddisks, no flash disks, no network disks. Edit: No USB drives. Setcd does not work for the live session.

    Read the article

  • How can I use a .html file as desktop background/wallpaper?

    - by dudealfred
    I have one of those underpowered netbooks with Lubuntu. I also have an iPod Touch. I'd like the best of both worlds. So I would like to create an active html wallpaper with beautiful little squared icons to launch my webapps through Chromium/Firefox. I've read a bit, but it looks like there isn't really anything that would allow for that. Why? Does anyone have any other alternatives (apart from buying an iPad)? :)

    Read the article

  • SEO: Is promoting your backlinks a good strategy for improving search results for my site's name?

    - by user4394
    I run a website that's been around for about three years in the sports space. I am successfully ranking well for targeted keywords, but searching for the name of my site itself returns very poor results - it shows my site, its FB/Twitter, and then 15 pages of unrelated spam that happen to contain two words that, when combined, form my website's name. After that, my backlinks begin to show up spordically. As far as I can tell, I simply don't have enough backlinks and the backlinks I do have are ranked worse than the spam. (Site Explorer lists 200 external links to any page on our domain and 20 external links directly to the front page). To counter this, my strategy is to promote my backlinks so they get a better page rank than the spam. Does that make sense? Am I going in the right direction or should I just focus on getting more backlinks pointing directly to my site? Thanks in advance and I'd be happy to answer any questions I can (without giving away my site of course).

    Read the article

  • NUll exception in filling a querystring by mocing framework

    - by user564101
    There is a simple controller that a querystring is read in constructor of it. public class ProductController : Controller { parivate string productName; public ProductController() { productName = Request.QueryString["productname"]; } public ActionResult Index() { ViewData["Message"] = productName; return View(); } } Also I have a function in unit test that create an instance of this Controller and I fill the querystring by a Mock object like below. [TestClass] public class ProductControllerTest { [TestMethod] public void test() { // Arrange var querystring = new System.Collections.Specialized.NameValueCollection { { "productname", "sampleproduct"} }; var mock = new Mock<ControllerContext>(); mock.SetupGet(p => p.HttpContext.Request.QueryString).Returns(querystring); var controller = new ProductController(); controller.ControllerContext = mock.Object; // Act var result = controller.Index() as ViewResult; // Assert Assert.AreEqual("Index", result.ViewName); } } Unfortunately Request.QueryString["productname"] is null in constructor of ProductController when I run test unit. Is ther any way to fill a querystrin by a mocking and get it in constructor of a control?

    Read the article

  • creating an array of objects in c++

    - by tim22
    I'm trying to create an array of objects in c++. I'm creating a employee object, from my constructor in my company class here: employee obj(int tempIdNum, double tempBase, double tempSales, double tempRate); emp[tempcount]=obj; (this doesn't work?) Emp is the name of the array which is defined here, located in my company h file. Employee emp[4]; more code: Company::Company(string name, string fileName){ string str; int tempcount; int tempIdnum; double tempBase; double tempSales; double tempRate; double num; double arr[16]; this->name=name; //Commission temp; ifstream readFile; readFile.open("fileName"); int inc=0; while(tempcount<4){ for(int i=0+inc; i<4+inc; i++){ readFile>>num; arr[i-inc]=num; } tempIdnum=(int)(arr[0]); tempBase=arr[1]; tempSales=arr[2]; tempRate=arr[3]; Employee obj(int tempIdNum, double tempBase, double tempSales, double tempRate); emp[tempcount]=obj; inc+=4; tempcount++; } readFile.close(); } Here is some more from my h file #include <string> include "Commission.h" using namespace std; ifndef Company_H define Company_H class Company{ private: string name; //name of company Employee emp[4]; //array of payrool info about 4 commission employees int numEmp; //number of employees public: Company(); Company(string name, string fileName); ~Company(); string getName(); Commission getEmployee(int element); int getNumEmp(); }; endif enter code here Does not compile: 46 E:\exercise2\Company.cpp no match for 'operator=' in '((Company*)this)-Company::emp[tempcount] = obj'

    Read the article

  • PHP imap_search not detecting all messages in gmail inbox

    - by Steve
    When I run a very simple imap_search on my GMail inbox, the search returns less messages than it should. Here is the script that anyone with a GMail account can run. $host = '{imap.gmail.com:993/imap/ssl}'; $user = 'foo'; $pass = 'bar'; $imapStream = imap_open($host,$user,$pass) or die(imap_last_error()); $messages = imap_search($imapStream,"ALL"); echo count($messages); imap_close($imapStream); This returns 39 messages. But, I've got 100 messages in my inbox, some in conversations, some forwarded from another account (SquirrelMail, FWIW). Can anyone duplicate these results, and/or tell me what's going on? Other server strings I've tried, all returning the same results: {imap.gmail.com:993/imap/ssl/novalidate-cert} {imap.gmail.com:993/imap/ssl/novalidate-cert}INBOX {imap.gmail.com:993/imap/ssl}INBOX GMail's IMAP feature support: http://mail.google.com/support/bin/answer.py?hl=en&answer=78761

    Read the article

  • General JDBC Setup

    - by AeroDroid
    So I have a MySQL database set up on a Debian server and it works fine from a phpMyAdmin client. I'm currently working on a project to write a Java server that would be able to use the MySQL database that is already on this server through a JDBC connection. I've looked at many tutorials and documentations but all of them seem to just explain how to do client-side code, but I have yet to figure out how to even successfully open a JDBC connection to the server. As far as I am concerned, I believe that program has the drivers properly set up because it's not crashing anymore (I simply direct the Java Build Path of my program to the Connector/J provided by MySQL). As far as my program goes, this is what it looks like... import java.sql.*; public class JDBCTest { public static void main(String[] args) { System.out.println("Started!"); try { DriverManager.registerDriver(new com.mysql.jdbc.Driver()); System.out.println("Driver registered. Connecting..."); Connection conn = DriverManager.getConnection("jdbc:mysql://localhost/", "root", "password"); System.out.println("Connected!"); conn.close(); } catch (SQLException e) { System.out.println("Error!"); e.printStackTrace(); } } } This is what's printed... Started! Driver registered. Connecting... It's as if the DriverManager.getConnection(String) just freezes there. I'm sure this is a problem with the server because when I intentionally misspell localhost, or an IP address, the program crashes within 20 seconds. This just hangs there forever. Sorry about this wall of text, but my final question is if anyone has any information what I should do or install on the server to get this to work? Thank you so much!

    Read the article

  • how to sort a treemap using bubble sort?

    - by Tsuna Sawada
    27527-683 27525-1179 27525-1571 27525-1813 27525-4911 27526-1303 27526-3641 27525-3989 27525-4083 27525-4670 27526-4102 27526-558 27527-2411 27527-4342 this is the list of key where it is declared as string in a map then i want to sort it in ascending order. how can i use a bubble sorting method inside a map? where the value of the key is a list. in order to get : 27525-1179 27525-1571 27525-1813 27525-3989 27525-4083 27525-4670 27525-4911 27526-558 27526-1303 27526-3641 27526-4102 27527-683 27527-2411 27527-4342

    Read the article

  • PPR in tr:selectOneChoice does not work

    - by Nhut Le
    Hi, I have a simple testing page that test my PPR on a selectOneChoice component. when select a value from selectOnechoice 1, the selected value will display on a output label and also reset the selected value and the other selectOneChoice. However, it prints the selected values to the label correctly but it can't set the selected value for the other selectOneChoice. and Here are my page and my value change event method. <tr:form id="nhutForm"> <tr:selectOneChoice id="one" value="#{nhutTestBean.one}" autoSubmit="true" immediate="true" valueChangeListener="#{nhutTestBean.onMyValueChanged}"> <tr:selectItem label="0" value="0"/> <tr:selectItem label="1" value="1"/> <tr:selectItem label="2" value="2"/> <tr:selectItem label="3" value="3"/> </tr:selectOneChoice> <tr:selectOneChoice id="two" value="#{nhutTestBean.two}" partialTriggers="one"> <f:selectItems value="#{nhutTestBean.myList}"/> </tr:selectOneChoice> <tr:outputText id="nhutTextBox" value="hello: #{nhutTestBean.output}" partialTriggers="one"/></tr:form> and my valueChangeEvent method: public void onMyValueChanged(ValueChangeEvent event) { this.setOutput((String)event.getNewValue()); this.setTwo((String)event.getNewValue()); } One thing I realize is that it calls my setTwo twice, the first the set the correct values, but the second time set it to null so that nothing would be selected for the two drop down box. please help. thank you so much.

    Read the article

  • Creating thousands of records in Rails

    - by willCosgrove
    Let me set the stage: My application deals with gift cards. When we create cards they have to have a unique string that the user can use to redeem it with. So when someone orders our gift cards, like a retailer, we need to make a lot of new card objects and store them in the DB. With that in mind, I'm trying to see how quickly I can have my application generate 100,000 Cards. Database expert, I am not, so I need someone to explain this little phenomena: When I create 1000 Cards, it takes 5 seconds. When I create 100,000 cards it should take 500 seconds right? Now I know what you're wanting to see, the card creation method I'm using, because the first assumption would be that it's getting slower because it's checking the uniqueness of a bunch of cards, more as it goes along. But I can show you my rake task desc "Creates cards for a retailer" task :order_cards, [:number_of_cards, :value, :retailer_name] => :environment do |t, args| t = Time.now puts "Searching for retailer" @retailer = Retailer.find_by_name(args[:retailer_name]) puts "Retailer found" puts "Generating codes" value = args[:value].to_i number_of_cards = args[:number_of_cards].to_i codes = [] top_off_codes(codes, number_of_cards) while codes != codes.uniq codes.uniq! top_off_codes(codes, number_of_cards) end stored_codes = Card.all.collect do |c| c.code end while codes != (codes - stored_codes) codes -= stored_codes top_off_codes(codes, number_of_cards) end puts "Codes are unique and generated" puts "Creating bundle" @bundle = @retailer.bundles.create!(:value => value) puts "Bundle created" puts "Creating cards" @bundle.transaction do codes.each do |code| @bundle.cards.create!(:code => code) end end puts "Cards generated in #{Time.now - t}s" end def top_off_codes(codes, intended_number) (intended_number - codes.size).times do codes << ReadableRandom.get(CODE_LENGTH) end end I'm using a gem called readable_random for the unique code. So if you read through all of that code, you'll see that it does all of it's uniqueness testing before it ever starts creating cards. It also writes status updates to the screen while it's running, and it always sits for a while at creating. Meanwhile it flies through the uniqueness tests. So my question to the stackoverflow community is: Why is my database slowing down as I add more cards? Why is this not a linear function in regards to time per card? I'm sure the answer is simple and I'm just a moron who knows nothing about data storage. And if anyone has any suggestions, how would you optimize this method, and how fast do you think you could get it to create 100,000 cards? (When I plotted out my times on a graph and did a quick curve fit to get my line formula, I calculated how long it would take to create 100,000 cards with my current code and it says 5.5 hours. That maybe completely wrong, I'm not sure. But if it stays on the line I curve fitted, it would be right around there.)

    Read the article

  • Write large PDFs with Java sequentially

    - by Benjamin Muschko
    I am looking for a Java library that let's you write large PDFs sequentially with a minimum amount of memory. Most of the libraries I had a look at has to build up the document in memory first before you can actually write it. The problem I have to deal with are OutOfMemoryErrors. It would be great if I could flush the writer programmatically whenever needed e.g. for each page. Does anyone have any recommendations? I need something with a license along the lines of the LGPL (so not the GPL or the Affero GPL that iText uses).

    Read the article

  • Dynamic Like Statement in SQL

    - by Peter McElhinney
    Hey there! I've been racking my brain on how to do this for a while, and i know that some genius on this site will have the answer. Basically i'm trying to do this: SELECT column FROM table WHERE [table][column] LIKE string1 OR [table][column] LIKE string2 OR [table][column] LIKE string3... for a list of search strings stored in a column of a table. Obviously I can't do a like statement for each string by hand because i want the table to be dynamic. Any suggestions would be great. :D EDIT: I'm using MSSQL :(

    Read the article

  • question about a sata read/write speed

    - by Joe
    I'm contemplating biting the bullet for an ssd drive in a server, obviously I know it will be MUCH faster than a regular 7200rpm sata2 3gbps drive. The nice thing about ssd's is often they post the read/write speed but that info isn't available for sata's so I'm just curious to know what a typical read/write speed would be for a seagate 120gb 7200rpm drive. I know it fluctuates from manufacturer and model series but I'm just looking for a guestimate.

    Read the article

  • How to script GPO in Windows computers without Active Directory?

    - by Peteris Krumins
    Does anyone know how to script GPO for users in a Windows computer that is not on any Active Directory network? I can't use GPMC because it doesn't work without a domain. I have been searching the net for the last couple of hours and all the solutions that I find are related to GPMC. I'd imagine there are some objects in the GPO that are accessible via WMI? Does anyone know anything about that? I was unable to find any information about that. Here is the situation I am trying to script: I have 10 users on the machine, and I want to restrict what they are able to do on the machine. So I created 10 GPOs for each one of them. Now I want to apply a common policy to all of them. The only way to do it is to go through each of the GPO and do it manually. This is too time consuming, therefore I am seeking for a simpler solution. I was unable to find a way to copy GPO from a user to a user. That would make it much easier, I would create a GPO for 1st user, then copy it over to all the other users, but no luck, couldn't find a way to copy GPOs. The other method I tried was creating a GPO for the whole user group but it turns out you can't apply GPO to a group unless you use GPMC, which I can't cause the computer is not on any domain. So I am thinking about scripting this whole process, but again I can't find any examples of how to access particular GPO objects for particular users and modify properties through WMI. Any suggestions on the issue I am having? Thanks!

    Read the article

  • Good 1U Rack Firewall

    - by AX1
    Hello, I'm trying to find a good 1U rack firewall at a reasonable price. Most pricing is completely out of space (thousands of dollars? Why?). I don't want to list all features I need/want (there are too many variations but I don't care about most of them) - I'm just looking for something simple and not overly expensive. I've looked at the WatchGuard XTM 505 which is more reasonably priced -- are there any other firewalls in that range or even less expensive that are good for a small company?

    Read the article

  • ISP Load Balancing with ISA 2006

    - by Bill Best
    I understand that ISA 2006 has an integrated Network Load Balancing feature. We also recently acquired a second internet line through a second service provider. I know it is possible to purchase a NLB router for using both incoming lines but this is not the route we would like to take if at all possible. Thus, is it possible to have two ISA 2006 servers each with there own external connection, Load balanced to be viewed as one gateway? My thought was to have two ISA servers each with three NICs, one external, one internal and one for cross communication. I am under the impression that this should work but was hoping someone else has had experience with it.

    Read the article

  • Seeking webcam with own IP address

    - by Mawg
    I am not sure if this is the correct place to post, but I couldn't find anywhere better. I am looking for a webcam/movie cam and this site seems more addressed to still images, but ... I am looking for a small, rugged web-cam which can be hand-held or perhaps head-mounted (failing that I can settle for a tripod mount, but I need portability). It must have its own IP address so that anyone can view its video stream from a web browser. I would prefer 2 way voice communication too. Encryption of data is nice, as is compression (H.264). Maybe also remote control, like causing it to zoom from the browser. Does anyone have any suggestions, even suggestions of somewhere else to look? Thanks very much in advance.

    Read the article

  • Window too big to fit the screen!

    - by syockit
    I'm using Windows 7 on a 8.9' monitor with 1280x768 screen resolution. Using the might of arithmetics, I'm able to determine that my dpi (actually ppi) should be 167. Win7 is really helpful in that it doesn't have to restart to apply new dpi settings, unlike its predecessors (though I'd rather it applies straight away). The problem with small monitors in Windows is that when you come across windows too big to fit the screen, you can't move the title bar far above it. In X window managers I used in the past, you could alt-drag the window to anywhere you want, but in Windows, even if you alt-space and select move, it will automatically push the window back until the title bar is visible. I'm looking for a solution that either: allows me to move window freely without regard to titlebar visibility, or attach a scrollbar to existing window, or EDIT: create virtual desktops that allow me to span windows over 2 desktops, or EDIT 2: allow me to set larger virtual resolution, then pan & scan. EDIT 3: I found some progs that might do some of the above: 1) AltDrag allows me to drag, resize using alt and left/right mouse button. Neat! Best solution so far. 2) GiMeSpace Desktop Extender is supposed to allow me to scroll desktop. Didn't work. The other new version, GiMeSpace Ultimate Taskbar worked, but it destroys my Superbar, replacing it with its map.

    Read the article

  • How does it hurt to use Linux (Ubuntu) as a guest OS for all my tasks?

    - by sauparna
    I have a machine running Windows, where the disk has two partitions C (50 GB) and D (250GB). I do research in Information Retrieval and need to work with a large corpus (more than 50 GB) and in Linux. So if I want to install Linux on the existing system, keeping the Windows installation intact, will it be fine to run it in a virtual box? (say, QEMU, VMWare, etc.) An alternative is using Wubi. In that case the Linux installation has to be on drive C. Then, if I keep a small Linux installation (say 5GB) on C, and my corpus on D (mounted in Linux), how will it affect the performance of my programs which would be accessing the mounted Windows drive D. Is it feasible to use Linux this way? Which of the above is better if at all they are a way out? Note : Since my post in July 2010, I have been using and have tried several ways of maintaining a disk-image that I can mount in Linux. I had a 100GB qcow2 disk and a 100GB raw disk, both formatted to an EXT3 file system. I was mounting and connecting to the qcow2 disk using qemu-nbd. The problem was that every now and then, the connection to the disk would get lost and the running programs would throw disk I/O errors. The raw disk would mount and work fine as a loop mounted device, but when writing data to it, the mount.ntfs program would hog the CPU and the process would take an enormous amount of time. I was in fact running make on a piece of software located on this raw disk, and after a point of time make was waiting while mount.ntfs would show 100% CPU usage.

    Read the article

  • Script Task and Event Logging in SSIS

    components. These same configuration settings can be leveraged in Script Task, but you also have the option of triggering and tracking events in a considerably more customizable manner. This article explores features that provide this flexibility. NEW! SQL Monitor 2.0Monitor SQL Server Central's servers withRed Gate's new SQL Monitor.No installation required. Find out more.

    Read the article

  • reinstalling phpmyadmin

    - by explorex
    EDIT:: installed mysql-server but no phpmyadmin (since phpmyadmin was installed before mysql, that resulted an error). How to reinstall phpmyadmin with database (there is no phpmyadmin datbase)? unstalling it and reinstalling it didn't help. i was trying to install phpmyadmin (and zend framework) through synaptic manager but in the middle i was prompted for password i thought it was phpmyadmin password and i proceeded but i got error and i aborted. and then again i tried to reinstall, it reinstalled but i am not getting phpmyadmin. EDIT::The following is invalid so please don't bother apache is running but mysql is not some of it's characteristics are: santosh@explorer:~$ mysql ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) santosh@explorer:~$ sudo apt-get install mysql-server E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable) E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it? Should i be asking this question here or stackoverflow? UPDATES:: after restarting my computer santosh@explorer:~$ sudo service mysql start [sudo] password for santosh: mysql: unrecognized service UPDATES:: santosh@explorer:~$ sudo apt-get install mysql Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package mysql

    Read the article

  • `power/persist` file not found in USB device sysfs directory

    - by intuited
    The file /usr/share/doc/linux-doc/usb/persist.txt.gz mentions that the USB-persist capability can be enabled for a given USB device by writing 1 to the file persist in that device's directory in /sys/bus/usb/devices/$device/power. This is said — if I understood correctly — to allow mountings of volumes on the drive to persist across power loss during suspend. However, I've discovered that the device I'd like to enable this facility for — a USB hard drive — does not have such a file in its corresponding directory, and that attempts to create it are rebuffed. Is there perhaps a kernel module that needs to be loaded for this to work? Do I need to build a custom kernel? I'm running ubuntu 10.10.

    Read the article

  • Multi Seat Ubuntu 10.10

    - by JJ Mcfly
    Hi I was hoping to have a 2 seat setup. One will be for my TV just going to run Boxee. The other is for my main Desktop. I've been looking for a good guide to help me navigate this, I'd like to use ubuntu 10.10. I am assuming it's just a case of getting a box + 2 graphics adaptors and 2 usb mice and keyboards, one of which will be bluetooth for the TV. I can't seem to find much documentation on this idea. Can anyone point me in the right direction? Also I am assuming that this is all possible with a standard ubuntu install, but with some additional configuration. Thank you in advance for any advice you can offer me JJ Mcfly

    Read the article

  • How to direct Ubuntu to use USB connection for Internet

    - by t3ch
    Hi folks, I posted yesterday regarding how to configure easytether on Ubuntu. I followed the steps and everything looks good from the terminal. But I am not able to connect to the Internet. Currently I am connected to a Wireless network, I tried disconnecting to it, in hope to connect to Internet using my phone but with no help. How do I make my notebook use my cell phone's connection. I have attached the snapshot from the terminal.

    Read the article

  • Help to setup networking in Virtualbox Ubuntu Guest from Windows vista Host

    - by Ramesh Vel
    Hi, I am trying to access the MYSQL installed inside the Ubuntu Guest (In VirtualBox) from my Windows vista Host. It always says not able to find the given IP in the network. I have tried ping the ubuntu virtual machine, but it was not working. So i believe root cause for this is, some bridging between Host & Guest is not enabled. Since i am very new to Ubuntu, am not able to troubleshoot this. Can someone help me out? Cheers

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >