locked
on webservice in IIS, VS2010, I can't get the return-value of funtion on DLL ... RRS feed

  • Question

  • 1

    PICTURE No1.: the project property screen in VS2010

    -----------------------------------------------------

    I used the sharedmemory on my webservice project like following.

    .

                    IntPtr hMapFile = OpenFileMapping(                                              // Open the named file mapping.                                                                                     FileMapAccess.FILE_MAP_ALL_ACCESS,                                                                                     false,                                                                                     str_맵파일명);

    -----------------------------------------------------

    CASE 1:

    after I select the radiobutton [Use visual studio development Server] on picture No.1, I ran the my webservice.

    I could get the correct return-value of hMapFile  from the "OpenFileMapping" that is "1316"                                                                                  

                                                   

    CASE  2:

    but when I ran my webservice after selecting the radiobutton [Use Local IIS Web server] on picture No.1,

    I could get the incorrect return-value of hMapFile   that is "0"

    .

    Q1. Could I get the samplecode in C# to solve this trouble??(CreateFileMapping, OpenFileMapping with SECURITY code)

    or How do I change the setting in IIS 7.0.

    Tuesday, November 13, 2012 5:55 AM

Answers

All replies

    1. Do you need to use ASMX web services? That's a legacy technology that shouldn't be used for new code. Are you stuck using .NET 2.0?
    2. Good Luck getting shared memory to work in a multi-threaded environment that has no doubt never imagined someone using unmanaged shared memory in a web service.


    John Saunders
    WCF is Web Services. They are not two separate things.
    Use WCF for All New Web Service Development, instead of legacy ASMX or obsolete WSE
    Use File->New Project to create Web Service Projects

    Saturday, November 17, 2012 4:03 AM
    Moderator
    • Marked as answer by Delight72 Thursday, November 22, 2012 12:05 AM
    Thursday, November 22, 2012 12:05 AM