Educational Software Thread, Does anyone else use MS Small basic and Scratch on the same PCs? in Technical; One of our ICT teachers discovered an issue on friday that scratch 1 and small basic use the same file ...
23rd June 2013, 06:32 PM #1
Does anyone else use MS Small basic and Scratch on the same PCs?
One of our ICT teachers discovered an issue on friday that scratch 1 and small basic use the same file extensions (.sb). They also found that files could get corrupted if they were opened in the wrong program. I can't reproduce this corruption though, I can't see how they managed it.
Does anyone have any clever ideas to work round this? The only ways I can see are:
* Ask users to right click on the file and choose open with. You could argue that that's not particularly hard, but its not a very elegant or reliable solution.
* Upgrade to scratch 2 - but this is only web based at the moment. Not ideal. version 2 uses .sb2
* Write a small program to figure out what the file is before opening it in the correct program. I found code on this page to do this: Get Windows to treat files with the same extension differently - Super User
I don't really want to have to maintain too many school-specific fixes like that if I can avoid it. I guess we will have to bite the bullet one way or another.
IDG Tech News
23rd June 2013, 06:48 PM #2
Well depends what you want from the end result I guess. If you don't want to let them have the option to open it at all, you could always remove .sb from any auto-associations. e.g. Have to open it through program.
As you said run a program in the middle to work it out.
The other option, which is a lot "smoother" but will take more work, is edit the scratch source and put a new filetype in it. Then there's no chance of opening the wrong one unless they physically force it to. Example as per scratch forums:
Then just put an association to the new filetype to scratch etc.
fName _ (self nameFromFileName: fName), '.sb'. "Change .sb to your file extension"
(fName size = 0 | (dir fileExists: fName , '.sb') not) ifTrue: [^ self saveScratchProject]. "Again change .sb"
projectName _ FileDirectory localNameFor: (fName, '.sb'). "Once again change .sb"
"Add this line change .sb to your file extension also change 3 to the length of your extension"
(s asLowercase endsWith: '.sb') ifTrue: [s _ s copyFrom: 1 to: s size - 3].
list _ ScratchFilePicker new extensions: #(scratch sb). "Add your extension"
Or wait till summer:
Will there ever be a downloadable Scratch 2.0 editor?
Yep! But it won't be ready until this summer. If you'd like to help beta test it, we'll post an announcement when it's ready to try out.
Thanks to Steve21 from:
Chris_Cook (23rd June 2013)
24th June 2013, 11:09 AM #3
We've put in a file association by year group, so for years 7 and 8, .sb opens Scratch, for year 9 it opens Small basic.
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)