<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: How To Create A Data Entry Screen</title>
	<atom:link href="http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/feed" rel="self" type="application/rss+xml" />
	<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen</link>
	<description>Tips and Tricks for iPhone, iPod, iPad and iOS Developers</description>
	<lastBuildDate>Sat, 28 Jan 2012 16:20:12 -0700</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: bob</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-12895</link>
		<dc:creator>bob</dc:creator>
		<pubDate>Sat, 30 Jul 2011 00:02:06 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-12895</guid>
		<description>[[aView class] isSubclassOfClass:[UIResponder class]]
should be written as
[aView isKindOfClass:[UIResponder class]]</description>
		<content:encoded><![CDATA[<p>[[aView class] isSubclassOfClass:[UIResponder class]]<br />
should be written as<br />
[aView isKindOfClass:[UIResponder class]]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jonathan Sterling</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-3025</link>
		<dc:creator>Jonathan Sterling</dc:creator>
		<pubDate>Tue, 11 May 2010 05:44:33 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-3025</guid>
		<description>@Nick: It&#039;s not standard UI, and it&#039;s just plain ugly.</description>
		<content:encoded><![CDATA[<p>@Nick: It&#8217;s not standard UI, and it&#8217;s just plain ugly.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-3020</link>
		<dc:creator>Nick</dc:creator>
		<pubDate>Mon, 10 May 2010 03:18:35 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-3020</guid>
		<description>@Jonathan: In some cases a table view makes more sense, i.e. when all data entry fields are uniform in size and type, in other cases I think using a scroll view as described above is a good solution. Would you like to expand on your reasons for &quot;never&quot; making a data entry screen using a scroll view?</description>
		<content:encoded><![CDATA[<p>@Jonathan: In some cases a table view makes more sense, i.e. when all data entry fields are uniform in size and type, in other cases I think using a scroll view as described above is a good solution. Would you like to expand on your reasons for &#8220;never&#8221; making a data entry screen using a scroll view?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jonathan Sterling</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-3013</link>
		<dc:creator>Jonathan Sterling</dc:creator>
		<pubDate>Sun, 09 May 2010 15:55:46 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-3013</guid>
		<description>Stop. Please never make a data entry screen out of fields in a scrollview. Always use a UITableView; also, scrolling is done automatically for you when you do it the way I suggest.</description>
		<content:encoded><![CDATA[<p>Stop. Please never make a data entry screen out of fields in a scrollview. Always use a UITableView; also, scrolling is done automatically for you when you do it the way I suggest.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alexander Mardari</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-2872</link>
		<dc:creator>Alexander Mardari</dc:creator>
		<pubDate>Tue, 27 Apr 2010 07:34:23 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-2872</guid>
		<description>EDIT: Add the necessary funcs and variables to your View .h</description>
		<content:encoded><![CDATA[<p>EDIT: Add the necessary funcs and variables to your View .h</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alexander Mardari</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-2871</link>
		<dc:creator>Alexander Mardari</dc:creator>
		<pubDate>Tue, 27 Apr 2010 07:33:29 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-2871</guid>
		<description>Here is the solution to the snap problem and the code to scroll view down after editing:

//We register for keyboard notifications in View init:
[self registerForKeyboardNotifications];

//Add this func to you View .m
- (void)registerForKeyboardNotifications{
    [[NSNotificationCenter defaultCenter] addObserver:self
											 selector:@selector(keyboardWasShown:)
												 name:UIKeyboardDidShowNotification object:nil];
	
    [[NSNotificationCenter defaultCenter] addObserver:self
											 selector:@selector(keyboardWasHidden:)
												 name:UIKeyboardDidHideNotification object:nil];
}

//We add a implementation for the return key
- (BOOL)textFieldShouldReturn:(UITextField *)aTextField {
	[myScrollView setContentOffset:CGPointMake(0, 0) animated:YES];  
	return YES;
}

//We move the View resize funcs out of textFieldDidBeginEditing
//The bKeyboardWasShown is for smooth scrolling when the keyboard is already on screen
- (void)keyboardWasShown:(NSNotification*)aNotification{
	if(!bKeyboardWasShown){
		bKeyboardWasShown=YES;
		CGRect applicationFrame = [[UIScreen mainScreen] applicationFrame];
		myScrollView.contentSize = CGSizeMake(applicationFrame.size.width, applicationFrame.size.height + 216);  
	}
}


// Called when the UIKeyboardDidHideNotification is sent
- (void)keyboardWasHidden:(NSNotification*)aNotification{
	bKeyboardWasShown=NO;
	CGRect applicationFrame = [[UIScreen mainScreen] applicationFrame];  
	myScrollView.contentSize = CGSizeMake(applicationFrame.size.width, applicationFrame.size.height);  
}

//And finally, add this to scrollViewToCenterOfScreen to check that the view won&#039;t scroll too much down
	if (y &gt; 216) {
		y = 216;
	}</description>
		<content:encoded><![CDATA[<p>Here is the solution to the snap problem and the code to scroll view down after editing:</p>
<p>//We register for keyboard notifications in View init:<br />
[self registerForKeyboardNotifications];</p>
<p>//Add this func to you View .m<br />
- (void)registerForKeyboardNotifications{<br />
    [[NSNotificationCenter defaultCenter] addObserver:self<br />
											 selector:@selector(keyboardWasShown:)<br />
												 name:UIKeyboardDidShowNotification object:nil];</p>
<p>    [[NSNotificationCenter defaultCenter] addObserver:self<br />
											 selector:@selector(keyboardWasHidden:)<br />
												 name:UIKeyboardDidHideNotification object:nil];<br />
}</p>
<p>//We add a implementation for the return key<br />
- (BOOL)textFieldShouldReturn:(UITextField *)aTextField {<br />
	[myScrollView setContentOffset:CGPointMake(0, 0) animated:YES];<br />
	return YES;<br />
}</p>
<p>//We move the View resize funcs out of textFieldDidBeginEditing<br />
//The bKeyboardWasShown is for smooth scrolling when the keyboard is already on screen<br />
- (void)keyboardWasShown:(NSNotification*)aNotification{<br />
	if(!bKeyboardWasShown){<br />
		bKeyboardWasShown=YES;<br />
		CGRect applicationFrame = [[UIScreen mainScreen] applicationFrame];<br />
		myScrollView.contentSize = CGSizeMake(applicationFrame.size.width, applicationFrame.size.height + 216);<br />
	}<br />
}</p>
<p>// Called when the UIKeyboardDidHideNotification is sent<br />
- (void)keyboardWasHidden:(NSNotification*)aNotification{<br />
	bKeyboardWasShown=NO;<br />
	CGRect applicationFrame = [[UIScreen mainScreen] applicationFrame];<br />
	myScrollView.contentSize = CGSizeMake(applicationFrame.size.width, applicationFrame.size.height);<br />
}</p>
<p>//And finally, add this to scrollViewToCenterOfScreen to check that the view won&#8217;t scroll too much down<br />
	if (y > 216) {<br />
		y = 216;<br />
	}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sam</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-2754</link>
		<dc:creator>Sam</dc:creator>
		<pubDate>Sat, 17 Apr 2010 14:58:17 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-2754</guid>
		<description>Thanks for the example you don&#039;t even know how many books and the SDK itself I browsed to even get a little of the knowledge you just dropped. I clipped this into evernote just in case I can&#039;t access your site in the future. Thanks, again, and know that I&#039;m using it.</description>
		<content:encoded><![CDATA[<p>Thanks for the example you don&#8217;t even know how many books and the SDK itself I browsed to even get a little of the knowledge you just dropped. I clipped this into evernote just in case I can&#8217;t access your site in the future. Thanks, again, and know that I&#8217;m using it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-2584</link>
		<dc:creator>Nick</dc:creator>
		<pubDate>Wed, 31 Mar 2010 21:07:33 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-2584</guid>
		<description>@Hardik: The code above is not dependent on portrait or landscape mode. If your screen layout works in both orientations, then this code should work too.</description>
		<content:encoded><![CDATA[<p>@Hardik: The code above is not dependent on portrait or landscape mode. If your screen layout works in both orientations, then this code should work too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hardik</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-2578</link>
		<dc:creator>Hardik</dc:creator>
		<pubDate>Wed, 31 Mar 2010 09:34:52 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-2578</guid>
		<description>Sir,This is good example
but can u give me document with explanation of each and every ling broadly to understand ur concept

2&gt;Is ur code is working on Portrait,Landscape,Portrait to Landscape and Landscape to portrait mode</description>
		<content:encoded><![CDATA[<p>Sir,This is good example<br />
but can u give me document with explanation of each and every ling broadly to understand ur concept</p>
<p>2&gt;Is ur code is working on Portrait,Landscape,Portrait to Landscape and Landscape to portrait mode</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Cameron</title>
		<link>http://iPhoneIncubator.com/blog/windows-views/how-to-create-a-data-entry-screen/comment-page-1#comment-1663</link>
		<dc:creator>Cameron</dc:creator>
		<pubDate>Sat, 12 Dec 2009 23:43:07 +0000</pubDate>
		<guid isPermaLink="false">http://iPhoneIncubator.com/blog/?p=161#comment-1663</guid>
		<description>And now looking back at my reasoning - after my comment - I see what&#039;s going on. The size of the content inside, not the size of the scrollView, is getting resized. So I understand how that should work, but now I&#039;m back to square one in understanding why it doesn&#039;t work as intended.

Any ideas, Nick?</description>
		<content:encoded><![CDATA[<p>And now looking back at my reasoning &#8211; after my comment &#8211; I see what&#8217;s going on. The size of the content inside, not the size of the scrollView, is getting resized. So I understand how that should work, but now I&#8217;m back to square one in understanding why it doesn&#8217;t work as intended.</p>
<p>Any ideas, Nick?</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching 2/17 queries in 0.083 seconds using disk: basic
Object Caching 355/366 objects using disk: basic

Served from: iphoneincubator.com @ 2012-02-08 01:40:15 -->
