CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2003
    Location
    Mumbai
    Posts
    7

    Question Passing complex types to methods of queued component

    I am trying to pass an object of a class to a method in Queued component. I tried doing this first by making use of XmlSerializer. It worked out fine. Currently I am trying to achieve the same by implementing the IPersistStream interface in my class. Also I am allowing unsafe code blocks in my code as I am making use of IPersistStream interface.
    When I try to register this queued component using the regsvcs utility I get a warning which is of the following format:

    Type library exporter warning processing 'QCTest.IPersistStream.Load(pStm), QCTe
    st'. Warning: Type library exporter could not find the type library for System.
    Runtime.InteropServices.UCOMIStream. IUnknown was substituted for the interface

    Also my client application is not able to execute. Can anyone please tell me what the problem is?
    Reena Pramodh
    Mail To: [email protected]

  2. #2
    Join Date
    Nov 2002
    Location
    Singapore
    Posts
    1,890
    hi,
    Question here is does your Queue component tries to fetch some run time dlls.?

    have you used "BinaryFormatter"
    in your app. (but it has nothing to do with above Q.)

    check the following article,
    http://www.developer.com/tech/article.php/620091




    When I try to register this queued component using the regsvcs utility I get a warning which is of the following format
    What type of COM Component is ? what type of typelibrary. What type of Threading Model you are using ?


    what type of client application you have ? is it I.E based. I mean to say is does Internet explorer is trying to call
    IPersistStream::Load() on the stored xml
    document ???

    thanks
    -Paresh
    - Software Architect

  3. #3
    Join Date
    Mar 2003
    Location
    Mumbai
    Posts
    7
    Hi,
    Firstly I have developed the queued component in C#. My queued component is not fetching any runtime dlls nor is it using the BinaryFormatter. I have a class Sample that implements the IPersistStream interface so that an object of the class can be passed to the queued component. i.e.

    public class Sample:IPersistStream
    {
    public string str_message;
    }
    I have a method in my queued component that takes an object of Sample as its parameter.

    [InterfaceQueuing]
    public interace IMyQueue
    {
    void displayMessage(Sample obj);
    }

    public class MyQueue: ServicedComponent, IMyQueue
    {
    void displayMessage(Sample obj)
    {
    MessageBox.Show(obj.str_message, "Message shown");
    }
    }

    This queued component when I try to register after compilation gives me the warning that I mentioned earlier. The client application that I am using is a simple C# console application.
    Reena Pramodh
    Mail To: [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured