Code in the book Beginning iPhone Development (by Dave Mark & Jeff LaMarche) assigns to the UITableViewCell text property:
UITableViewCell *cell = ...
...
cell.text = ...
This assignment brings up a "'setText' is deprecated..." warning. What should I use as an alternative?
Also, how do I open the long URL in the warning (in Xcode) without retyping the whole thing?
try:
cell.textLabel.text = @"test";
(Ah, it's nice to be answer 3.0 SDK questions now)
Deprecated suggests that you change your code to use the new method suggested by Apple. Any deprecated methods would be removed in the future update releases (for ex: they might remove it from OS 3.1) So, instead of setText, use this
[cell.textLabel setText] method
you Use This Code:-
"cell.textLabel.text"
Remove The Warning Of Text deprecated UITableViewCell setText?
To address the second question.
I'm not sure what you mean by URL but to get the full text of the build output, which is where the warning bubble comes from:
1) open the build window (default key binding Command-Shift-B)
At the bottom of the build progress view there are four buttons. The buttons from left to right are a checkmark, a warning symbol, some dotted lines, and a popup menu for more options.
Make sure the third symbol, the one with the dotted lines, has a dark grey background. Toggle it if you are in doubt. The new view that is exposed when this button is pressed has the full text output from the build process (compiler, linker, shell script output, etc...)
I believe this is what you are asking about.
You can use the Command-= and Command-Shift-+ to move through the warnings and errors. When you do this the full text of each warning/error bubble will be selected in the full output view.!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With