getting TEXT of an xslt.transform

On my page right now, I call a function:

<%=getMenu()%>

in my codebehind, I have the function do an xslt transformation:

sub
    xslt.Transform(doc, xslArg, Response.Output, Nothing)
end sub

Instead of calling the function directly on the main page, I now want to 
just place a literal on the page and set the literal's text via codebehind. 
However, I can't seem to do this:

ltl_menu.Text = xslt.Transform(doc, xslArg, Response.Output, Nothing)

As the 'expression does not return a value'.

How can one get the result of the text as a string?

-Darrel 


0
11/2/2005 11:01:43 PM
dotnet.xml 7266 articles. 0 followers. Follow

2 Replies
448 Views

Similar Articles

[PageSpeed] 56

Hello!

> ltl_menu.Text = xslt.Transform(doc, xslArg, Response.Output, Nothing)
> 
> As the 'expression does not return a value'.
> 
> How can one get the result of the text as a string?

Don't write it to Response.Output but use StringWriter: (untested)

StringWriter sw = new StringWriter();
xslt.Transform( doc, xslArg, sw, null );
ltk_menu.Text = sw.ToString();


There is also an XSLT-WebControl...



-- 
Pascal Schmitt
0
11/3/2005 12:07:51 AM
> Don't write it to Response.Output but use StringWriter: (untested)
>
> StringWriter sw = new StringWriter();
> xslt.Transform( doc, xslArg, sw, null );
> ltk_menu.Text = sw.ToString();
>
>
> There is also an XSLT-WebControl...

aha! perfect! Thanks!

-Darrel 


0
11/3/2005 12:54:25 AM
Reply:

Similar Artilces:

