Adding a (href) hyperlink to html(convertTo-HTML) via powershell

  Im trying to add a href hyperlink to my HTML as below as im sending it as an email.
But it's not working for me.
Has anyone experienced this? How can I get this rolling?
I have already added
$message.IsBodyHTML = $true to convert to html
    $message.Body = $exportlist | Select-Object Sponsor,Activate,Category,FileName,@{name="Link"; expression={"<a href=""" + $web.Url + "/" + $_.Sponsor + "/Activate/" + $_.FileName + """>Link</a>"}} | ConvertTo-Html -Head $a       
Thanks in Advance

Hi,
Can you try to write it to a htm file and see the output? 
http://technet.microsoft.com/en-us/library/ff730936.aspx
something like below:
Get-Service | Select-Object Sponsor,Activate,Category,FileName,@{name="Link"; expression={"<a href=""" + $web.Url + "/" + $_.Sponsor + "/Activate/" + $_.FileName + """>Link</a>"}} | ConvertTo-Html -Head $a | Out-File C:\Scripts\Test.htm
Invoke-Expression C:\Scripts\Test.htm

Similar Messages

  • Hyperlink on html to a word document does not navigate to the bookmark

    i am trying to navigate to a word document bookmark from an html page
    <p><a href = "file:///D:\temp.docx#my_bookmark">my_bookmark</a></p>
    When we click on the link, we get a pop up from internet explorer asking "What do you want to do with temp.docx?"
    When, we click on "Open", the work document opens up but does not navigate to the bookmark.
    i am able to navigate to the same bookmark when i create a hyperlink inside another word document
    ie. navigation from one word document to another work document bookmark works.
    i am using windows 7  , microsoft office 2010 
    Thanks for your Support

    Hi,
    After adding this link into your HTML page, did you check the URL of the link in browser? Did you see the complete URL with the
    #my_bookmark at the end?
    It should be a query about HTML code, there is not so much we can do on Office client side. For your case, I would suggest you post in the MSDN forum of
    Word for developer, where you can get more experienced responses.
    Regards,
    Ethan Hua
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • When previewed in browser or on the server the path of my web site repeats folders. However the "href" in the html code does not show the repetition in the path.

    If someone could help me on this one, this would be great. I am creating a web site that has several departments. I have categorized and saved each department in a main folder called "departments" and a subfolder for each one. In the Dreamweaver code view the pop-up menu links seem to show up properly, but when I preview in browser or upload to server "page not found" comes up because for some reason the address changes. Some parts of the address seem to be appearing twice, sometimes the entire path will appear twice as shown below:
    http://www.graphicmechanic.com/DEKALBCOUNTY/departments/parks-and-recreation/departments/p arks-and-recreation/pr-arabiamtn-map.html
    that is incorrect and it takes me to "web page cannot be found".
    It is obviously repeating the folders (hence the "departments/parks-and-recreation" twice. The correct link is:
    http://www.graphicmechanic.com/DEKALBCOUNTY/departments/parks-and-recreation/pr-arabiamtn- map.html
    The link issues are happening in the pop-up menu. For example if you go to http://www.graphicmechanic.com/DEKALBCOUNTY/departments/parks-and-recreation/pr-arabiamtn. html and rollover the link called "Arabia Mountain" in the links to the left side of the page, then click the pop-up menu link entitled "Arabia Mountain Map" that's where the problem occurs.
    Can anyone tell me how I can fix this problem. I don't know what I should do with the code since it already appears correct in html view.
    Please help if you can...
    Thanks in advance for any possible help you can provide...

    XonoBoom wrote:
    It is obviously repeating the folders (hence the "departments/parks-and-recreation" twice. The correct link is:
    http://www.graphicmechanic.com/DEKALBCOUNTY/departments/parks-and-recreation/pr- arabiamtn-map.html
    The link issues are happening in the pop-up menu.
    This problem usually happens when the menu is either a server-side include or a library item using links relative to the document. When you reference a page at a different level of the folder hierarchy, the document-relative links no longer point to the correct destination.
    Change the links in the menu to be relative to the site root.
    A document-relative link usually looks like this:
    <a href="../products/index.html">Products</a>
    A link relative to the site root begins with a forward slash like this:
    <a href="/products/index.html">Products</a>

  • How to create hyperlink in Html page using Java

    Hello every one
    I want to know that how can I create a hyperlink in Html page using java ?
    Let for example
    I have code like this and i want to give hyperlink to it using java.
    rember that i am creating node using this id="name" which give me multiple value. and i want to assign diff link to each name..?
    <tr>
    <td ><span id="name"></span>
    </tr>

    but i m using this code to create node in html file
    HTMLLIElement li = (HTMLLIElement)appHTML.createElement("LI");
    Text txt = appHTML.createTextNode(name);
    li.appendChild(txt);
    appHTML.getElementById("name").appendChild(li);
    this will display all name value which is coming from database,
    and i want to assign a hyperlink to it,
    I have id with name also so I thought that using id i will
    create javascript like
    function popup(id)
         if(id==1)
              var n1 = window.open("../list/name1.html");
         if(id==2)
              var n1 = window.open("../list/name2.html");
    this way i want to popup particular file if i can pass id value in this function
    so want hyperlink like
    name

  • Adding new text in SHC HTML template with different colour

    Hi Gurus,
    We are using SRM5.0 Server 550 and SP14 and classic scenario.
    Is it possible to change the colour of a newly added text in Shopping cart HTML template?
    I mean we have a requirement to add a new text in HTML template of shopping cart and with a different colour so that it woulod be highlighted whenever users try to shop something.
    Can anyone let me know the pros and cons of such a thing, if later on they upgrade to SRM7.0 and its feasibility?
    Regards,
    Teja

    Hi,
    You can enhance/modify the HTML template.
    SRM 7.0 does not use ITS HTML template. So SRM 5.0 is the last version using ITS HTML template and no impact for upgrading to SRM 7.0.
    Regards,
    Masa

  • How to do hyperlink to html page?

    can i know how to do a hyperlink to html page once i click on a Jbutton? I need a help : )

    You can try something like this:
    String cmd = "c:/program files/ie.exe"; // WHat ever your explorer path is
    String url = "test.html"; // what ever your html path is
          try {
          Runtime.getRuntime().exec(cmd + " \"" + url + "\"");
          } catch (IOException ex) {
    ex.printStackTrace();
          }

  • Can I get Href attributes in HTML page ?

    Can I get Href attributes in HTML page ?
    I want to get HTML's table include href.
    I want to get columns "item", "item href", "value" from below table in a HTML web page.
    <table>
    <thead>
    <th>item</th>
    <th>value</th>
    </thead>
    <tbody>
    <tr>
    <td><a href="http://xxx.com/blue">item blue</a></td>
    <td>10</td>
    </tr>
    <tr>
    <td><a href="http://xxx.com/red">item red</a></td>
    <td>20</td>
    </tr>
    </tbody>
    </table>
    Regards,
    Yoshihiro Kawabata

    Hello Ben, I'm using some methos Web.Contents+Text.FromBinary+Text.Replace+Web.Page for href on HTML.
    source1 = Web.Page(
    Text.Replace(
    Text.Replace(
    Text.FromBinary(
    Web.Contents(url)),
    "href=""",
    ">"),
    "q=xx"">", "q=xx,")),
    This query transform href attribute to text in specific HTML.
    Original:
    <table>
    <thead>
    <th>item</th>
    <th>value</th>
    </thead>
    <tbody>
    <tr>
    <td><a href=http://xxx.com/blue?q=xx>item blue</a></td>
    <td>10</td>
    </tr>
    <tr>
    <td><a href="http://xxx.com/red?=q=xx">item red</a></td>
    <td>20</td>
    </tr>
    </tbody>
    </table>
    Result:
    <table>
    <thead>
    <th>item</th>
    <th>value</th>
    </thead>
    <tbody>
    <tr>
    <td><a>http://xxx.com/blue?q=xx, item blue</a></td>
    <td>10</td>
    </tr>
    <tr>
    <td><a>http://xxx.com/red?q=xx, item red</a></td>
    <td>20</td>
    </tr>
    </tbody>
    </table>
    Regards,
    Yoshihiro Kawabata

  • I added a counter and other html to my non .mac site

    I added a counter and other html to my non .mac site by simply adding the code to the index.html page after I published to folder.
    http://www.the-scrap-yard.net/photorestoration/

    Also, I would suggest requesting a change in your credit card number that was
    used for that transaction just to be safe.
    Also, since they actually got access to your computer, if you have any other
    financial account info on your computer, you will need to monitor those accounts
    quite closely for any fraudulent activity.  There is no knowing what they might have
    accessed.  They quite possibly may have downloaded your whole life.

  • Binding an object tag value / Creating HTML via a backing bean

    I have a task flow that sets some properties in my backbean. I've bound the "classid" of an <object> tag to one of these values. However, the first time i load the JSFF page, the object tag isnt created, but if i refresh the page, its loaded correctly.
    This would lead me to believe that the binding isn't being done before the JSFF is rendered, so the question is. Does anyone know how to fix this? and if not, i have thought about creating a backing bean that would add the <object> tag to the page with the bind value, but have no idea how i would go about this.
    Does anyone know of any good tutorials on adding HTML via a backing bean before the page is rendered?

    After further investigation and talking to a colleague, It seems it might not be binding related, since if I print out the bind in a text field, it displays correctly. I think the problem is because I am trying to inject an object tag (hosts a .NET control) into a fragment, but this is never picked up and rendered. Thus, when I do a full page refresh, the object tag is added and all goes well.
    If I attempt to bind/add a ADF Faces component this way, it works correctly.
    Do you know how to inject code for a fragment?, I am very stuck at the moment - don't have that much knowledge on ADF, so any links/help would be appreciated.
    My scenario is this:
    I am using a task flow that has 2 fragments.
    Fragment 1: set properties - has two input fields and a next button which are bound to a bean that saves the input fields
    Fragment 2: display object tag using step ones properties.

  • Calling EJB with HTML via SERVLET

    Hi,
    I used a writen example that calls EJB from HTML via SERVLET. Example name is Bonus. The problem I have is that the HTML throw error while calling SERVLET. I dont figure out what seams to be a problem. Someone know?
    I wonder if the problem is in servlet? The EJB is fine!
    christian
    HTML CODE:(bonus.html)
    <HTML>
    <HEAD>
    <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1250"/>
    <TITLE>untitled1</TITLE>
    </HEAD>
    <BODY BGCOLOR = "WHITE">
    <BLOCKQUOTE>
    <H3>Bonus Calculation</H3>
    <FORM METHOD="GET" ACTION="BonusAlias">
    <P>Enter social security Number:<P>
    <INPUT TYPE="TEXT" NAME="SOCSEC"></INPUT>
    </P>
    Enter Multiplier:
    <P>
    <INPUT TYPE="TEXT" NAME="MULTIPLIER"></INPUT>
    </P>
    <INPUT TYPE="SUBMIT" VALUE="Submit">
    <INPUT TYPE="RESET">
    </FORM>
    </BLOCKQUOTE>
    </BODY>
    </HTML>
    SERVLET CODE:(BonusServlet.java)
    package mypackage5;
    import mypackage5.Calc;
    import mypackage5.CalcHome;
    import mypackage5.impl.CalcBean;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import javax.naming.*;
    import javax.rmi.PortableRemoteObject;
    import java.beans.*;
    public class BonusServlet extends HttpServlet {
    CalcHome homecalc;
    public void init(ServletConfig config) throws ServletException{
    //Look up home interface
    try{
    //InitialContext ctx = new InitialContext();
    //Object objref = ctx.lookup("Calc");
    //homecalc = (CalcHome)PortableRemoteObject.narrow(objref, CalcHome.class);
    Context context = new InitialContext();
    CalcHome calcHome = (CalcHome)PortableRemoteObject.narrow(context.lookup("Calc"), CalcHome.class);
    Calc calc;
    catch (Exception NamingException) {
    NamingException.printStackTrace();
    public void doGet (HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
    String socsec = null;
    int multiplier = 0;
    double calc = 0.0;
    PrintWriter out;
    response.setContentType("text/html");
    String title = "EJB Example";
    out = response.getWriter();
    out.println("<HTML><HEAD><TITLE>");
    out.println(title);
    out.println("</TITLE></HEAD><BODY>");
    try{
    Calc theCalculation;
    //Get Multiplier and Social Security Information
    String strMult = request.getParameter("MULTIPLIER");
    Integer integerMult = new Integer(strMult);
    multiplier = integerMult.intValue();
    socsec = request.getParameter("SOCSEC");
    //Calculate bonus
    double bonus = 100.00;
    theCalculation = homecalc.create();
    calc = theCalculation.calcBonus(multiplier, bonus);
    catch (Exception CreateException){
    CreateException.printStackTrace();
    //Display Data
    out.println("<H1>Bonus Calculation</H1>");
    out.println("<P>Soc Sec: " + socsec + "<P>");
    out.println("<P>Multiplier: " +
    multiplier + "<P>");
    out.println("<P>Bonus Amount: " + calc + "<P>");
    out.println("</BODY></HTML>");
    out.close();
    public void destroy() {
    System.out.println("Destroy");

    The error is that page cannot be found! When I run only the servlet it works, when I run the HTML page and enter the field throws eror that the page cannot be found!
    thanks
    Christian

  • JATO: How to send HTML via Component

    How does one output formatted text as HTML via a visual component?
    I usually have an HTML UL/LI list of "...is required" messages if a user submits a form without all required values entered.
    When I assign the text in the requestHandler() event, the text appears, but displays the HTML and text "literally" and doesn't render it as HTML.

    alabanco wrote:
    thanks. Now we've got to the most interesting part and intriguing one. Why should I upload html page to the server. I do understand uploading the images to server which will be used as links in my html mail. But why and how should I store that page in my server if I have CMS post instead from which I used pictures as links. SHould I create yet another type of post in CMS that is my html newsletter? That's not cool. What is the industry standard approach for that?
    By the way Mail.app uses that baby design templates for your messages. Why don't we have an option to delete all these creepy childish templates and store solid bold corporate style templates for newsletters and send it somehow? Or will it just attach the images to the message then? If so then it is not what I want and it is really depressing.
    The industry convention/"standard" is not to use html in email. Wheteher or not your html newsletter displays as you intended is at the mercy of the recipient and their email client settings.
    If you want to preserve your html layout and styles, save your newsletter as a pdf document and attach the pdf document to your email. Or, as already suggested, use a web server to serve your html newsletter.

  • Display Pre-Formatted HTML via Web Dynpro

    Hi,
    Does anyone know of a way to display preformatted HTML via web dynpro, can any of the standard UI elements do this?
    Thanks in advance,
    Simon

    Hi,
    can you explain what do you mean by HTML string? is it binary data that you have?
    if it is a binary data i.e. in bytes then you can do this way also..
    Store the binary data in a context varaible named Data and to store the url to be generated, create another context variable Url;
    String formattedStr = wdContext.currentContextElement()
        .getData();
    try
      IWDCachedWebResource resource = WDWebResource.getWebResource
        formattedStr.getBytes("UTF-8"),
        WDWebResourceType.HTML
      resource.setResourceName("<Give a filename>");
      resource.setAttachement( false );
      resource.setReadOnce( false );
      wdContext.currentContextElement().setUrl
         resource.getAbsoluteURL()
    catch (Exception ex)
      wdComponentAPI.getMessageManager()
        .reportException( ex.getMessage, false );
    Set source of the Iframe as context variable Url.
    regards,
    Mahesh

  • Nokia C3 - viewing html via e-mail / Hotmail

    Deer users,
    I wondered if there is an option for the Nokia C3 to view HTML via e-mail, for example Hotmail.
    Does someone knows how to configure this in the phone?
    Regards,
    Fandaman

    rembsen wrote:
    - Sender has got Outlook (at least 2003)
    - Mail service is Exchange (at least 2003)
    Looks like there is a common theme there. It is probably just that the original message has been corrupted somehow. Some mail clients try harder to understand corrupted data than others. I can't really tell from your original post. With mail messages, you really need to have the original data, not copied and pasted and not forwarded. If you have such a mail message, save it as raw source, put it into a zip file, and e-mail it to me. I can tell if it is an Apple Mail problem or a MS problem. If it is an Apple problem, I can file a detailed bug report on it. You can find an e-mail address for me by Googling my nickname.

  • Adding a shared mailbox to a user's Outlook profile, who has reviewer rights only, via PowerShell

    Hello Everyone,
    I'm working on trying to create something like a knowledge base for my company, and what I'm trying to accomplish is to create a shared mailbox on 365, add users to have read-only rights to the Inbox (which I can achieve via PowerShell) so they can't delete
    the articles, but it seems that by just adding Reviewer permission to a user, it doesn't force the mailbox to open on the end-user's Outlook profile - it only seems to automatically populate if I go through the exchange admin console and allow Full Access
    through User Delegation. 
    Is there a way, via PowerShell, to open a shared mailbox in a user's Outlook profile?
    Thanks for all the help!

    Hi,
    We can create a PRF file that modifies the existing Outlook profile to add the shared mailbox.
    Please have a look at this thread which discussed a similar issue:
    http://social.technet.microsoft.com/Forums/systemcenter/en-US/374e5a31-1732-45b8-afdd-7c0987e04a7e/how-to-add-additional-mailboxes-in-outlook-for-exchange
    For more information about Customize Outlook profiles by using an Outlook Profile (PRF) file, see:
    http://technet.microsoft.com/en-us/library/cc179062(v=office.14).aspx
    Hope this helps.
    Regards,
    Steve Fan
    TechNet Community Support

  • Open hyperlinks in html text using StageWebView instead of external browser

    My iPad app downloads xml data from a server and displays it as html text. The text may contain hyperlinks and currently these are correctly displayed as links in my app. However when I click on the link, it opens the link in an external browser.
    Any idea how I could instead open the links using StageWebView - I know how to open a link using StageWebView - the problem is intercepting whatever causes it to open in the external browser and instead use StageWebView.
    Thanks in advance

    Hi, John, welcome to Apple's user-to-user discussion forums.
    Does anyone here know of a way to open new windows without using command click in a tab?
    If you want links on a web page to open in a new tab, you need to command-click on them. This will work both for links set up to open in the same window and those set up to open in a new window. There is no setting in Preferences to make links on a web page automatically open in a new tab.
    There is a preference setting to open links from other programs, such as Mail, in a new tab. In Safari's Preferences, click on the General icon. Towards the bottom where it says "Open links from applications", check "in a new tab in the current window".

Maybe you are looking for

  • Issue at billing

    A delivery has  two different origins on the same item for which our system is supposed to create two different delivery notes. We have 100PCs of Item soap from Canada and 200 PCs of bottles from US.  The real issue is in the invoice it is showing 30

  • Problem with mail with pictures.

    Hi, I got my iPhone last Thursday so there is still a lot for me to learn. However, I thought we could receive pictures in our emails on the iPhone. Am I wrong? My son's girlfriend sent me 2 pictures in an email and I thought I could view and downloa

  • Forecast horizon values are not being considered in Total demand row

    Hello Experts, We are in SCM 4.1 Version. I have a question regarding Forecast horizon consderation in Planning book. We have a weekly data view In our  Planning book,and in that planning data view "Total demand" row is not calculating correctly for

  • Best way to to hook up Thunderbolt NAS to 2009 iMac

    I have a 2009 iMac with USB and FireWire.  I just purchased and new NAS with Thunderbolt and USB.  Is there any way to connect at a faster speed than the USB 2.0 that I my computer has?

  • How to re-post Unposted Travel Transactions in Posting-Run

    Hello Experts, In theory all Travel Expenses in all approved trips ends up in General Ledger via Posting Run management which is purely an ATR(Accounting To Report) function.  But in practice we have realised few of the transactions did not get poste