Search Results

Search found 19539 results on 782 pages for 'pretty print'.

Page 21/782 | < Previous Page | 17 18 19 20 21 22 23 24 25 26 27 28  | Next Page >

  • Search for and print only matched pattern

    - by Ayman
    I have some huge xml text files. I need to write a script to find and print a specific tag only. I tried sed and grep but they both return the whole line. Using SunOS 5.x, so not all linux commands may work. grep -o is not available. The 'xml' file is not actually one huge xml document, but each line is a separate xml document, with just a few tags, not even nested. And the structure is fairly easy, so full xml parsers is not needed, and probably would not work. I was looking for sed, awk, or some other one liners, but could not get them to work, and they are both relatively new to me.

    Read the article

  • Is there a way to unlock PDF documents?

    - by NoCatharsis
    I realize most PDF documents are locked for a reason, but I spend several hours a week editing datasheets provided directly from my vendors to be sent to customers. Obviously it's very annoying and somewhat of a show-stopper when I download a datasheet in PDF format, then I am not able to draw boxes, add comments, or draw arrows to the supplied product. One of our vendors told us the way around that was to print a physical copy, then scan it in as a PDF - not the most technological or aesthetically pleasing solution I have found. I at least would like to be able to print the PDF to another PDF so that the new copy is unlocked for editing. Is there any way around this?

    Read the article

  • How to modify PATH variable for X11 during log-in?

    - by user1028435
    I originally posted this over at StackOverflow, but someone said it might fit better here. Original question is here: http://stackoverflow.com/questions/10096327/overwriting-print-screen-actions-in-linux-without-administrative-rights. Decided to revise my question, based on what I learned there: Essentially, my problem is that I am working on some lab computers (read: no administrative rights) that, if I log in, I need to change the PATH variable as X11 starts. The reason is that I need to change the PATH variable at this time, as opposed to later, is that the Print Screen command seems to "bind" during login (forgive my bad explanation of this). You can see in the work-around I listed in the previous question, that I can make it work by starting a new X, but I was wondering if it is possible to change upon login. If this seems a poor explanation, you can check out the original link for my context and reasoning behind what I'm doing. Any ideas? Details about Distribution: cat /etc/redhat-release tells me: Red Hat Enterprise Linux Client release 5.8 (Tikanga)

    Read the article

  • Program to print gCal or iCal calendars in a monthly one calendar per column format

    - by David Smith
    I'm moving my family off of using the low tech "Boynton Mom's Family Calendar" to schedule things but I'd like to be able to create a monthly printout of the calendar in the same "Boynton" format (I'm sure it has an official name). The format is kind-of like a spreadsheet where each row of the calendar is a different day of the month and there is a separate column for each person in the family. I have all our calendars on Google but they are also accessible from iCal on the Mac. Is there a Mac program that can get the data from gCal or iCal print out the calendars in the Boynton format?

    Read the article

  • Epson XP-600 will not print properly with all new ink recently installed

    - by Joy
    I just installed brand new Epson 273 ink cartridges ($64 worth!) in my Epson XP-600 printer. One box had all the colors plus black, and one had the fatter black cartridge. I am not getting ANY black print on paper, although, when I lift the cartridges out, they show ink inside. Now the yellow is saying LOW though all cartridges are less than 2 weeks old. I only use this printer sparingly—not for business or work reasons. I am ready to scream, as the ink cost almost as much as the actual printer (which is barely 7 months old)! Any ideas on how to solve this issue?

    Read the article

  • Eliminating Duplicate Printers on Print Server 2008 R2

    - by user123247
    I added a print server role to our new 2008 R2 server and started adding printers to it that will be available to Remote Desktop sessions. When I added the Remote Desktop services role, I specified printer redirection, thinking that would be a good thing. On the PCs where I am testing all this, I added the network printers locally so that they would have the printer available for local use. When I logon to the 2008 R2 server, I notice that the printers I added are out there twice... once on the 2008 R2 server and an additional time redirected from my PC. Is there some way to eliminate this duplication w/o eliminating redirection?

    Read the article

  • How to print TIFF files using MSFT Office Document imaging?

    - by Think Floyd
    OS: Vista and Windows7 I have Microsoft Office Document Imaging installed. .tif and .tiff files association is set to " Microsoft Office Document Imaging" When I open a TIFF file, it opens in " Microsoft Office Document Imaging". Good so far. However, when I right-click on the TIFF file and invoke print, I see a "Print Pictures" dialog, ("How do you want to print your pictures?") I have some applications installed on my machine that print incoming TIFF files on the printer. They work fine on XP. However, on Vista and Windows7, I get this "Print pictures" prompt requiring an user intervention (i.e, click on Print button). How do I get rid of this "Print Pictures" prompt?

    Read the article

  • using sed to print next line after match

    - by smokinguns
    I came across various examples on printing next line after a match, that use awk and sed. I'm using it in my code and it works fine. Now I want to use a variable instead of a hardcoded value for the pattern match. The search pattern string includes forward slashes "/". How do I use a variable that has "/" in it and use it to print the next line after the match? The following doesn't seem to work: var="/somePath/to/my/home" val=`echo -e "$someStr" | sed -n ':$var:{n;p;}'` In this case, val is always blank. I'm using using ":" as the delimiter instead of "/". I'm on a Mac OS X.

    Read the article

  • DNSHost.exe trojan found, now after fix, no one can print

    - by Matt Dawdy
    What started today as an inability to get to the internet (but people could get in just fine), morphed to we realized that the DNS Server wasn't working, then we figured out that we had a trojan called DNSHost.exe (spybot.rl I think), and we disabled its service entry and deleted the offending file and all registry keys told to use by the Trend Micro site. Now, we can get on the internet, but the printer being served by this machine (called server2) cannot be printed to from any client machine on the network. We get the error "The RPC Server is unavailable". I'm assuming that this is related to the DNS issue we had earlier, as we were able to print just fine until this fun happiness started this morning. Anyone have any solid suggestions? Windows Server 2003 R2 SP2, and the client machine are all Windows XP SP2.

    Read the article

  • Windows 7 Printing to a network printer

    - by JohnyV
    We have a 2008 server as our print server. Clients that use windows xp with a logon script to map have no problems printing. When I test printing to a network printer on a windows 7 machine it works fine up to a few machines as soon As i get 12-15 workstations trying to print, when they log in they get the yellow exclamation mark and needs troubleshooting against the printer name. It is being deploy by group policy. I have tried to deploy it by group policy also by group policy preferences and by using a script and i get the same error whatever i try. Does anyone have any suggestions to try and troubleshoot? Once again Windows xp clients have no issues printing at all. It is only windows 7 clients. Thanks

    Read the article

  • Changing shared printer settings to default to greyscale

    - by Chris
    My company has about 60 employees all running Windows Vista or 7 and a gigantic Minolta printer hooked up to an EFI Fiery Image Processor. We're burning about $300 a month in printer supplies alone. I'm trying to find a way to cause the printer to default to grayscale in order to save money. So far I've tried: Changing settings on the image processor Changing settings on the print server Looking through the Group Policy editor to see if I can find anything useful Creating a new printer on the print server and setting it to be grayscale only Adding the printer to my computer directly (through a TCP/IP port) and setting it to be greyscale only Has anybody successfully done this before? If so, how was it gone about? I don't expect anybody to know the specifics of my environment, I just not sure what the right direction is.

    Read the article

  • How to print 4 index cards on a single A4 sheet in Word 2003

    - by Anna
    I have an index card designed in Word. It's fairly complicated with graphics, borders and background. The page layout has been set to landscape and with size set to 4x6. How can I print this, 4x per A4 landscape sheet? I cannot for the life of me work it out. The printer always seems to do a single card per A4 sheet, wasting 3/4 of the page. "Pages 1,1,1,1" will result in 4 sheets being printed. What am I doing wrong?

    Read the article

  • All-on-one-page print view in Plone

    - by Kev
    We have a Plone 4 document that is in a hierarchy. At each node there's either a document, or a folder. Folders then have more documents and folders. We want to be able to print the entire hierarchy, which means rendering the whole thing on one page. I see a number of web sites like this one that seem to have something like this. Is it manually done or is there some add-on I can get to make this feature possible?

    Read the article

  • How to print TIFF files using MSFT Office Document imaging?

    - by Think Floyd
    OS: Vista and Windows7 I have Microsoft Office Document Imaging installed. .tif and .tiff files association is set to " Microsoft Office Document Imaging" When I open a TIFF file, it opens in " Microsoft Office Document Imaging". Good so far. However, when I right-click on the TIFF file and invoke print, I see a "Print Pictures" dialog, ("How do you want to print your pictures?") I have some applications installed on my machine that print incoming TIFF files on the printer. They work fine on XP. However, on Vista and Windows7, I get this "Print pictures" prompt requiring an user intervention (i.e, click on Print button). How do I get rid of this "Print Pictures" prompt?

    Read the article

  • Print Screen key of Windows on Mac

    - by mgpyone
    I've tried Win 7 on my MacBook. then I'm facing a problem of capturing the screen . I want to take the screen shot of the whole screen(including the cursor) . I'm sure that I can grab it with the key "Print Screen" . but I don't found any key for it on my Mac. also though Windows Snippet tools can take the whole screen, I've to use the cursor .. Thus, any solution that can help out my problem will be appreciated.

    Read the article

  • I can't get my Macbook Pro to print to an IP addressable printer

    - by Pieter
    Running Macbook Pro OS X 10.6.3 Accessing an HP OfficeJet 5610 plugged in the USB port of a US Robotics router. I tried several combinations of: Protocol: Internet Printing Protocol (IPP) Line Printer Daemon (LPD) HP JetDirect (socket) Address: http://192.168.1.10:1631/printers/HP5610 192.168.1.10:1631/printers/HP5610 http://192.168.1.10:1631 192.168.1.10:1631 192.168.1.10 ... Driver: HP OfficeJet 5600 Series Whenever I try to print, it fails while saying "connected to printer" or "Printer is busy...zill try again in X seconds" Both Windows 7 and Windows XP computers on the network can successfully access this printer, identifying it as "HP5610 on http://192.168.1.10:1631/" I tried clearing all tasks and printers (ctrl-click in the menu), and resetting it to (socket, http://192.168.1.10:1631/printers/HP5610, HP5600 series) but to no success.

    Read the article

  • MS Word showing unwanted table borders on screen (but not on print preview)

    - by Jivlain
    I have a MS Word document with a number of tables. The other day when I created it, the tables all had no borders. Today, I opened it up to find that the tables did have borders. However, when I check the border properties on each table, it says that there are no borders. The tables are displayed with cell borders in all view modes except for the reading layout, and they do not show up on print preview. As this document is going to generally be for on-screen viewing, I need to get rid of the borders. How can I accomplish this? (this is a MS Word 2003 *.doc document, in MS Word 2003, which has been the only editor involved.)

    Read the article

  • Disable "Print and Close" Preview Shortcut on OS X Mountain Lion (10.8.2)

    - by Twitch_City
    I recently upgraded to Mountain Lion from Leopard and there is a global shortcut that I would really like to disable. Apparently, now if you select a document and press Command + p, Preview will open, print the document, then close. I'm sure this was done with the purest intentions but, unfortunately, it is right next to Command + o, which I use many times a day to open files. Since installing Mountain Lion, I've accidentally printed way too many documents just trying to open them! I've gone into the Keyboard preference pane and tried to find where this shortcut is located, but haven't had any success. Anyone know how I can disable this?

    Read the article

  • How to print new line character with echo?

    - by Summer_More_More_Tea
    I dump a string with hexdump like this 2031 3334 2e30 0a32 2032 3331 302e 000a. It is clear that 0x0a is new line character, however, when I try to echo this string out, I always got 1 430.2 2 13.0 -- the new line is replaced with a space, even I use the -e flag. What may be the problem? Does the tailing \0 ruin the output? Is there any alternatives to print 0x0a a new line? Thanks and Best regards.

    Read the article

  • Print each bookmark of a PDF separately

    - by Dave
    I have a very large (1000 page) PDF which contains about 100, ten page each documents one after the other. I would like to have them sent to my office printer as individual files so my office printer will print them double sided and staple each one individually. I'm using Adobe Acrobat X and think the first step is to bookmark the start of each of those 100 documents. I don't know the next step though. I also have a batch printing program so if i can extract each of those 100 bookmarks to individual files that would work too. Thanks for all the help.

    Read the article

  • Automate opening HTML and printing to PDF

    - by craigpatik
    I need a way to automate the following process in Windows 7: Open an .html file in Internet Explorer Print to PDF Save the PDF with a patterned file name (i.e., original_name_YYYY-MM-DD.pdf) Ideally, I could drag and drop several files or open a whole folder of files at once and a PDF would be created for each one. A command line solution is also acceptable. The files have to be opened in the browser because parts of the page are rendered with JavaScript on page load. In other words, if you simply right-click on the file in Explorer and choose "print", the resulting file is not the same because the JS didn't run. If it helps, Internet Explorer can be set as the default browser, and a PDF printer can be set as the default printer.

    Read the article

  • How to convert image to bitmap code for bluetooth print in iphone

    - by John Patel
    I am interested to print image from iPhone programmatically using bluetooth printer device. In one of the sample code I have implemented code for Text print but in that sample I am not getting how to convert image into format, like unsigned char buffer3[796]={ 0x55 , 0x66 , 0x77 , 0x88 , 0x44 , 0x1B , 0x58 , 0x31 , 0x19, 0x20, 0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x80 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x01 ,0xC0 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 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0x00 ,0x00 ,0x00 }; //[self addLabel:@"buffer3 is selected"]; [[session outputStream] write:(const uint8_t *)buffer3 maxLength:796];//send print package*/ This is sample code for Image print I am not able to print any other image because I am not having idea how to convert UIImage or NSData to the below mentioned Bit code. If any proper step by step method to do Image to bitmap conversion, then please let me know this.

    Read the article

  • Rails - How can I display nicely indented JSON?

    - by sa125
    Hi - I have a controller action that returns JSON data for api purposes, and plenty of it. I want to be able to inspect it in the browser, and have it nicely indented for the viewer. For example, if my data is data = { :person => { :id => 1, :name => "john doe", :age => 30 }, :person => ... } I want to see { "person" : { "id" : 1, "name" : "john doe", "age" : 30, }, "person" : { "id" : 2, "name" : "jane doe", "age" : 31, }, ...etc } In the view. I thought about using different routes to get the bulk/pretty data: # GET /api/json # ... respond_to do |format| format.html { render :json => data.to_json } end # GET /api/json/inspect # ... respond_to do |format| format.html { render :text => pretty_json } end Anyone knows of a gem/plugin that does this or something similar? I tried using JSON.pretty_generate, but it doesn't seem to work inside rails (2.3.5). thanks.

    Read the article

  • print a linear linked list into a table

    - by user1796970
    I am attempting to print some values i have stored into a LLL into a readable table. The data i have stored is the following : DEBBIE STARR F 3 W 1000.00 JOAN JACOBUS F 9 W 925.00 DAVID RENN M 3 H 4.75 ALBERT CAHANA M 3 H 18.75 DOUGLAS SHEER M 5 W 250.00 SHARI BUCHMAN F 9 W 325.00 SARA JONES F 1 H 7.50 RICKY MOFSEN M 6 H 12.50 JEAN BRENNAN F 6 H 5.40 JAMIE MICHAELS F 8 W 150.00 i have stored each firstname, lastname, gender, tenure, payrate, and salary into their own List. And would like to be able to print them out in the same format that they are viewed on the text file i read them in from. i have messed around with a few methods that allow me to traverse and print the Lists, but i end up with ugly output. . . here is my code for the storage of the text file and the format i would like to print out: public class Payroll { private LineWriter lw; private ObjectList output; ListNode input; private ObjectList firstname, lastname, gender, tenure, rate, salary; public Payroll(LineWriter lw) { this.lw = lw; this.firstname = new ObjectList(); this.lastname = new ObjectList(); this.gender = new ObjectList(); this.tenure = new ObjectList(); this.rate = new ObjectList(); this.salary = new ObjectList(); this.output = new ObjectList(); this.input = new ListNode(); } public void readfile() { File file = new File("payfile.txt"); try{ Scanner scanner = new Scanner(file); while(scanner.hasNextLine()) { String line = scanner.nextLine(); Scanner lineScanner = new Scanner(line); lineScanner.useDelimiter("\\s+"); while(lineScanner.hasNext()) { firstname.insert1(lineScanner.next()); lastname.insert1(lineScanner.next()); gender.insert1(lineScanner.next()); tenure.insert1(lineScanner.next()); rate.insert1(lineScanner.next()); salary.insert1(lineScanner.next()); } } }catch(FileNotFoundException e) {e.printStackTrace();} } public void printer(LineWriter lw) { String msg = " FirstName " + " LastName " + " Gender " + " Tenure " + " Pay Rate " + " Salary "; output.insert1(msg); System.out.println(output.getFirst()); System.out.println(" " + firstname.getFirst() + " " + lastname.getFirst() + "\t" + gender.getFirst() + "\t" + tenure.getFirst() + "\t" + rate.getFirst() + "\t" + salary.getFirst()); } }

    Read the article

< Previous Page | 17 18 19 20 21 22 23 24 25 26 27 28  | Next Page >