how do i get oulook to get mail from yahoo?
I have yahoo accounts, but cannot get outlook to recognize them... am computer illiterate, so put answer in laymans terms please. thanks Do you have a paid yahoo account? You need an account that supports POP3 (free accounts don't) before you can use it with Outlook. -- Diane Poremsky [MVP - Outlook] Author, Teach Yourself Outlook 2003 in 24 Hours Coauthor, OneNote 2003 for Windows (Visual QuickStart Guide) Need Help with Common Tasks? http://www.outlook-tips.net/beginner/ Outlook Tips: http://www.outlook-tips.net/ Outlook & Exchange Solutions Center: http://www.slipstick.com Sub...

Logical tests between Word form text fields
I have a Drop-Down form field with "Yes" and "No". I want to place the value 4 in a Text form field in the same document if the user selects "Yes" in the Drop-Down field. I set the Text form field to type "Calculation" but can not figure out the formula to use that doesn't return a Syntax error or "Undefined Bookmark, Yes". While I have Word 2007, I need to create this form for users with 2003 and so am using Legacy form fields. Hi jstern, Instead of using a calculation formfield, I'd suggest an ordinary formula field,...

Text in a filled text box not printing on PS printers
I am having problems printing Word 2007 documents to PostScript printers. the problem has been reproduced on different computers. the problem seems to be fixed in Office 2010. On any page in Word with a transparent image or an image with a drop shadow, text in any text box with a color-fill background does not print correctly. The text appears correct on screen and in print preview and prints correctly to a non-PS printer. The problem can be reproduced as follows: 1. Create a new image in MS Paint, save the image as a .jpg. 2. Create a new Word document, insert the new .jpg...

text not showing when i type in the email body
when i type in the body of the email nothing shows up. i can type in the subject and type in address. i cant copy and paste from a word doc. any suggestions. thx What version of Outlook are you using? I assume you've already tried rebooting? -- -Ben- Ben M. Schorr, MVP Roland Schorr & Tower http://www.rolandschorr.com http://www.officeforlawyers.com/outlook.html Author: The Lawyer's Guide to Microsoft Outlook 2007: http://tinyurl.com/ol4law-amazon "yanto" <yanto@discussions.microsoft.com> wrote in message news:8DEEB82A-EF41-4692-9470-8713...

Formula to strip figures from cells text strings
I'm trying to write a cell formula that strips figures from cells text strings & totals them into one cell. The figures will always have a decimal. For example: Cell A5 has a text string "924 Social 9.78" Cell B5 has a text string "984 163.94 981 7.84" Cell C5 has a text string "920 Kitchen 7.86 Cell D5 has a text string :988 Youth 42.46 Need to arrive a the total amount of 231.88 in cell E5 (9.78+163.94+7.84+7.86+42.46)-do not include the non-decimal figures 924, 984, etc. Any ideas? Thanks for all your help. mikeburg -- mikeburg --------------...

Cells formatted for general and text show scientific format
I am working on an Amazon.com shipping confirmation upload. The workbook is downloaded from amazon.com. When I enter the Order Item ID number which is 14 characters, it displays in scientific format. I have tried general, number and text formats. Number format works if there is no leading zero but general and text do not. - Are you formatting the column for Order Item ID number before entering the data? That should solve the problem. - If you are formatting after entering the data, selecting F2 (Edit) in a cell will then put that cell into the correct text format (except for leedi...

How do I format a long number fields as text in an Excel .CSV file
I am creating an Excel .csv text file with a program and I am trying to format a field that contains about 20 numbers as a text filed. When I open the .csv file with Excell that column does not show correctly. It appears that Excel is trying to treat it as a number. It tried bounding the field with double quotes and that doesn't seem to make a difference. The filed still shows up with an "E" towards the right end of the filed that I can't make go away. Cyber, It's probably happening when you open the csv file with Excel, not when the file was written. Open t...

Outlook default text for HTML
Hi all, When I use "send to...mail recipient" to send a file to someone it opens a message window in text mode. When I change this to HTML it defaults to Times New Roman font. How can I make it NOT go to Times New Roman? E.G. something like Arial ? This is very annoying because I have to highlight the entire message, then do multiple clicks and scroll through the entire fonts menu. Can the font default be changed and if so, where ? any help would be greatly appreciated ! Thanks in advance. Mike marvin0069 'at' nc 'dot' rr 'dot' com You can'...

How do I get pictures of certain equipment in Microsoft Visio?
I'm trying to use Visio to help illustrate our network. I know I've seen before where somebody had the exact equipment in his Visio project. How do I get those? Is there a main database with all the equipment, or do I need to go to each individual site and see if they have it? Thanks in advance. unless you are willing to pay for them at third party sites, the best bet is too check with the vendor. you might strart over at john marshall's site (www.mvps.org/visio) al "captmorg11" <captmorg11@discussions.microsoft.com> wrote in message news:336545C1-F340...

Where is the text to speech in excel 2000 #2
I know I have speech on my computer, it is in the control panel but I can't find it any where else. I have tried to search the help in excel and word with no luck. Any help would be great! What you need is to start Narrator. It works with most applications with varing degrees of helpfulness "Hifly" wrote: > I know I have speech on my computer, it is in the control panel but I can't > find it any where else. I have tried to search the help in excel and word > with no luck. Any help would be great! ...

Pasting text with double quotes
I'm trying to paste text that contains double quotes into Excel. Example: "Bob Anderson" 36475tmmn8766 Excel is stripping out the double-quotes upon pasting. I've look everywhere for an option or setting to override this but have been unsuccessful. Does anyone have any ideas? Thanks - Bob A. Some additional info...the stripping only occurs when a double-quote is the first character in the string. If there is more than one quote it will strip out the first two it encounters. On Thu, 31 Mar 2005 18:30:00 -0800, Bob Anderson <banderson1962@yahoo.com> wrote: >...

include string or text value in cell reference
Hi, does anyone know how/if i can include a cell value within a path in a function/formula so i can update it by simply changing cell value, e.g. SUM($A$1, '[E:\folder\stats June.xls]'!sheet1$A$1) so that the 'June' part can change according to a cell value, say F1. So if I change F1 from "June" to "July" then the SUM formula would change to show ....'\stats July' . many thanks in advance, Nelly Use the INDIRECT() function -- Gary''s Student "nelly" wrote: > Hi, > > does anyone know how/if i can include a ce...

I cannot get my printer to print any information
I USED EXCEL 2003 TO GENERATE A WORKSHEET WITH DATA. I CANNOT PRINT IT. WHY? The why could be many things, some of which could be exel issues and some of which could be driver issues, network issues, or others. Can you, for instance, print from other applications to your printer? Have you been able to print from Excel in the past and this is a new problem, or is this your first attempt to print from Excel? -- Y "ANDIAMO" wrote: > I USED EXCEL 2003 TO GENERATE A WORKSHEET WITH DATA. I CANNOT PRINT IT. WHY? ...

wrap text in a chart data table #2
Hi, Im have created a graph, which ive had no problem, but i when i click the option to "show data table" i cannot get the titles to wrap to the box, i have searched but i cannot find an option to wrap the text as i need it for a presentation. I do not want to just simply alter the font size if possible. Is there anyway of doing this? ...

Auto Text of Email Addresses
When i am starting a new email and i go to enter the name of the recipient in the TO: box - i enter the first letter and a bunch of names i have used in the past come up (auto text is the only thing i can assume it is called). How do you go about removing some of these addresses that automatuically come up if you no longer want them>? It's called AutoSuggest ;-) To remove an address from there, simply highlight it by using your arrow keys and press Delete on your keyboard. -- Robert Sparnaaij [MVP-Outlook] Coauthor, Configuring Microsoft Outlook 2003 http://www.ho...

How do I turn a scanned handwritten document into text?
I would like to be able to scan pages in a handwritten journal, and be able to edit them as text in MS Office (OneNote or Word). I have MS Office 2007 + MSO 2003, also OneNote 2007. I use a pen and tablet, so I can manually use handwriting in the Office Programs. I have a scanner. I have tried the Document Imaging program in MSO Tools, that scans a typed document in TIFF format. However, handwritten documents don't seem to work. Surely, there must be a solution Out There? On Jan 3, 4:48=A0am, TeaPatch <TeaPa...@discussions.microsoft.com> wrote: > I would like to be...

VBA
Dear all, I have several charts in a sheet for which I need to change the data ranges. Currently each chart has a different data range, and for each chart the new desired data range is just an straightforward extension of the original (i.e., the new data ranges could be easily calculated from the original ones just by adding a fixed number of rows/ columns). I am therefore trying to implement a macro for updating the data ranges of my charts automatically, but so far I haven't found a way for getting the actual data range of a chart. I guess I'm looking for something like the opposit...

How can I add a two letter prefix to text in cells?
Hi. I need to add a two letter prefix to a large number of data cells that currently have text in them w/o overwritting the current data. For example a column of this text: 106 108 110 202 206 I would need to add the letters "SE" before the numbers. Any quick way to do that? Format-->Cells, Custom. Type the following into the short box: "SE"000 Remember, now, that's not the VALUE of the cell. It's just a VIEW of it. ************ Anne Troy www.OfficeArticles.com "Newbs18" <Newbs18@discussions.microsoft.com> wrote in message news:CA1B7783-EC...

Some accounts don't show up on the Get online statement list
I've set up some new accounts with my financial broker and check "get online statements". But when I go to connect these accounts do not show up in the "Get Statement" List for that institution. What do I need to do to add these to the list? In microsoft.public.money, Steven Friedman wrote: >I've set up some new accounts with my financial broker and >check "get online statements". But when I go to connect >these accounts do not show up in the "Get Statement" List >for that institution. What do I need to do to add these to &g...

How do i make text see thru
I want my background picture to show thru the text, and i want the text the have a smoked glass look, is this possible clare I know how to make the text show through because I asked it here once, click on fill (up top) then "no fill". I use this a lot because otherwise the text box blocks something out or a part of it. As for smoked glass, I'm not sure with Publisher if they have this effect. I just tried it (and I'm still a newbie) I made a text box, wrote TEST on it, made the font grey. Then clicked fill- effects and tried some of the graduants which were in shades of ...

Convert text invoice into a table- please help!
Hi, We have an invoice in text format in excel. I need to convert in a table format to be able to convert it into a pivot I need macros created which can 1) delete blank rows 2) delete rows which start with certain text in a particular (the invoice heading appears frequently in every page) 3) each transaction is in 2 lines- need it to be in one line PAGE ROSANA ALAM 36422299601017 FINANCE CONTROLLER 30/03/10 MICROSOFT GULF FZE LLC MICROSOFT STAFF 1 P O BOX 52244 DUBAI AGN CODE:01 AGN NAME :DNATA TEMPORARY STATEMENT FOR MARCH 2010 DATE TICKET TRAN...

