Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
| Search | Today's Posts | Mark Forums Read
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old August 7th, 2007, 09:49 AM
Authorized User
Join Date: Oct 2006
Location: , , .
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default Format Merged Lines

I'm really hoping someone can help with this..

I am using infopath published to a sharepoint library. One of the columns contains the values of a repeating table merged together when published.

In Sharepoint Designer I've convertedt the view to xslt in order to format some of the columns.

The merged column looks like this:


And the code behind it is:

<div dir="{ddwrt:GetVar('Direction')}"><xsl:value-of disable-output-escaping="yes" select="ddwrt:AutoNewLine(string(@LDIPS_x0020_DATE ))" /></div>

In infopath the dates are set to date already so the problem isn't there.

Ideally I want to get rid of the time displayed and display as below:

It doesn't have to be a date, I don't mind deconstructing using substring and putting back together but the problem is every time I try I only ever get the first line displayed.

Can anyone please help me with this?

Old August 7th, 2007, 11:28 AM
Friend of Wrox
Points: 1,676, Level: 16
Points: 1,676, Level: 16 Points: 1,676, Level: 16 Points: 1,676, Level: 16
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Jul 2006
Location: , , .
Posts: 430
Thanks: 28
Thanked 5 Times in 5 Posts
Send a message via Yahoo to bonekrusher

Try changing this line:
<xsl:value-of disable-output-escaping="yes" select="ddwrt:AutoNewLine(substring-before(string(@LDIPS_x0020_DATE), "T"))" /></

Old August 7th, 2007, 05:25 PM
mhkay's Avatar
Wrox Author
Points: 18,487, Level: 59
Points: 18,487, Level: 59 Points: 18,487, Level: 59 Points: 18,487, Level: 59
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Apr 2004
Location: Reading, Berks, United Kingdom.
Posts: 4,962
Thanks: 0
Thanked 292 Times in 287 Posts

Sorry, you'll have to show more of your input and output and explain what the extension functions do. It's also not clear why you would want to use disable-output-escaping.

In XSLT 1.0 if xsl:value-of is given a node-set as input, it displays the string value of the first node in the node-set. That might be relevant to your problem.

Michael Kay
Author, XSLT Programmer's Reference and XPath 2.0 Programmer's Reference

Similar Threads
Thread Thread Starter Forum Replies Last Post
Merged cells when exporting a report to excel bea Reporting Services 0 June 22nd, 2007 09:18 AM
Autofit Merged cells mls Beginning VB 6 1 April 29th, 2006 08:26 PM
split cells up if merged crmpicco Excel VBA 4 May 4th, 2005 10:25 AM
Wrap text with merged cells aspadda Excel VBA 4 January 29th, 2004 03:02 PM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.