Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to create common memory for two ocx

How to create common memory for two ocx

Scheduled Pinned Locked Moved C / C++ / MFC
performancetutorialquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Surendra Vishwkarma
    wrote on last edited by
    #1

    Hi, I have a web based application in which we have 8 ocx for displaying images. Currently images are loaded from CD .But now we want to allocate some memory in some of the 8 ocx we have and in this memory we will save maximum files that we could. Then we want to access this memory buffer using cmemfile. So we need to create a common memory which can be accessed by all the ocx on the page. I dont know how to create such memory? And then how to access the memory through different ocx. Please provide me some inputs on this..

    Surendra Vishwkarma

    M 1 Reply Last reply
    0
    • S Surendra Vishwkarma

      Hi, I have a web based application in which we have 8 ocx for displaying images. Currently images are loaded from CD .But now we want to allocate some memory in some of the 8 ocx we have and in this memory we will save maximum files that we could. Then we want to access this memory buffer using cmemfile. So we need to create a common memory which can be accessed by all the ocx on the page. I dont know how to create such memory? And then how to access the memory through different ocx. Please provide me some inputs on this..

      Surendra Vishwkarma

      M Offline
      M Offline
      Matthew Faithfull
      wrote on last edited by
      #2

      You might want to look up the CoTaskMemAlloc function and also Memory Mapped Files. Your biggest problem is likely to be browser security. It will not like your embedded controls accessing memory outside their normal scope. You might even have to consider replacing the OCX with Javascript but hopefully not:~ . It should be possible to write script on the page which can access the controls and negotiate between them which one will own/create a memory mapped file and then communicate it's handle to the other controls.

      Nothing is exactly what it seems but everything with seems can be unpicked.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups