Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1064129
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T18:53:06+00:00 2026-05-16T18:53:06+00:00

Well, it’s been several hours I’m lost… IXSLTemplate::putref_stylesheet doesn’t document any error except E_FAIL.

  • 0

Well, it’s been several hours I’m lost…

IXSLTemplate::putref_stylesheet doesn’t document any error except E_FAIL.

However in my case putref_stylesheet returns E_INVALIDARG. GetErrorInfo() is only redundant telling me that the “Argument is invalid”. So I am not left with much information.

However my code is pretty close to all examples I found on the web and msdn.
And it does something like:

void xsltProcessing(MSXML2::IXMLDOMDocument* pXmlDoc, MSXML2::IXMLDOMDocument * pXslDoc)
{
    IXSLTemplatePtr pTemplate;
    pTemplate.CreateInstance( _T( "Msxml2.XSLTemplate" ));
    pTemplate->putref_stylesheet(pXslDoc);
    //...
}

As there is not much documentation for putref_stylesheet. Do you have any idea what could go wrong for it to return E_INVALIDARG ?

My pXslDoc is a IXMLDOMDocument I have loaded from static const strings with success.

Any clue ? ( I guess it’s pretty vague a question, but it’s been hours I am searching )

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T18:53:07+00:00Added an answer on May 16, 2026 at 6:53 pm

    Are you loading pXslDoc asynchronously perhaps?

    The default behaviour for IXMLDOMDocument objects is to load asynchronously, so it is possible that the pXslDoc has not finished loading when you call putref_stylesheet().

    Adding the following code before you load pXslDoc would fix this problem, if it is what you are suffering from:

    pXslDoc->put_async(VARIANT_FALSE);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Well it's not realy causing any errors. Anyways i'm sending ajax request and getting
Well i have var message , which has any type of character... I replace
Well, I've been programming for VB.NET for a while, and now I am interested
Well the subject is the question basically. Are there any version control systems out
Well, i have such-like code that prevent select all action from keyboard: $(document).keydown(function(e){ //
Well I think this is kinda dumb but, I wonder if there's any way
Well, first I know that this question was already asked several times. But I
Well...I feel absolutely stupid. Here's why: I have been using some library functions I
Well, I followed the instructions here , but I get a compilation error when
Well, my problem is quite strange, because it really doesn't make sense. 1)I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.