Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Persistance

Status
Not open for further replies.

elziko

Programmer
Nov 7, 2000
486
GB
I have created an ActiveX control and have attempted to persist it's properties using a property bag. This seems to work fine when I've got a single instance of the control on a form.

However when I have two controls (or more) any properties that I set (using my property page) for the second control overwrite the properties that I have chosen for the first control.

Now, I know that the persisted data is stored in the .frm file so I had a look inside it and sure enough there are a set of properties (the last four are my own defined properties) stored for both the instances of my control but they are the same. How do I make sure that the properties of the correct control are updated.

Begin ActiveX_PDL.Standard Standard2
Height = 2565
Left = 240
TabIndex = 1
Top = 3330
Width = 3585
_ExtentX = 6324
_ExtentY = 4524
Axis1_Var = "TestTime"
Axis2_Var = "PEN"
Axis3_Var = "ROT"
Test_ID = "BT104A"
End
Begin ActiveX_PDL.Standard Standard1
Height = 3135
Left = 90
TabIndex = 0
Top = 60
Width = 4335
_ExtentX = 7646
_ExtentY = 5530
Axis1_Var = "TestTime"
Axis2_Var = "PEN"
Axis3_Var = "ROT"
Test_ID = "BT104A"
End

Anyone any good with persistance? I am confused.s-)

Many Thanks

elziko
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top