From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "deech" Newsgroups: gmane.emacs.help Subject: Newbie: Unable to write a custom function Date: 2 Dec 2006 13:23:26 -0800 Organization: http://groups.google.com Message-ID: <1165094606.836594.304590@j72g2000cwa.googlegroups.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1165095691 30456 80.91.229.2 (2 Dec 2006 21:41:31 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 2 Dec 2006 21:41:31 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Dec 02 22:41:29 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1Gqcbt-0001PE-E2 for geh-help-gnu-emacs@m.gmane.org; Sat, 02 Dec 2006 22:41:25 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gqcbt-00079Z-3z for geh-help-gnu-emacs@m.gmane.org; Sat, 02 Dec 2006 16:41:25 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!postnews.google.com!j72g2000cwa.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 19 Original-NNTP-Posting-Host: 24.182.169.51 Original-X-Trace: posting.google.com 1165094612 15283 127.0.0.1 (2 Dec 2006 21:23:32 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Sat, 2 Dec 2006 21:23:32 +0000 (UTC) User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.8) Gecko/20061115 Ubuntu/dapper-security Firefox/1.5.0.8,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: j72g2000cwa.googlegroups.com; posting-host=24.182.169.51; posting-account=T7vKIQ0AAACZ7mcQD4-iXJahrK6PRJNP Original-Xref: shelby.stanford.edu gnu.emacs.help:143610 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:39212 Archived-At: Hi all, I am new to Emacs. I have written a new search function into my .emacs file but I am unable to invoke it with M-x when I restart Emacs. There are no error messages when Emacs starts up. Here is the code: ;;Search backwards from a point for a string. If found delete ;;all characters from that string to the point. ;;Eg Given the argument 't', 'alligator' becomes 'alliga' (defun isearch-backward-tophrase () (set-mark-command ()) (isearch-backward ) (kill-region ()()) ) Any idea what I am doing wrong? Thanks... Deech