LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

badly formed pathname error popup whenever the IDE tries to save *.cws file.

Hi all,

 

I get an error popup when I create a new project as follows:

 

Cannot create temporary file in directory "~~~"
(Badly formed pathname)

 

The popup keeps showing when I build the project and quit the IDE, etc. So I guess it happens whenever it tries to make *.cws file.

 

When I close the window, it shows the error popup first and then it says, "The workspace was not saved. Do you want to discard the changes or save the workspace under a different name", and if I choose to save as and another folder to save, it shows the error popup again and quit immediately.

 

It's very annoying. This happens since yesterday, and I didn't recognize the problem so far because it doesn't occur for existing projects.

 

I tried to repair the software packages using the NI Package Manager, which didn't work, and remove all the NI products from my PC and then reinstall, but had no luck.

 

How can I fix this problem? Is there anybody who had the same problem? I found some posts here but the situation seems not exactly same as mine.

 

Sorry for my poor English, I hope my intention is well conveyed.

 

Thanks!

0 Kudos
Message 1 of 10
(2,274 Views)

遇到同样的问题,可能是更新Windows 11 22H2后出现的。谁有解决办法?

0 Kudos
Message 2 of 10
(2,227 Views)

I don't know Chinese, but Goggle translator gave me this:

 

Had the same problem, probably after updating Windows 11 22H2. Does anyone have a solution?

 

The version of the Windows I'm using now is Windows 11 Pro 22H2 which is updated in 9/21/2022. I doubt the problem occurred after then.

 

Thanks anyway.

0 Kudos
Message 3 of 10
(2,213 Views)

Not just .cws file, all the files(.c, .h etc) have this error.

There are two solutions, the first you should use windows 11 21h2 version, another you can use labwindows oler version(forexample cvi 9.0).

0 Kudos
Message 4 of 10
(2,190 Views)

Thank you for your answer. I hope the NI developers fix the problem asap. I almost give up to use it. 😞

0 Kudos
Message 5 of 10
(2,179 Views)

That's a weird problem. Have you opened you .cws and .prj files in a text editor to make sure there isn't some garbage in there ? Remember that there was no UTF-8 until version 2020... It should be plain ASCII.

0 Kudos
Message 6 of 10
(2,122 Views)

It happens only when I create a new project. I tried to create a new project in a totally new folder under both of user folder and root (C:\) folder and still had same problem.

 

As I described above, it doesn't occur at existing projects. Only happens for new project. I think this is kinda bug that may have been caused by the Windows major update.

 

Thank you for your reply!

0 Kudos
Message 7 of 10
(2,109 Views)

I have the same. But if in Windows I create .prj, .uir, .c, cws etc. and I will overwrite them with those newly created in LabWindows, it works. The rest of the files are saved without any problem.

0 Kudos
Message 8 of 10
(2,055 Views)

Oh, if so, it can be a workaround for now. I'm gonna give it a try. Thank you! 😄

0 Kudos
Message 9 of 10
(2,037 Views)

KB5018418 for windows11 22H2 has solved this problem.

0 Kudos
Message 10 of 10
(1,977 Views)