Add Google Maps to your .Net site

 

Ever wanted to add a Google Map to your site but only had 15 minutes to spare? Now you can add a map and still have time to brag to your mates and bask in the worship that (inevitably) comes afterward.

Basically, the guys over at subgurim.net have already done all the hard work in writing the .Net wrapper for Google Maps. Problem is, the examples on their site are mostly in spanish & its a bit difficult to find out exactly what is needed to get everything working.

But all this is cutting into your bragging time - so lets get started!

1. Get a Google Maps API key from here:
http://www.google.com/apis/maps/

2. Download the SubGurim wrapper dll from here:
http://en.googlemaps.subgurim.net/descargar.aspx

3. Unzip it, and put it in your \bin directory

4. Add it to your toolbox by
Tools -> Choose Toolbox Items -> Browse -> Select the .dll file -> OK
GMap will now be in the ‘Standard’ area of your Toolbox.

5. Add a new webpage.

6. Drag the GMap from the toolbox onto the page. A new instance of the GMap will appear on the page, with the name ‘GMap1′

7. Add the following lines to your web.config file:


<appSettings>
<add key="googlemaps.subgurim.net" value="YourGoogleMapsAPIKeyHere" />
</appSettings>

8. Add the following code to your Page.Load sub


Dim sStreetAddress As String
Dim sMapKey As String = ConfigurationManager.AppSettings("googlemaps.subgurim.net")
Dim GeoCode As Subgurim.Controles.GeoCode

sStreetAddress = "100 Russell St. Melbourne. VIC. 3000. Australia"
GeoCode = GMap1.geoCodeRequest(sStreetAddress, sMapKey)
Dim gLatLng As New Subgurim.Controles.GLatLng(GeoCode.Placemark.coordinates.lat, GeoCode.Placemark.coordinates.lng)

GMap1.setCenter(gLatLng, 16, Subgurim.Controles.GMapType.GTypes.Normal)
Dim oMarker As New Subgurim.Controles.GMarker(gLatLng)
GMap1.addGMarker(oMarker)

Press F5, and start basking in the glory!

Update: I’ve now posted the code to add draggable markers and events to your Google Maps



SQL TOOLBOX: 20+ Tools and Lessons About SQL

SQL is all around us, but not everyone really knows its inner workings. We’ve gathered 20+ tools and lessons to help you learn all about it.

    25 Commandments for MySQL Development

25 Commandments for MySQL Development – A list of 25 things all MySQL designers should keep in mind as they work.

    Comparison of different SQL implementations

Comparison of different SQL implementations – A simple page comparing all the different ways you can use the SQL language.

    Instant SQL Formatter

Instant SQL Formatter – Open several different forms of databases and output them in to a language of your choice including SQL.

    Introduction to SQL

Introduction to SQL – An introductory lesson to SQL, covering pretty much all the basics.

    Learning SQL Using phpMyAdmin

Learning SQL Using phpMyAdmin – A tutorial for learning the popular phpMyAdmin interface for MySQL database management.

    MySQL Basics

MySQL Basics – A basic tutorial for those just starting out with learning MySQL.

    sqlcheatsheet

MySQL Cheat Sheet – A quick reference for some of the most common commands in MySQL.

    Oracle SQL Developer

Oracle SQL Developer – A free graphical tool for developing an SQL database.

    PostgreSQL.org

PostgreSQL.org – An open source database system developed on SQL.

    SQL Designer

SQL Designer – A site directed at teaching very basic beginners in SQL database work.

    SQL Injection Attacks

SQL Injection Attacks – A documentation of how “Injection Attacks” work on an SQL database.

    SQL on Rails

SQL on Rails [PARODY] – A web framework for combining Ruby on Rails with SQL for quick deployment.

    sql.org

SQL.org – A large resource for all things related to SQL.

    sql-tutorial.net

SQL-Tutorial.net – A very organized tutorial for SQL that lets you focus on one section at a time.

    SQLAlchemy.org

SQLAlchemy.org – A tool for harnessing the power of Python and SQL together.

    SQLCourse.com

SQLCourse.com – An interactive beginner’s course to SQL that includes an on-line SQL interpreter.

    sqlinform.com

