Ejemplo n.º 1
0
        private void btnPreview_Click(object sender, EventArgs e)
        {
            string strName = tbName.Text.Trim();
            string strAddress = tbAddress.Text.Trim();
            string strCrossStreet = tbCrossStreet.Text.Trim();
            string strCity = tbCity.Text.Trim();
            string strState = tbState.Text.Trim();
            string strZip = tbZip.Text.Trim();
            string strPhone = tbPhone.Text.Trim();

            string strGeocode = "";
            if (!String.IsNullOrEmpty(strAddress))
            {
                strGeocode += strAddress;
            }

            if (!String.IsNullOrEmpty(strState))
            {
                strGeocode += " " + strState;
            }

            if (!String.IsNullOrEmpty(strCity))
            {
                strGeocode += " " + strCity;
            }

            if (!String.IsNullOrEmpty(strZip))
            {
                strGeocode += " " + strZip;
            }

            strGeocode = strGeocode.Replace(" ", "+");
            GoogleGeoCode.GeoCode geoResult = GoogleGeoCode.GetGeoCode(System.Uri.EscapeDataString(strGeocode));

            tbLat.Text = geoResult.Latitude;
            tbLon.Text = geoResult.Longitude;

            frmVenueFullMap oForm = new frmVenueFullMap(tbLat.Text, tbLon.Text);
            oForm.Show();
            this.Hide();
        }
Ejemplo n.º 2
0
        void oButton_Click(object sender, EventArgs e)
        {
            frmVenueFullMap oForm = new frmVenueFullMap(_strLat, _strLon);
            oForm.Show();

            MessageBox.Show(this.ToString());

            this.Hide();
        }
Ejemplo n.º 3
0
 private void pbMap_Click(object sender, EventArgs e)
 {
     frmVenueFullMap oForm = new frmVenueFullMap(_strLat, _strLon);
     oForm.Show();
     this.Hide();
 }
Ejemplo n.º 4
0
 private void btnReview_Click(object sender, EventArgs e)
 {
     frmVenueFullMap oForm = new frmVenueFullMap(tbLat.Text, tbLon.Text);
     oForm.Show();
     this.Hide();
 }