Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 993325
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T06:24:18+00:00 2026-05-16T06:24:18+00:00

Is there an objective c version of text delimiters?? Here’s the applescript code: set

  • 0

Is there an objective c version of text delimiters??

Here’s the applescript code:

set oldDelim to AppleScript's text item delimiters

set AppleScript's text item delimiters to "Jarvis>"
set charliePlainOutput to (what ever needs to be parsed)
set charlieUnmoddedOutput to last text item of charliePlainOutput
set charlieOutputFiltered to text item 1 of charlieUnmoddedOutput
set AppleScript's text item delimiters to "[Jarvis]"
set charlieOutputLast to text item 1 of charlieOutputFiltered
set AppleScript's text item delimiters to "["
set charlieOutput to text item 1 of charlieOutputLast

set AppleScript's text item delimiters to oldDelim

Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T06:24:19+00:00Added an answer on May 16, 2026 at 6:24 am

    The NSString method componentsSeparatedByString: will do basically the same thing as text items in Applescript. You can call than, then access objects from the array to get the substrings. This example grabs all the text after the last occurrence of “Jarvis>” in the original string:

    NSString* originalString; //comes from somewhere
    NSArray* substrings = [originalString componentsSeparatedByString:@"Jarvis>"];
    NSString* lastSubstring = [substrings lastObject];
    

    However, if you just want to grab a substring off the front or the back of an existing string, take a look at rangeOfString:, substringToIndex:, and substringFromIndex:. You would first use rangeOfString: to find the string you want to separate by, then one of the substring methods to grab the actual text you want. This is somewhat more efficient that componentsSeparatedByString: if you only want to access a single substring, rather than every single substring separated by your text delimiter. This example grabs all the text before the first occurrence of “[Jarvis]” in the original string:

    NSRange jarvisRange = [originalString rangeOfString:@"[Jarvis]"];
    NSString* substring = [originalString substringToIndex:jarvisRange.location];
    

    You can also use rangeOfString:options: passing in NSBackwardsSearch to the options parameter if you want to search from the end of the string rather than the front.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 507k
  • Answers 507k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer As far as I know, for most scenarios, you can… May 16, 2026 at 3:54 pm
  • Editorial Team
    Editorial Team added an answer $('#zip-input').keyup(function(){ if($(this).val().length == 5) { //do your stuff here }… May 16, 2026 at 3:54 pm
  • Editorial Team
    Editorial Team added an answer It appears that C extension modules included with the wxPython… May 16, 2026 at 3:54 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

There are two runtimes for Cocoa/Objective-C: the legacy runtime and the modern runtime (that's
I know that there are functions in the objective-c runtime that allow you to
Is there a Objective-c function to return a NSString * from a NSUInteger ,
Are there any methods in objective C for converting byte to int, float and
is there an OR function in Objective-C? for example: if(string1 == string2 || string3
Is there any way to split strings in objective c into arrays? I mean
In Objective-C, if I override a class method using a category, is there a
There are a few tutorials online ( For example ) having to do with
I have a simple question about creating multiple initialisers within an objective-c class. Basically
I've seen a few questions here related to determining the similarity of files, but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.