From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot create storage target

I'm also getting the "Cannot create storage target" error when using DataFileSave to overwrite a TDM file on a NAS.  I verified that I have privileges to delete the file from the computer in question.  Anyone else figure out a solution to this?

0 Kudos
Message 11 of 17
(1,002 Views)

I was not able to work around the "Cannot create storage target error" within a reasonable amount of time, even after confirming that I am able to save the file manually from DIAdem.  I also confirmed I was able to create/delete new files in the directory.  I ended up scripting an unsatisfying workaround that opens a TDM file, changes a property for each group, saves the TDM file to a Temp directory, deletes the source file, then copies the temp file back to the source directory.  This is the equivalent of opening a file, changing it as desired, and saving it...

0 Kudos
Message 12 of 17
(987 Views)

Hello,

Unfortunately I can't reproduce the described behaviour on my computer.
Which DIAdem version do work with?
Please try this setting.
- Open the DIAdem Settings dialog, select NAVIGATOR, page "Loading Behavior"
- Change to "Always load bulk data" (Currently "Load bulk data on modification of channel data" might be set").
Please let me know if it helped.

Regards

0 Kudos
Message 13 of 17
(974 Views)

Hi Thomas,

I changed the loading behavior as you suggested, but still no luck.  The code I'm using is as follows:

 

Call DataFileLoad(sLine, "TDM", "Register")
IF GlobUsedChn > 0 THEN
Call RefreshPortal()
Msg = HdrMsg & "Saving TDM file..."
Call MsgBoxDisp(Msg, "MB_NOBUTTON", "MsgTypeNote", 0, 0, 1)
Call ChangePropVal(sPropChngName, sNewPropVal)
Call DataFileSave(sLine, "TDM")

 Cannot create target error 170913.png

The data is loaded and the desired property changed correctly, but cannot save back to the same file from the script.  This is DIAdem 2017.

 

Chris

0 Kudos
Message 14 of 17
(969 Views)

Hello Chris,

When loading a file with DataFileLoad() with using the import parameter "Register", the file will be opened with write protection. In this mode, saving to the same file is not possible. Changing channel properties is also not possible because they are write-protected. If you want to edit the channels or save the changes to the same file you have to expand the channels first.
The parameter "register" will be often used for large data sets in oder to get a quick view of the data.

In your case please try to use the DataFileLoad command without the register parameter.
Please also switch back to the previously set loading parameter in the DIAdem settings.

Please let me know if it helped

Regards 


Message 15 of 17
(964 Views)

That did it!  I just saw "Register" in an example without any explanation that it opens the file as "write-protected".  Thank you for sorting this out Thomas.

-Chris

0 Kudos
Message 16 of 17
(962 Views)

Thanks for the reply and Greetings
Thomas

0 Kudos
Message 17 of 17
(950 Views)