Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
macOS & iOS Developer Playground
iOS Development
Extracting some information
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="StudentDev" data-source="post: 1801761" data-attributes="member: 400688"><p>Lets suppose this array:</p><p>[CODE]static let dlkContent = [ </p><p> LabelContent(text: "PRE FLT", theme: .menuOption), </p><p> LabelContent(text: "IN FLT", theme: .menuOption), </p><p> LabelContent(text: "POST FLT", theme: .menuOption), </p><p> LabelContent(text: "FREE TEXT", theme: .menuOption), </p><p> LabelContent(text: "FLT TIMES", theme: .menuOption), </p><p> LabelContent(text: "SYS MENU", theme: .menuOption), </p><p> LabelContent(text: "NEW MSGS", theme: .menuOption), </p><p> LabelContent(text: "MSGS SENT", theme: .menuOption), </p><p> LabelContent(text: "MSGS RCVD", theme: .menuOption), </p><p> LabelContent(text: "VOX CONTACT", theme: .menuOption), </p><p> LabelContent(text: "STATUS", theme: .menuOption), </p><p> LabelContent(text: "ATS MENU", theme: .menuOption), </p><p> ] [/CODE]</p><p> </p><p>Is it possible to insert a new "element" like (destination: "navContent")?</p><p>[CODE]LabelContent(text: "PRE FLT", theme: .menuOption, destination: "navContent"), [/CODE]</p><p> </p><p>And use this information to inform for an IBAction what array to be used?</p><p>[CODE]@IBAction func btn1L(_ sender: UIButton) { </p><p> Contents.apply(contents: Contents.destination[0][0..<12], to: uiTextLabels) </p><p> </p><p> } [/CODE]</p><p></p><p>Basically, I would like to inform the system that every time the dlkContent Array is used, if the user select the button, corresponding to the first element of this array, it will call another action with that mentioned value</p><p></p><p>I know the line 02 of the last code is not ok. But I would like to get the first destination value of the array and use in Contents.xxxx</p><p> </p><p>Is it possible?</p><p> </p><p>Thank you</p></blockquote><p></p>
[QUOTE="StudentDev, post: 1801761, member: 400688"] Lets suppose this array: [CODE]static let dlkContent = [ LabelContent(text: "PRE FLT", theme: .menuOption), LabelContent(text: "IN FLT", theme: .menuOption), LabelContent(text: "POST FLT", theme: .menuOption), LabelContent(text: "FREE TEXT", theme: .menuOption), LabelContent(text: "FLT TIMES", theme: .menuOption), LabelContent(text: "SYS MENU", theme: .menuOption), LabelContent(text: "NEW MSGS", theme: .menuOption), LabelContent(text: "MSGS SENT", theme: .menuOption), LabelContent(text: "MSGS RCVD", theme: .menuOption), LabelContent(text: "VOX CONTACT", theme: .menuOption), LabelContent(text: "STATUS", theme: .menuOption), LabelContent(text: "ATS MENU", theme: .menuOption), ] [/CODE] Is it possible to insert a new "element" like (destination: "navContent")? [CODE]LabelContent(text: "PRE FLT", theme: .menuOption, destination: "navContent"), [/CODE] And use this information to inform for an IBAction what array to be used? [CODE]@IBAction func btn1L(_ sender: UIButton) { Contents.apply(contents: Contents.destination[0][0..<12], to: uiTextLabels) } [/CODE] Basically, I would like to inform the system that every time the dlkContent Array is used, if the user select the button, corresponding to the first element of this array, it will call another action with that mentioned value I know the line 02 of the last code is not ok. But I would like to get the first destination value of the array and use in Contents.xxxx Is it possible? Thank you [/QUOTE]
Verification
Post reply
Forums
macOS & iOS Developer Playground
iOS Development
Extracting some information
Top