The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Shooter on May 17, 2012, 06:15:15 PM

Title: MasmED and C Files
Post by: Shooter on May 17, 2012, 06:15:15 PM
Trying to search the forum for "C Programming" files doesn't exactly yield much due to the "c" being in a ton of words.

Also, I apologize if this is in the wrong part of the forum.


[li]Is there an addon/plugin that can take C files in directly?
[/li]
[/list]

(Also, is there a set of instructions to follow as to inserting lists into a post here on the forum? It took me forever to figure out how to do just this simple list, but I wanted numbering so people could easily refer to Item #1 or Item #2.)

Thanks a bunch,
-Shooter
Title: Re: MasmED and C Files
Post by: jj2007 on May 17, 2012, 08:19:57 PM
Hi Shooter,

What exactly is the problem there? C files in Unix/Linux format, i.e. Lfs instead of CrLfs? Unicode? UTF8? Special characters should not be a problem for most editors...

Can you zip a sample and post it here?
Title: Re: MasmED and C Files
Post by: dedndave on May 17, 2012, 08:53:47 PM
he is probably refering to line-feed with no carriage return
i have seen a number of them - lol
Title: Re: MasmED and C Files
Post by: hfheatherfox07 on May 17, 2012, 09:35:55 PM
I would not be the same (foobar.c) that I just tried Goggling ?

7th post down


Spare us this virus crap.


LOL  :tdown


Sorry hutch ....
Title: Re: MasmED and C Files
Post by: Shooter on May 18, 2012, 03:10:58 PM
Here is one file that I couldn't open in Notepad.
Title: Re: MasmED and C Files
Post by: dedndave on May 18, 2012, 03:56:58 PM
yah - line feeds without carriage returns   :P

NotePad++ opens it with no problem - and can reformat it for you (Edit menu - EOL Conversion)
http://notepad-plus-plus.org/
Title: Re: MasmED and C Files
Post by: Shooter on May 18, 2012, 04:09:42 PM
Quote from: dedndave on May 18, 2012, 03:56:58 PM
yah - line feeds without carriage returns   :P

NotePad++ opens it with no problem - and can reformat it for you (Edit menu - EOL Conversion)
http://notepad-plus-plus.org/

Thank you!!  :U
Title: Re: MasmED and C Files
Post by: jj2007 on May 18, 2012, 04:58:37 PM
Opens fine in RichMasm. I just resaved it - now it will open in normal Notepad.
Title: Re: MasmED and C Files
Post by: MichaelW on May 18, 2012, 05:30:11 PM
It views correctly under SciTE, and after using the Convert Line End Characters option and saving it, it views correctly with Notepad.
Title: Re: MasmED and C Files
Post by: Shooter on May 18, 2012, 05:33:46 PM
Why doesn't it open correctly in MasmED?
Title: Re: MasmED and C Files
Post by: jj2007 on May 18, 2012, 06:26:11 PM
Good question. I can't speak for the others, but RichMasm and qEditor use the RichEdit control, which apparently sets automatically the right switches.
Title: Re: MasmED and C Files
Post by: MichaelW on May 18, 2012, 11:53:26 PM
Perhaps MasmEd is keying on the CR (that may not be present) instead of the LF (that should always be present).
Title: Re: MasmED and C Files
Post by: hfheatherfox07 on May 19, 2012, 12:01:12 AM
Quote from: Shooter on May 18, 2012, 03:10:58 PM
Here is one file that I couldn't open in Notepad.


Check the way that notpad2 opens it .... http://www.masm32.com/board/index.php?PHPSESSID=19a0f4a80bfe3f2db878b1aa58f908df&action=dlattach;topic=18686.0;id=10567
Title: Re: MasmED and C Files
Post by: mineiro on May 19, 2012, 04:09:13 AM
With this version of MasmEd opened, click on menu "File","Open as Hex", and point to that file.
Click on menu "Edit","Replace", in field "find what" put "0a" and field "replace" put "0d0a". Click in "Hex" inside "Type" group.
Click on button "Replace All", and save your file. After, close it.
Now your file is not truncated.
To reverse to original, Find for "0d0a" and Replace to "0a" in hex mode.

MasmEd version 1.0.4.0 handle fine these files.
Title: Re: MasmED and C Files
Post by: Shooter on May 19, 2012, 09:31:59 PM
Quote from: mineiro on May 19, 2012, 04:09:13 AM
With this version of MasmEd opened, click on menu "File","Open as Hex", and point to that file.
Click on menu "Edit","Replace", in field "find what" put "0a" and field "replace" put "0d0a". Click in "Hex" inside "Type" group.
Click on button "Replace All", and save your file. After, close it.
Now your file is not truncated.
To reverse to original, Find for "0d0a" and Replace to "0a" in hex mode.

MasmEd version 1.0.4.0 handle fine these files.

Thanks!!  :U