Results 1 to 9 of 9

Thread: C++ to VB (I think/Hope)

  1. #1

    Thread Starter
    Member
    Join Date
    Feb 2002
    Posts
    38

    C++ to VB (I think/Hope)

    i'm writing a custom app to pull things out of a Microsoft Exchange server. the HTML part of an email is stored in an RTFHTML format which is then stored in a compressed binary format. converting the RTFHTML to HTML was really easy, now the problem i need to figure out is how to convert the compressed stream to text (RTF.) everywhere i go everyone says to use the WrapCompressedRTFStream method, but that's only available to C++ programmers. there's info on the method here:

    http://msdn.microsoft.com/library/de...drtfstream.asp

    i guess what i would like to know is if it's possible to either access this function through VB in anyway, or if it's possible for someone to create a "wrapper" function that VB could pass through. they both sound like logical ideas, but since i have no clue as to how to do either one.

    thanks for any help!
    Chris Haas
    Web Developer
    Ovation Advertising & Marketing
    p. (608) 785-2460
    e. [email protected]

  2. #2
    Fanatic Member HaxSoft's Avatar
    Join Date
    May 2000
    Location
    Ohio
    Posts
    593
    I think you should post this particular question in either the API section or the C section.

    Your ideas are both very logical and the only obstacle is how to do it.

    In the API and C sections, there are some real good programmers. They can help you.

  3. #3
    Frenzied Member MerrionComputin's Avatar
    Join Date
    Apr 2001
    Location
    Dublin, Ireland
    Posts
    1,616
    You need to declare the API function in order to make it available to Visual Basic (something like this
    VB Code:
    1. Option Explicit
    2.  
    3. Public Declare Function WrapCompressedRTFStream Lib "mapi32.dll" (ByVal lpCompressedRTFStream As Long , _
    4.                           ByVal uFlags As Long , _
    5.                           lpUncompressedStream As Long ) As Long

    Then the function is available to use within your VB code. The memory address of the uncompressed strream is returned to you in the variable lpUncompressedStream which is why this variable must not be declareed using ByVal....

    Hope this helps,
    Duncan
    ----8<---------------------------------------
    NEW - The .NET printer queue monitor component
    ----8<---------------------------------------
    Now with Examples of use

  4. #4
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704
    Wow, one of the lucky few who actually have a tech job in LaCrosse... I'm impressed...

  5. #5

    Thread Starter
    Member
    Join Date
    Feb 2002
    Posts
    38
    thanks a lot MerrionComputin! i'm trying this right now!

    nemaroller, i'm from Milwaukee originally but i'm glad i got a job here. La Crosse is a great city to work in
    Chris Haas
    Web Developer
    Ovation Advertising & Marketing
    p. (608) 785-2460
    e. [email protected]

  6. #6
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704
    Yea I know, spent the first four years of college there....

    finishing up here in Milwaukee..

    Sure miss those bluffs though....

  7. #7

    Thread Starter
    Member
    Join Date
    Feb 2002
    Posts
    38
    i don't blame you. i just came down from the alpine and man is it beautiful up there. i did my time in winona (another great city, btw) and started working almost immediately after.
    Chris Haas
    Web Developer
    Ovation Advertising & Marketing
    p. (608) 785-2460
    e. [email protected]

  8. #8
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704

    This is south toward Grandad from the NOAA weather station.

  9. #9

    Thread Starter
    Member
    Join Date
    Feb 2002
    Posts
    38
    nice pic! well you can see the river anytime you want, here's our company's river cam:

    http://www.ovationadvertising.com/rivercam.asp

    and here's a 6 day time lapse we did once (5MB WMV stream)

    http://percidae.ovationmarketing.com...erout4-250.wmv
    Chris Haas
    Web Developer
    Ovation Advertising & Marketing
    p. (608) 785-2460
    e. [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