YetAnotherForum
Welcome Guest Search | Active Topics | Log In | Register

Runtime error '8364': Data Set has not been opened for modification Options · View
CodeMonkey
#1 Posted : Monday, February 21, 2011 9:47:12 PM
Rank: Newbie
Groups: Member

Joined: 2/21/2011
Posts: 3
Whenever I try to change the DataSourceName property of an ODBCDataset, I get a message box that says "Runtime error '8364': Data Set has not been opened for modification". How do I open it for modification? I'm trying to modify several datasets using VBA. When I do it with the dialog box in PB, it locks up after about the third data set.
Sponsor  
 

OSIsoft vCampus is a subscription-based, online offering that consists of providing everything people need to develop applications on the PI System.
We invite you to take a "tour" of the OSIsoft Virtual Campus - also feel free to consult the FAQ  or contact OSIsoft vCampus for more details.
CodeMonkey
#2 Posted : Tuesday, February 22, 2011 2:29:54 PM
Rank: Newbie
Groups: Member

Joined: 2/21/2011
Posts: 3
I figured it out. You have to use ThisDisplay.Datasets.GetDataset instead of ThisDisplay.Datasets.Item. Also, PI created duplicates of all my datasets (still haven't figured that one out) so calling, e.g., GetDataset("DSN_FOO") would only retrieve one of them. To loop through all datasets, I had to reference them by integers.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.