# Can't edit sketch file!

**URL:** <https://forum.arduino.cc/t/cant-edit-sketch-file/49797>\
**Category:** Troubleshooting\
**Created:** [January 21, 2011, 6:49am UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797 "2011-01-21T06:49:19Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [January 21, 2011, 6:49am UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797/1 "2011-01-21T06:49:19Z")

</div>

Forum,

Total noob here with UNO and Macbook Pro.

I open the BLINK sketch, upload it, led blinks... Life is good.

Now, when I try to edit the file .. Nothing happens on screen.  
I can move the cursor around with the mouse and the keyboard but again, I can't make any modifications.

I have done a 'save as..' to my desktop to make sure it's not write protected. No change.  
I have done 'verify disk permissions'. No change (but do get some errors on java... hmmmm)  
I have created a blank sketch... Same symptoms

Here's something interesting when using 'comment/uncomment'. I get the following java errors:

Exception in thread "AWT-EventQueue-0" java.lang.InternalError: Text component read only  
at processing.app.syntax.JEditTextArea.setSelectedText(JEditTextArea.java:1269)  
at processing.app.Editor.handleCommentUncomment(Editor.java:1730)  
at processing.app.Editor$TextAreaPopup$7.actionPerformed(Editor.java:2629)  
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028)  
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351)  
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)  
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)  
at javax.swing.AbstractButton.doClick(AbstractButton.java:389)  
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1223)  
at com.apple.laf.AquaMenuItemUI.doClick(AquaMenuItemUI.java:137)  
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:1264)  
at java.awt.Component.processMouseEvent(Component.java:6352)  
at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)  
at java.awt.Component.processEvent(Component.java:6117)  
at java.awt.Container.processEvent(Container.java:2085)  
at java.awt.Component.dispatchEventImpl(Component.java:4714)  
at java.awt.Container.dispatchEventImpl(Container.java:2143)  
at java.awt.Component.dispatchEvent(Component.java:4544)  
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)  
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4282)  
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)  
at java.awt.Container.dispatchEventImpl(Container.java:2129)  
at java.awt.Window.dispatchEventImpl(Window.java:2478)  
at java.awt.Component.dispatchEvent(Component.java:4544)  
at java.awt.EventQueue.dispatchEvent(EventQueue.java:635)  
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)  
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)  
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)  
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)  
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)  
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Might this be the source of the problem?

Suggestions anyone?

Thanks!

Rob

---

<div class="post-metadata">

**Author:** ![u0421793](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/u0421793/32/214044_2.png) [@u0421793](https://forum.arduino.cc/u/u0421793)\
**Post date:** [January 21, 2011, 10:49am UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797/2 "2011-01-21T10:49:08Z")

</div>

Are you the only user account on that MacBook, or are there other users?

---

<div class="post-metadata">

**Author:** ![smeezekitty](https://avatars.discourse-cdn.com/v4/letter/s/c4cdca/32.png) [@smeezekitty](https://forum.arduino.cc/u/smeezekitty)\
**Post date:** [January 22, 2011, 1:09am UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797/3 "2011-01-22T01:09:54Z")

</div>

I know it sounds too simple but try closing the arduino software and restarting it.  
Sometimes strange bugs occur that can be resolved by restarting the software.  
BTW I sent you a personal message.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [January 22, 2011, 3:49am UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797/4 "2011-01-22T03:49:11Z")

</div>

I'm the only user on the system and have admin rights.

Stopping/starting or... reinstalling for that matter.. does not help either.

:-[

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [May 6, 2021, 8:20pm UTC](https://forum.arduino.cc/t/cant-edit-sketch-file/49797/5 "2021-05-06T20:20:57Z")

</div>