Text "=SMTP:" appended to email addresses
Not sure if this is a server or an Outlook issue, so please bear with me if in wrong place! I've got one user (Outlook 2007) who is finding that when she replies to an email, the text "=SMTP:" is appended to the front of the destination email address, which renders the email undeliverable. ? Any ideas ? "Baz" <Baz@discussions.microsoft.com> wrote in message news:4E9CC0D5-B7C9-44AF-BFB9-54190CEBA96B@microsoft.com... > Not sure if this is a server or an Outlook issue, so please bear with me if > in wrong place! > > I've got one ...

Getting Common Dialog Font ?
Hi guys, Is there a way I can get the font that's displayed in a MessageBox() or a CFileDialog() ? When I create my controls explicitly they have that bold system font. I can set it to MS Sans Serif size 8 to match the dialog boxes created in the resource editor but is that the best way to do it ? It would be cool if there was a function like this: CFont* pFont=GetCommonFont(); Take care, Robert A. "Robert A." <invalid@invalid.org> wrote in message news:eqer0QbGEHA.1292@TK2MSFTNGP12.phx.gbl... > Hi guys, > > Is there a way I can get the font that's displa...

how do i get the hours between these times??
hi! i have the following scenario: if a person works between i.e. 08:00 and 21:00 i need to have a column that says how many hours and minutes it is between 08:00 and 18:00 18:15 and 20:00 20:00 and infinit i also have to have in mind that a person very well can work between i.e. 08:00 and 19:00. someone have a good solution for me =) ? thanks! -- hendersson ------------------------------------------------------------------------ hendersson's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=18427 View this thread: http://www.excelforum.com/showthread.php?th...

Formula to count text and alert me if a text appears more than twi
Hi I have a column of text and I need to be alerted if the same text appears more than twice in the column. The column changes on a regular basis. e.g. Tom Tom Jane Mary Tom "ALERT AN ITEM APPEARS MORE THAN TWICE" Thanks Mike Select the column (say it's Col D), use Data/Validation, change Allow Any Value to Allow Custom, enter =COUNTIF(D:D,D1)=1, then choose an appropriate error message on the error tab if you wish. This won't change any already existing duplicates, but you can find those by tools/auditing/show auditing toolbar, then click the "circle Invali...