「Acet-str-m-find」の版間の差分

提供:GizmoLabs - だいたい CAD LISP なサイト
(ページの作成:「{{AutoLISP}} ; 構文 : (acet-str-m-find ''what'' ''string'' ) ; 機能 : what が出現する文字列を返し、見つかったすべての位置リストを返す。 ; 引数 :* what… 検索する文字列 :* string… 評価する文字列 ; 戻り値 : 文字列内から見つかった位置のリスト。見つからない場合は nil。 ; サンプル <pre class="brush:autolisp;"> (setq text "This is a Pen. This is a Apple. Un! penpainappleapplep…」)
 
(相違点なし)

2025年8月6日 (水) 07:31時点における最新版

構文
(acet-str-m-find what string )


機能
what が出現する文字列を返し、見つかったすべての位置リストを返す。


引数
  • what… 検索する文字列
  • string… 評価する文字列


戻り値
文字列内から見つかった位置のリスト。見つからない場合は nil。


サンプル
(setq text "This is a Pen. This is a Apple. Un! penpainappleapplepen.")
(setq pos1 (acet-str-m-find "apple" text))
(44 49)

(setq text "東京特許許可局")
(setq pos1 (acet-str-m-find "許" text ))
(4 5)

(setq text "日本国際技術アカデミー")
(setq pos1 (acet-str-m-find "アカデミ" text ))
(7)

(setq text "あかまきがみあおまきがみきまきまみ")
(setq pos1 (acet-str-m-find "まき" text ))
(3 9 14)



関連事項