SQLinForm.com – Corrects spelling an syntax errors in your SQL code.

    sqlzoo.net

SQLzoo.net – An interactive tutorial that teaches you the ins-and-outs of MySQL.

    sswug.org

SSWUG.org – A site to get help with any troubles you may be having with SQL databases.

    Stump The SQL Guru

Stump The SQL Guru – From the 4GuysFromRolla.com, ask tough questions of an SQL expert.

    W3 Schools SQL Tutorials

W3 Schools SQL Tutorials – An extensive tutorial on SQL that includes quizzes and recommended reading list.


JAVASCRIPT TOOLBOX: 25+ Tools & Tutorials For JavaScript

JavaScript is one of the most often used languages on the web, and it seems to be gaining in popularity each day. We’ve gathered 25+ tools and tutorials which will be useful to any JavaScript programmer – novice or pro.

    ActiveWidgets.com

ActiveWidgets.com – A component library that gives you AJAX-style fuctions with common visual elements.

    Agile Partners

Agile Partners Photo Resizing Tutorial – A tutorial on how to use the Prototype and script.aculo.us libraries to build an interactive photo resizer.

    ByteFX

ByteFX – A low-level framework for simple JavaScript effects.

    DevGuru.com

DevGuru – Defines all the terms of JavaScript and gives you code samples of what they do.

    Dojo Toolkit

DojoToolkit.org – An open source DHTML toolkit built in JavaScript and based on several other tools.

    Drag & Drop Sortable Lists

Drag & Drop Sortable Lists – Tutorial for creating sortable lists with drag & drop functions.

    DynamicDrive.com

DynamicDrive.com – A large collection of DHTML and JavaScripts for your use.

    Firebug

Firebug – An extension for the FirefoxFirefox browser that allows you to do web development from directly inside the browser, including JavaScript.

    javascript-reference.info

JavaScript-reference.info – A reference site that teaches you both how to read and write JavaScript.

    javascriptkit.com

JavaScriptKit.com – A list of JavaScript objects, properties, and methods that include examples.

    jQuery.com

jQuery.com – A JavaScript library with a small footprint and concise coding for as few lines as possible.

    Learn JavaScript in 10 Minutes

Learn JavaScript in 10 Minutes – As the name implies, learn the basics of JavaScript in 10 minutes from this very straightforward tutorial.

    lightbox2

Lightbox2 – A JavaScript for overlaying photos on the current page with a semi-transparent background.

    LightWindow

LightWindow – Another overlay window system that allows you to do it with multiple media file types and even other websites.

    MochiKit.com

MochiKit.com – A set of JavaScript libraries that takes ideas from Python and Objective-C, and uses them in JavaScript.

    moo.fx

Moo.fx – JavaScript effects library that works with the Prototype.js and Mootools frameworks.

    Mootools.net

Mootools.net – An object-oriented JavaScript framework for intermediate to advance users.

    Prototype Window Class

Prototype Windows Class – Allows you to add an overlay window to your HTML.

    Prototypejs.org

Prototypejs.org – A JavaScript framework that is built with Web 2.0 in mind, includes Ajax integration.

    QuirksMode.org

QuirksMode.org – The personal site of a professional web developer who offers over a 120 tricks for defeating browser incompatibility issues of CS and JavaScript.

    reflection.js

Reflection.js – A small JavaScript to add reflections to your image.

    script.aculo.us

script.aculo.us – A JavaScript library that integrates easily with numerous frameworks.

    ThickBox

ThickBox – Works with jQuery to provide an AJAX hybrid for image overlays.

    TinyMCE

TinyMCE JavaScript Content Editor – A content editor written completely in JavaScript and converts HTML text areas in to editor instances.

    W3Schools JavaScript Tutorials

W3Schools JavaScript Tutorials – 100 Examples to learn JavaScript by.

    WebTeacher

WebTeacher.com – Takes the point of view of teaching JavaScript to a programming novice.

    Walter Zorn Drag & Drop

Walter Zorn Drag & Drop – A cross-browser JavaScript DHTML library that allows you to turn any image in to a layer that can be dragged and dropped where the user chooses.