Cannot edit files in primal script

Support for all customers who have purchased a PrimalScript product license. This forum does not offer a response time guarantee.
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
User avatar
huginson
Posts: 5
Joined: Thu Nov 05, 2015 8:43 pm

Cannot edit files in primal script

Post by huginson » Wed Aug 16, 2017 6:17 am

PrimalScript Version 7.3.103
64X Version
Windows 10 X64

When i open a script a.g.a d:\wamp64\www\index.php. Primalscript will not let me edit in the scripts.(like keyboard is locked, but i can move cursor around)

The status bar is saying [Ready Ascii BLOCK]. I suspected it might have been files comming from another Source and that the file had to be unblocked.
At first 3 files was blocked and i removed the Block from all of them. However....PrimalScript is still treating the files as blocked. Does it have some kind of cache on Block?, No other program is treating these files as blocked. Any way to turn of that feature in PrimalScript ?

User avatar
huginson
Posts: 5
Joined: Thu Nov 05, 2015 8:43 pm

Re: Cannot edit files in primal script

Post by huginson » Wed Aug 16, 2017 6:25 am

Well i found a workaround even if it is annoying. Open in Primalscript. Save it, Close file and reopen. Then the Block is gone on the status bar.

User avatar
Alexander Riedel
Posts: 6361
Joined: Tue May 29, 2007 4:43 pm

Re: Cannot edit files in primal script

Post by Alexander Riedel » Wed Aug 16, 2017 7:37 am

Blocking files that come from the internet or another computer is not a PrimalScript feature, it is a Windows feature. Windows does not allow editing (saving that is) or executing files that have come from an outside source. PrimalScript, PrimalPad and PowerShell Studio alert you to the existence of such a lock via the status bar and by treating the file as if it was read-only, which it effectively is. We also do not allow execution of such script files as a security measure.
If you remove the lock attribute outside the application you do need to reload the file, that is correct.
The easier way however is to unblock the file within PrimalScript:
Right click on the file tab and click on the "Blocked" menu topic with the check mark.
unblock.png
unblock.png (89.53 KiB) Viewed 2831 times
PowerShell Studio has a similar context menu item. The block/unblock feature for PrimalPad is located on the ribbon interface.
Alexander Riedel
SAPIEN Technologies, Inc.

User avatar
huginson
Posts: 5
Joined: Thu Nov 05, 2015 8:43 pm

Re: Cannot edit files in primal script

Post by huginson » Thu Aug 17, 2017 9:17 pm

Thank you Alexander.

I know about the Windows "feature" of blocking files, however PrimalScript kept saying it was blocked even after i removed the block in windows. It did not help to reload the file (my reload method was to close the file and reopen, i did not know about the reload feature in PrimalScript then), i had to save it in Primalscript first.

Thank you so much for the tip about unblocking files in PrimalScript, i did honestly not know you could right click on the tabs, and wow theres all that stuff i been looking for lol. Unblocking there worked like a charm :-)

After downloading my work to my home computer this time i ran "gci d:\(mypath) -recurse | unblock-file" in powershell to unblock all files before starting to work.

Again thank you