Windows Vista Forums

get-html

  1. #1


    William Stacey [C# MVP] Guest

    get-html

    Bit OT, but psh related. So this guy has a get-html script that grabs the
    console as formatted html. So how do I paste this output in OneNote or Word
    so it shows up rendered and not just text? I have been scratching my head
    for some time. tia

    http://ps1.soapyfrog.com/2007/01/06/...grabs-in-html/

    --
    William Stacey [C# MVP]





      My System SpecsSystem Spec

  2. #2


    klumsy@xtra.co.nz Guest

    Re: get-html

    not sure the right syntax but basically you have to put it on the
    clipboard and specify the contents are html etc..


      My System SpecsSystem Spec

  3. #3


    William Stacey [C# MVP] Guest

    Re: get-html

    I got the cut/paste thing. Let me ask another way. I get the html text
    instead of the formatted html.



    <pre style='color: #eeedf0; background-color: #012456; '>Windows PowerShell



    Copyright (C) 2006 Microsoft Corporation. All rights reserved.



    </pre>


    --
    William Stacey [C# MVP]
    PCR concurrency library: www.codeplex.com/pcr
    PSH Scripts Project www.codeplex.com/psobject


    <klumsy@xtra.co.nz> wrote in message
    news:1176175220.231376.148080@l77g2000hsb.googlegroups.com...
    | not sure the right syntax but basically you have to put it on the
    | clipboard and specify the contents are html etc..
    |



      My System SpecsSystem Spec

  4. #4


    klumsy@xtra.co.nz Guest

    Re: get-html

    how are you, programatically putting the html on the clipboard, how
    are you specifying that the contents of the clip are to be treated as
    rich html, rather than as dumb plain text?


      My System SpecsSystem Spec

  5. #5


    Gaurhoth Guest

    Re: get-html

    It's a couple of extra steps, but what I generally do is write the HTML to a
    file and launch that file using IE (from a script that wraps
    get-bufferhtml). When you copy/paste from IE, it shows up correctly in Word.
    I don't have the script on this PC or I'd post it.

    gaurhoth


    "William Stacey [C# MVP]" <william.stacey@gmail.com> wrote in message
    news:#FFNkYweHHA.4032@TK2MSFTNGP02.phx.gbl...
    > Bit OT, but psh related. So this guy has a get-html script that grabs the
    > console as formatted html. So how do I paste this output in OneNote or
    > Word
    > so it shows up rendered and not just text? I have been scratching my head
    > for some time. tia
    >
    > http://ps1.soapyfrog.com/2007/01/06/...grabs-in-html/
    >
    > --
    > William Stacey [C# MVP]
    >
    >
    >
    >


      My System SpecsSystem Spec

  6. #6


    Keith Hill Guest

    Re: get-html

    "William Stacey [C# MVP]" <william.stacey@gmail.com> wrote in message
    news:#FFNkYweHHA.4032@TK2MSFTNGP02.phx.gbl...
    > Bit OT, but psh related. So this guy has a get-html script that grabs the
    > console as formatted html. So how do I paste this output in OneNote or
    > Word
    > so it shows up rendered and not just text? I have been scratching my head
    > for some time. tia
    >
    > http://ps1.soapyfrog.com/2007/01/06/...grabs-in-html/
    >


    With PSCX 1.1.1 you can do this:

    gps | ConvertTo-Html Name, Id, Handles | Join-String | Set-Clipboard -Html
    {$_}

    Without PSCX 1.1.1, it gets tricky because you have to call the
    System.Windows.Forms.Clipboard.SetText($text, 'Html') method on a separate
    thread that is configured STA.

    --
    Keith


      My System SpecsSystem Spec

get-html

Similar Threads
Thread Forum
HTML Anchor not jump to the particular Anchor Point in New HTML document
We are working in the Health Archiving HTML CD, we are facing these problem, Experts, please try to give solution to solve this problem. Problem:...
Browsers & Mail
Vb & html
Hi dear; I want to create a page like the following, the only thing I want to add a column. This column also available printer that is on the...
VB Script
HTML
Hi, I've been using Vista for Windows Mail without any problem for over a year. Now or some reason all my received mail is in plain text so I can't...
Vista mail
.txt to .html
Hi, I'm just looking for a quick and dirty way to knock together a single web page from .txt. Eg. $textsource = get-content "C:\source.txt"...
PowerShell
What is HTML?
I got a warning that some PC can't read this. I didn't know I was sending it. I was recommended to change to plain text, but did not tell me how to...
Vista mail
working on html objects using HTML DOM, VBscript
Hi All, I have one html page with forms and objects like radiobuttons, checkboxes, dropdown list, text boxes, links..... I will perform some...
VB Script
HTML
Hi all, Windows Mail by default blocks images and other external content in HTML. How do I go about unblocking it so I can see images instead of...
Vista mail