<?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: Android Basics &#8211; Dialogs and Floating Activities</title>
	<atom:link href="http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/</link>
	<description>Tutorials, Tips and tricks, Tools for Android development</description>
	<lastBuildDate>Mon, 30 Jan 2012 19:28:00 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Dontel Newton</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-503</link>
		<dc:creator>Dontel Newton</dc:creator>
		<pubDate>Wed, 22 Sep 2010 01:50:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-503</guid>
		<description>what does the code that goes with this statement look like?

&quot;Now the calling activity needs to provide the object of the class that implements the MyDialogListener which will gets called on ok or cancel button clicks.&quot;

if i have a text view in my original activity how do i connect it to the listener from my dialog to get the information from the dialog.</description>
		<content:encoded><![CDATA[<p>what does the code that goes with this statement look like?</p>
<p>&#8220;Now the calling activity needs to provide the object of the class that implements the MyDialogListener which will gets called on ok or cancel button clicks.&#8221;</p>
<p>if i have a text view in my original activity how do i connect it to the listener from my dialog to get the information from the dialog.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: lamia</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-413</link>
		<dc:creator>lamia</dc:creator>
		<pubDate>Wed, 19 May 2010 09:25:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-413</guid>
		<description>Hi,
I want to update the dialog before it is getting shown,I used the showdialog method and to create the  dialog I use this:

protected Dialog onCreateDialog(int id) {
		                     switch (id) {
		             case DIALOG_LIST:
		            
return new AlertDialog.Builder(calendar.this).setTitle(&quot;Events&quot;).setItems(dialog_items_Event, new DialogInterface.OnClickListener() {
			                         public void onClick(DialogInterface dialog, int which) {
		                       
                      	   viewcalendar();
			                         }
			                     })
			                     .create();
			        
			             }
		                     
			             		return null;}

but every time I click in the item I get the same dialog ,my be I use
 onPrepareDialog() method but where and how  I use it ? please I need answer</description>
		<content:encoded><![CDATA[<p>Hi,<br />
I want to update the dialog before it is getting shown,I used the showdialog method and to create the  dialog I use this:</p>
<p>protected Dialog onCreateDialog(int id) {<br />
		                     switch (id) {<br />
		             case DIALOG_LIST:</p>
<p>return new AlertDialog.Builder(calendar.this).setTitle(&#8220;Events&#8221;).setItems(dialog_items_Event, new DialogInterface.OnClickListener() {<br />
			                         public void onClick(DialogInterface dialog, int which) {</p>
<p>                      	   viewcalendar();<br />
			                         }<br />
			                     })<br />
			                     .create();</p>
<p>			             }</p>
<p>			             		return null;}</p>
<p>but every time I click in the item I get the same dialog ,my be I use<br />
 onPrepareDialog() method but where and how  I use it ? please I need answer</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amol</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-412</link>
		<dc:creator>Amol</dc:creator>
		<pubDate>Tue, 18 May 2010 17:22:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-412</guid>
		<description>Thank you Mayur,
But I wanted it to set in onCreateDialog(). 
protected Dialog onCreateDialog(int id) {
		 progress = new ProgressDialog(this);
		 switch(id){
		 case PROGRESS_START :
			 progress.setContentView(R.layout.progess);
			 textview = (TextView)findViewById(R.id.text);
			 textview.setText(&quot;this is custom progressdialog&quot;);
			 return progress;
		 }
		 return null;
		
	} 
and i called showDialog in onCreate method
but it is showing NULLPOINTEREXCEPTION
i think it is finding the view 
so do you have any suggestion/example
thank you once again.</description>
		<content:encoded><![CDATA[<p>Thank you Mayur,<br />
But I wanted it to set in onCreateDialog().<br />
protected Dialog onCreateDialog(int id) {<br />
		 progress = new ProgressDialog(this);<br />
		 switch(id){<br />
		 case PROGRESS_START :<br />
			 progress.setContentView(R.layout.progess);<br />
			 textview = (TextView)findViewById(R.id.text);<br />
			 textview.setText(&#8220;this is custom progressdialog&#8221;);<br />
			 return progress;<br />
		 }<br />
		 return null;</p>
<p>	}<br />
and i called showDialog in onCreate method<br />
but it is showing NULLPOINTEREXCEPTION<br />
i think it is finding the view<br />
so do you have any suggestion/example<br />
thank you once again.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zeeshan</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-411</link>
		<dc:creator>zeeshan</dc:creator>
		<pubDate>Tue, 18 May 2010 13:25:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-411</guid>
		<description>Hi Amol,
if you want to change the color of progressdialog ,i have one solution on it,
used setContentView method to change the background of progressdialog,
here is my project link-http://www.androidcompetencycenter.com/wp-content/uploads/2010/05/ProgressDialog.zip</description>
		<content:encoded><![CDATA[<p>Hi Amol,<br />
if you want to change the color of progressdialog ,i have one solution on it,<br />
used setContentView method to change the background of progressdialog,<br />
here is my project link-http://www.androidcompetencycenter.com/wp-content/uploads/2010/05/ProgressDialog.zip</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amol</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-410</link>
		<dc:creator>Amol</dc:creator>
		<pubDate>Mon, 17 May 2010 11:06:04 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-410</guid>
		<description>hi,
well actually I wanted to customize my ProgressDialog. I want to change the color of the progressdialog is there any example for this.</description>
		<content:encoded><![CDATA[<p>hi,<br />
well actually I wanted to customize my ProgressDialog. I want to change the color of the progressdialog is there any example for this.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Woodster</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-116</link>
		<dc:creator>Woodster</dc:creator>
		<pubDate>Mon, 29 Jun 2009 21:23:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-116</guid>
		<description>Hello,

Thanks for the post, its a great guide.

I am trying to implement the code, which worked fine till I got to adding the code:

MyDialogListener listener

Once added, how do you call the dialog from the activity, and how do you receive the entry in that activity? If there any chance of getting the code you would use in the calling activity?


Thanks!</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>Thanks for the post, its a great guide.</p>
<p>I am trying to implement the code, which worked fine till I got to adding the code:</p>
<p>MyDialogListener listener</p>
<p>Once added, how do you call the dialog from the activity, and how do you receive the entry in that activity? If there any chance of getting the code you would use in the calling activity?</p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zeeshan</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-91</link>
		<dc:creator>zeeshan</dc:creator>
		<pubDate>Thu, 14 May 2009 13:31:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-91</guid>
		<description>&lt;a href=&quot;#comment-89&quot; rel=&quot;nofollow&quot;&gt;@Nils Thorell&lt;/a&gt; 
Hi Nils,

The layout is given in the above code 

Save the complete layout xml code given in the tutorial above as mydialog.xml in res/layout location in your android application.

If this doesn’t solve your problem,then post the exception here
(You can see the exception in the logcat in DDMS view).</description>
		<content:encoded><![CDATA[<p><a href="#comment-89" rel="nofollow">@Nils Thorell</a><br />
Hi Nils,</p>
<p>The layout is given in the above code </p>
<p>Save the complete layout xml code given in the tutorial above as mydialog.xml in res/layout location in your android application.</p>
<p>If this doesn’t solve your problem,then post the exception here<br />
(You can see the exception in the logcat in DDMS view).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nils Thorell</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-89</link>
		<dc:creator>Nils Thorell</dc:creator>
		<pubDate>Thu, 14 May 2009 09:30:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-89</guid>
		<description>The program crashes on 
setContentView(R.layout.mydialog);

How can I define &#039;mydialog&#039; in the layout?</description>
		<content:encoded><![CDATA[<p>The program crashes on<br />
setContentView(R.layout.mydialog);</p>
<p>How can I define &#8216;mydialog&#8217; in the layout?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Will</title>
		<link>http://www.androidcompetencycenter.com/2009/01/android-basics-dialogs-and-floating-activities/comment-page-1/#comment-15</link>
		<dc:creator>Will</dc:creator>
		<pubDate>Thu, 29 Jan 2009 02:04:08 +0000</pubDate>
		<guid isPermaLink="false">http://www.androidcompetencycenter.com/?p=280#comment-15</guid>
		<description>Thanks, the best android dialog example I have found.  Illustrative, useful, thorough and easy.  Only note: the OnClickListener &#039;implemented&#039; above is imported from View not DialogInterface.</description>
		<content:encoded><![CDATA[<p>Thanks, the best android dialog example I have found.  Illustrative, useful, thorough and easy.  Only note: the OnClickListener &#8216;implemented&#8217; above is imported from View not DialogInterface.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

