DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Channel write protection - still there after using ChnValExpand

Solved!
Go to solution

Hi,

When I load certain datafiles, some time channels appear as write protected.  I use ChnValExpand which appears to work (the little symbol disappears from the channel name).  However, the channels remain protected and I am unable to write to them.  How can I remove the write protection? 

Any help is appreciated

Thanks

Thomas

 

0 Kudos
Message 1 of 3
(2,681 Views)
Solution
Accepted by topic author mrme

Hi Thomas,

 

It seems that this is a bug. If you some similar code like this below, the you get an error regarding write protection:

dim oChn
set oChn = Data.Root.ChannelGroups(1).Channels(1)
call ChnValExpand(oChn)
oChn(1) = 5

The workaround is to redefine the object variable oChn like this:

dim oChn
set oChn = Data.Root.ChannelGroups(1).Channels(1)
call ChnValExpand(oChn)
set oChn = Data.Root.ChannelGroups(1).Channels(1)
oChn(1) = 5

The all is fine.

 

Greetings

Walter

 

0 Kudos
Message 2 of 3
(2,669 Views)

Hi Walter,

 

Thanks!

 

Thomas

0 Kudos
Message 3 of 3
(2,614 Views)