1

I have made an application in which I am getting the direction by parse the ready made URL to the Google MapView. Now I want to set the Back Button and the my own header On the top of the layout. How could it be possible? Please help me. . . My code is as below:

StringBuffer mapUrl = new StringBuffer();

// onCreate Method

@Override
public void onCreate(Bundle savedInstanceState) 
{
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);

    mapUrl.append("http://maps.google.com/maps?");
    mapUrl.append("saddr="+21.22794190505816+","+72.8173828125);
    mapUrl.append("&daddr="+23.039297747769726+","+72.59765);

    System.out.println("MapUrl: "+mapUrl.toString());

    Intent i = new Intent("android.intent.action.VIEW", Uri.parse(mapUrl.toString()));
    startActivity(i);
}

Now how could be possible to set the Back Button and Title on the MapDirection Page.
Please help me. . .

droidev
  • 7,352
  • 11
  • 62
  • 94

1 Answers1

0

I have already answer this questions please check this

How to Set Layout with Mapview

if you find it as useful please mark it as an answer

Best Regards, Anup

Community
  • 1
  • 1
Anup Rojekar
  • 1,093
  • 9
  • 29
  • Budy, Still u Don't Understand the Problem. . . –  Apr 19 '11 at 11:48
  • Just Run My Code in by Making Small application then u got the reality that what happend. . . Your answer cant seen the Layout on the Direction page and i m loading the direction by ready made url by pasing to the New Intent.. . . –  Apr 19 '11 at 11:52
  • ok so you are using GoogleMap native app provided already on the device to invoke your URL is it so please confirm. – Anup Rojekar Apr 19 '11 at 11:53
  • So How it's Possible to Set the Header title and the Back Button in that Direction Page. . . ? –  Apr 19 '11 at 11:58
  • Ithin kyou can use a FrameLayout in order to something on Title & on th bottom, and embedd you mapactivity in that. – Anup Rojekar May 06 '11 at 12:02