On Tue, 28 Apr 2020 at 18:18, martin schatzmayr < address@hidden> wrote: Gesendet von Mail für Windows 10 On Tue, 28 Apr 2020 at 17:30, martin schatzmayr <address@hidden> wrote: Gesendet von Mail für Windows 10 On Tuesday, 28 April 2020, Nicholas Jankowski <address@hidden> wrote: Used buil-in-editor to create same code – on running I had the same issue . When I open the file ami.m I see the expected code . I have uninstalled octave and reinstalled it again ( octave 5.2.0 -w64-installer.exe) still no change
Please always Reply All to keep the mailing list copied. So just to be clear, you have used both notepad++ and the built-in Octave editor to create the same file, and get the same non-ascii output from _both_ programs? But only after saving the file? And if you open the same file in both programs you see the expected code not the garbage characters I saw? For notepad++, are you using the version that comes with Octave or do you have another version installed? If it does the same in both Notepad++ and also the Octave Editor, what happens if you try saving it in another program like the Windows Notepad text editor? What happens when Octave tries to run it? What do you see if you open a file saved in Octave's editor in Windows Notepad? Within Octave, also confirming: if you type the text, save it, and press F5 to run it, do you get the same error? Are you using any non-default Windows Language or Keyboard settings?
Please zip and upload the file you created. That should ensure it is not codepage translated during the transfer and will allow us to inspect it. Cheers Ian Hi I have created this file with the built-in-editor of octave. As suggested the file is zipped
So the problem is codepage-related. Please open a powershell window and type: [System.Text.Encoding]::Default And tell us what you obtain. Ian That is the output: PS C:\Users\Martin Schatzmayr> [System.Text.Encoding]::Default IsSingleByte : True BodyName : iso-8859-1 EncodingName : Western European (Windows) HeaderName : Windows-1252 WebName : Windows-1252 WindowsCodePage : 1252 IsBrowserDisplay : True IsBrowserSave : True IsMailNewsDisplay : True IsMailNewsSave : True EncoderFallback : System.Text.InternalEncoderBestFitFallback DecoderFallback : System.Text.InternalDecoderBestFitFallback IsReadOnly : True CodePage : 1252
This is identical to what I receive, which suggests that in some circumstances Octave and notepad++ editors choose the wrong encoding based on something else. Another possibly relevant internationalisation setting in windows is:
Get-WinSystemLocale
LCID Name DisplayName ---- ---- ----------- 2057 en-GB English (United Kingdom)
Regarding how to get you using Octave,:
1. Have you tried creating files using the windows notepad editor? 2. Try copying and pasting from the Octave command window to the editor window and saving as a .m file and running.
Hoping something here is helpful!
Cheers... Ian
Last possibility
Hi i have reinstalled notepad ++ on my computer. When use notepad ++ to write a program I can run this program from the command-line ! When i write the same program with octave’s built-in-editor I still get the same old error code
|