Objective C(and programming in general) newbie here. I have a specific goal project I'm working on, but I'm not sure the best way to tackle it. I came up with a pseudo code solution that I'm slowly translating to obj c, but I'm not sure if I'm wasting my time coming at it all wrong. Am I headed down the wrong path? Is this a good forum to post in?
I don't mind learning too much high level stuff, but on the other hand I'd rather spend one day or even a week copying and pasting than three or four months just to get started. Thanks for any help!
Here's the problem:
I have 15 objects each exactly the same, other than the name. Each object has 20 parameters. Each of these parameters can be set by the user to "connected" "disconnected", or "random". I want to output a text file in binary 0=off 1=on. So the result would be like this: object_12_11100110110000111000
Here's the general plan
When the program launches:
a)If there are less than x(15 in this case) objects make a new one. Call it object_0 +1.
b)Each object is to have a page to be dynamically named object 1,2,3, ect.(Unsure how to do this in Interface builder) I will build one template page with all the named paramaters and a user selectable UI box for each. I need to figure out way to number all the parameters behind the scenes too. The user could then go to an object's page and edit each of the parameters. Then they hit a button to make a text file.
c) Start with object_1 and append blank "parameters" string.
As long as parameters length is less than y(20 in this case) check UI box z(z starts as zero)+1. Set this as the new z value.
If UI box says "connected" append 1, "disconnected" append 0 or "random" then pick 0 or 1 randomly and append that.
When parameters = 20, store that info, object_1 +1 and repeat c), unless object_20 then print out a objects 1 through x to a text file.
Example code would be great! BTW Is there a list of all obj c syntax? There is so much, it would really help.
I think my algorithm is sound, but I'm not sure if I should use the algorithm to create the program and have the hard values coded into the file I distribute or what. I'm not sure how I would go about that.
I've built something similar to this using the command prompt where the user hit 1,2,3, but nothing this in depth. It was also really easy to copy the text file and just change the number for the objects.
I'd like to give the user an interface, an option to save their settings to come back latter and make a lot of usability improvements like that. But combining the GUI and the code is really throwing me off. I'm not sure how to deal with Interface Builder and window generation. Switching between the two modes is hard.
There's also a lot more functionality I want to add later like loading and parsing the output to fill in the settings of the program.
I don't mind learning too much high level stuff, but on the other hand I'd rather spend one day or even a week copying and pasting than three or four months just to get started. Thanks for any help!
Here's the problem:
I have 15 objects each exactly the same, other than the name. Each object has 20 parameters. Each of these parameters can be set by the user to "connected" "disconnected", or "random". I want to output a text file in binary 0=off 1=on. So the result would be like this: object_12_11100110110000111000
Here's the general plan
When the program launches:
a)If there are less than x(15 in this case) objects make a new one. Call it object_0 +1.
b)Each object is to have a page to be dynamically named object 1,2,3, ect.(Unsure how to do this in Interface builder) I will build one template page with all the named paramaters and a user selectable UI box for each. I need to figure out way to number all the parameters behind the scenes too. The user could then go to an object's page and edit each of the parameters. Then they hit a button to make a text file.
c) Start with object_1 and append blank "parameters" string.
As long as parameters length is less than y(20 in this case) check UI box z(z starts as zero)+1. Set this as the new z value.
If UI box says "connected" append 1, "disconnected" append 0 or "random" then pick 0 or 1 randomly and append that.
When parameters = 20, store that info, object_1 +1 and repeat c), unless object_20 then print out a objects 1 through x to a text file.
Example code would be great! BTW Is there a list of all obj c syntax? There is so much, it would really help.
I think my algorithm is sound, but I'm not sure if I should use the algorithm to create the program and have the hard values coded into the file I distribute or what. I'm not sure how I would go about that.
I've built something similar to this using the command prompt where the user hit 1,2,3, but nothing this in depth. It was also really easy to copy the text file and just change the number for the objects.
I'd like to give the user an interface, an option to save their settings to come back latter and make a lot of usability improvements like that. But combining the GUI and the code is really throwing me off. I'm not sure how to deal with Interface Builder and window generation. Switching between the two modes is hard.
There's also a lot more functionality I want to add later like loading and parsing the output to fill in the settings of the program.