Quantcast
Channel: VBForums - CodeBank - Visual Basic 6 and earlier
Viewing all articles
Browse latest Browse all 1553

How to share a variable between a OCX and a program?

$
0
0
Hi

I have a program with a few custom controls and (my mistake) I'm using a global variable shared between the controls and the program. Now I want to compile the controls to an independent ocx so I guess I should use another way to work with that variable. Probably a way should be to create a procedure in the OCX that I could call with the variable value (something like myocx.setvariable("xxxx")). The OCX neds the variable but does not change it, just use the value.

Any better idea to get access from the ocx to the global variable in my program?

Thks

Viewing all articles
Browse latest Browse all 1553

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>