Monthly Archives: August 2008

VB6 to .NET Migration Series: Getting ready for the ArcGIS 9.4 release

At the 2008 ESRI International User Conference  we announced that ESRI would no longer support the development of Visual Basic 6.0 applications at the ArcGIS 9.4 release.   Well, it is true.  As we speak, the development team is in the process of removing the VB6 DLLs and dependencies throughout the system.  So what does this mean for VB6 developers that plan to release their software applications on ArcGIS 9.4?  Well here are some inside tips that will help you plan for the future.
 
 
 
Visual Basic 6.0 SDK and Runtime
1. The Visual Basic 6.0 SDK will not be delivered with any of the ArcGIS 9.4 products.  Developers will not have access to the VB 6 developer help files, tools, add-ins and utility applications. 
 
2. The Visual Basic 6.0 Runtime will no longer be installed with any of the ArcGIS 9.4 products.   Therefore, if you still plan to deploy VB applications, you will need to ensure the VB 6 runtime has been installed by another application or you will need to install it as part of your deployment solution. 
Can you still develop with VB6?
Compilation:  The ArcObjects Type Libraries (OLBs) will still be shipped and installed with ArcGIS 9.4. As a result, as long as you don’t mind not having the ArcObjects VB6 SDK or any development tools, technically speaking, if you have a Visual Basic 6.0 development platform, you can still reference libraries and compile your applications.
 
Compatibility:  As long as the VB6 runtime is in place, it is possible that your applications will just work on an ArcGIS 9.4 system.  But please remember, while we make every effort to maintain backward compatibility, it is still your responsibility as the developer to reference the type changes and ensure that all applications behave as expected.
 
Microsoft Support:  In February, Microsoft released a “it just works” support statement indicating that they will continue to support the VB6 runtime on Windows 2008 and Vista; however, it is important to note that the VB6 IDE has gone past the period of extended support.  So that is something you may want to consider this as well.
What about VBA?
The Visual Basic for Applications SDK will still be released with ArcGIS 9.4 to support VBA development inside of the ArcGIS Desktop applications.  So VBA developers do not need to migrate their applications to .NET.
 
Should you still be developing with VB6? 
The bottom line is that if you are planning to develop applications for ArcGIS 9.4 and beyond, we strongly encourage you to start moving your VB6 applications to C#, VB.NET or VC++.

 

Making the Leap
You can find a number of articles on MSDN about how to make the switch from VB6 to .NET.  If you are thinking of transitioning to Visual Basic .NET today, there’s also a good set of articles here to get you started.   You’ll find that most of the documentation refers to Visual Studio 2005, but most of it applies to 2008 as well.  That said, you’ll need to decide whether to move to Visual Studio 2005 or 2008.  The current release of ArcGIS 9.3 supports development with both platforms.
 
Future blog series
To help you make the transition, be sure to stop by again or subscribe to view the upcoming VB6 to .NET Migration Series for ArcGIS developers.
 
 
 
 
Feel free to share your comments, links and experience here as well.
 
Posted in Developer | Tagged , , , , , | 1 Comment

Video: ArcGIS Server .NET team members show three Code Gallery samples

In this video, ArcGIS Server .NET development team members show three new samples they’ve posted to the Code Gallery. You’ll see an “Add Data” custom control, a Flickr search task that uses the client side graphics capabilities of the Web ADF, and some custom renderers that give the appearance of 3D. The video also shows how you can download the samples.

Posted in Services | Tagged , , , , | Leave a comment

Premium Subscriptions for Microsoft Virtual Earth Maps and USA Prime Imagery now available

8/29/08—ArcGIS Online Services Premium subscriptions are now available: 

  • USA Prime Imagery service from i-cubed for use in ArcGIS Desktop or with ArcGIS Server can be previewed in the content showcase on the ArcGIS Online Resource Center home page.
Posted in ArcGIS Online, Services | Comments Off

Geodatabase Essentials Presentations

Following up on our UC presentations post, Brent and I are posting the tech workshop presentations we gave (with other members of the geodatabase team) down in San Diego at this year’s user conference. You can check out the presentations in PDF format by following the links below.

    

Geodatabase Essentials Part I – An Introduction to the Geodatabase
Geodatabases Essentials Part II – An Introduction to ArcSDE Geodatabases

If these slides are not enough, you can order all the technical workshop recordings through Source of Knowledge here.

 

Posted in Geodata | Tagged , , | Leave a comment

Same blog, new name

Today we shortened the title of this blog to “ArcGIS Server Blog”. We removed “Development” from the name because the blog has come to include many topics of interest to non-developers.

You won’t notice any change in subject matter on this blog. It is still written by the ArcGIS Server software development team and will still contain many developer-oriented posts.

We’d like to thank you for reading the blog and for participating through your comments and e-mails.

The ArcGIS Server Software Development Team

Posted in Services | Tagged | Leave a comment

Geodatabase Replication – Additional info & Patch

This post was written by Heather McCracken and Gary MacDougall, both product engineers on the geodatabase team specializing in geodatabase replication

We just wanted to give you a heads up that there are a number of resources available which provide additional information on geodatabase replication. These include white papers, podcasts and technical articles. We’ve been keeping a knowledge base article that lists these helpful resources. This is a living document, so we’ll be continually updating it as new resources become available. You can find the article here

Also, there is a new patch for replication available for 9.2’s service pack 6. The patch addresses issues when synchronizing data where there are relationships that use the objectID column as the primary key. You can download the patch at the following location:

ArcGIS (Desktop, Engine, Server) 9.2 Synchronizing with Objectid Based Relationship Classes Patch

 

Posted in Geodata | Tagged , | 2 Comments

Live training seminar to demonstrate map caching strategies

During the past several weeks I’ve been working with Danielle Hopkins of ESRI Educational Services to prepare a live training seminar on ArcGIS Server map caching. The seminar is free and will be broadcast three times this Thursday, August 28 or you can watch it later in the seminar archives. This page has more information about how and when you can tune in to the seminar.

We prepared this seminar with two main goals in mind. First, we wanted to focus on caching strategies. The seminar will explain what map caching is and how to do it, but that is really just the beginning of successful caching. There are many things to think about when you create a cache, including how to design your map, how to choose a tiling scheme, where to create tiles, how to update the tiles, and so on. In this seminar, we’ll show some best practices and how to implement them using, in many cases, new features available at ArcGIS Server 9.3. Hopefully you’ll learn something new even if you’ve been caching for a while.

Second, we wanted to teach caching by showing it, so the presentation will include four demonstrations that might be similar to caching scenarios that you face. We’ll show how to create a base map cache, how to create an overlay cache that gets updated nightly, how to create a partial cache that gets filled in on demand, and how to create a cache for a Web mashup. At multiple points throughout the presentation, we’ll pause to take questions that you submit.

We look forward to seeing you on Thursday!

Update: The archived seminar is now available at http://training.esri.com/acb2000/showdetl.cfm?DID=6&Product_ID=931

Contributed by Sterling Quinn of the ArcGIS Server software development team

Posted in Services | Tagged , , , , | 3 Comments

Deploying your ArcGIS Mobile solution

An extremely important and challenging step in building an effective mobile solution is the deployment of it. Deployment involves packaging all of the information required to complete operations in the field and getting that information into the hands of your field workers so they can be efficient and productive with the software and data you give them.

I would like to focus this blog entry on deployment of the ArcGIS Mobile application, mobile projects and data to Windows Mobile handheld devices. If you need to deploy a custom mobile solution to laptops or tablets, you should take a look at a code gallery posting we have for building a mobile runtime.  

Overview 

There is no “one solution fits all” when it comes to deploying mobile solutions. Factors such as the size of your field workforce, the devices that they use in the field, the volume of data required for field use, and the frequency you need them to synchronize with the office all influence the choices you will make. Let’s not forget to factor in IT infrastructure either!

It all boils down to 2 methodologies. Either you “push” information to devices or you “pull” information from a server to your device. There are a number of 3rd party deployment systems in the marketplace today that you can use to “push” deployments to devices (Microsoft, SOTI, and Motorola are a few companies that offer solutions). With ArcGIS Mobile, we offer a web-centric solution for the “pull” model out-of-the-box by creating a web site and web service that hosts your mobile projects and the ArcGIS Mobile application. More on that a little later.

Windows Mobile and CAB files

First it is important to understand that Windows Mobile devices use cabinet files (.CAB files) as a compressed installer for applications and CAB files can be used for other information (such as map data). Marcus Perryman wrote an interesting blog article on MSDN explaining cabinet technology so I won’t go into details on the technology here.With ArcGIS Mobile at 9.3, we include a .CAB file for the out-of-the-box application and provide that CAB file as a link on a web page that you can download from your mobile device. Deploying the ArcGIS Mobile application to a mobile device is as simple as clicking on the CAB link from your device.

Note that at 9.3 we also include a CAB for the SDK runtime as well. You can use the SDK runtime in the deployment of your custom Windows Mobile application.We recently posted a code gallery entry on how you can create a .CAB file for your application that includes this SDK runtime CAB using Visual Studio. 

ArcGIS Mobile Web Site 

When you install ArcGIS Server at 9.3, a new web site is created to help you manage your mobile deployments (http://yourWebServer/yourInstance/Mobile). This web site is optimized for mobile browsers as well. It contains a link to the .CAB file for the ArcGIS Mobile application, and links for each of the projects that you create inside of the Server Manager as shown below. Projects are xml files that configure the ArcGIS Mobile application with data and tasks.

From your Windows Mobile device, you can use the web browser and navigate to the web site on your server, download and install the application by clicking on the link, and download the mobile project which configures the mobile application to use appropriate map data and tasks for your work in the field.

Using the ArcGIS Mobile application you can open the project and pull map data from the server using the Synchronize task. Pulling map data from the server to the device can take time if are wireless so be careful…

What would be more efficient is to pre-cache the data, create a .CAB from it, and somehow get this CAB file to the mobile device. But how?

Creating a Data Deployment Cache

Within ArcGIS Desktop, you will find a new toolset in the ArcToolbox window that contains 2 new geoprocessing tools for building mobile datasets:

Ignoring the Create Mobile Basemap tool for a minute, lets discuss the Generate Mobile Service Cache tool. This tool inputs a connection to your mobile service, lets you pick a set of map layers and an extent, and creates an output cache into a defined folder location. For your mobile projects, you can create caches using this tool for deployment to devices.

The Create Mobile Basemap tool can be used to build a highly compressed mobile base map. This tool uses a map document as input and creates a folder of SDC files. Inside of the project you define you can specify a base map when determining the layer source. Please read more about preparing maps and data to understand how you can leverage base maps inside of ArcGIS Mobile.

Building a Data Deployment CAB

Once you have built a mobile service cache, you can then create a data deployment CAB. If you are savy in the ways of Visual Studio, you can use it to create a CAB file from your mobile service cache. But if not, we have put a utility application that you can use to create your own cache on the code gallery called the Data Deployment Utility. Using this tool, you can create a CAB file for your mobile cache.

Tweaking the Mobile Web Site

The ArcGIS Mobile application CAB file and each of the mobile project files are stored on your web server. You can find these files at: \yourServerInetpubwwwrootyourInstanceMobile. Projects are stored in the Project folder, the CAB file is located in the Software folder.

Also at that folder location you will find 2 ASP web pages – Default.aspx and MobileDefault.aspx. As you might expect, MobileDefault.aspx is the web page loaded when you access the site from a mobile web browser and Default.aspx is the web page loaded from a Desktop. You can extend either web page with your own information and/or links to other downloads.

The <body> tag inside of MobileDefault looks like this:
<body>
    <form id=”form1″ runat=”server”>       
        <div>
        </div>
    </form>
</body>

You can extend the page with your own content with something like this (in bold) where the:

<body>
    <mobile:Form id=”mobileForm” runat=”server”>        
            <b>
              <a href=”MobileApplication.ashx?file=ProjectXData.CAB”>
                Project X Data CAB</a>
            </b>

  </mobile:Form>  
</body>

If ProjectXData.CAB is located in the software folder, the end result will be a new link for your data CAB directly below the project list like so:



New CAB Link

From your mobile device you can click on the new link added to the MobileDefault.aspx web page and it will download and install the mobile service cache onto your device.

Summary

Deployment is an important step in building an effective and efficient mobile solution. There are a number of factors to consider when choosing a deployment methodology and there are deployment systems that you can purchase to make the deployment process easier. ArcGIS Mobile provides a very simple, out-of-the-box experience for deployment that you can extend for your needs. Remember that deployment can make or break the success of a mobile solution. Spend time in analyzing how deployment best fits into your field operations before making any decisions.

Posted in Mobile | Tagged , , , | Leave a comment

Quick Content

The Quick Content task is a recent addition to Explorer, introduced with the 480 release in June. It provides a simple way to create your own Web-based menu for adding and displaying information using ArcGIS Explorer. The following video clip shows how you can access the task, and begin using it:

The Quick Content task is not in the collection of tasks you see when you open the default map. But you can add it very easily by choosing Tools > Manage Tasks. You’ll see it at the bottom of the default tasks list, just highlight it and use the arrow to move it to the right hand available in this map list.

 

When you first open Quick Content, you’ll see a sample page that you can use as a template.

Click GeoTagged photo, and you’ll automatically zoom to a result location (in this case the ESRI campus) and will see a photo appear in the popup window.

How’d we do this? The Quick Content example is just a Web page, and it could be anything that we can display in a browser. If we look at the Quick Content source (right click in the content and choose View Source), you’ll see that the link we clicked to view the photo references an NMF file.

To create the NMF file we used the Create Note task to add a note result, using the the photo of the ESRI campus in the note description so it would open in the popup window. With the popup window open, we exported the result, and put it in a location that anyone could access (also making sure the ESRI photo could be externally accessed).

You can create your own Quick Content page, then just paste your URL into the address at the top. Below we used a local path, but obviously if you want this to be available to others in your organization or extenally, you would need to place it in an location that can be accessed externally. When you save your map your custom Quick Content will be available every time you open it.

You can add your own layers, results, and even tasks to the Quick Content, even making your own complete resource center (there are other ways to link your own resource center directly in Explorer using your own home server, which we’ll cover in a future post). 

A Quick Content task was also demonstrated during the recent User Conference Plenary, covered in this blog post.

For more information see the Quick Content Help topic.

Posted in Uncategorized | Tagged , | Leave a comment

Code Snippets: write 'em, save 'em, reuse 'em

The “DRY” principle describes an element of programming efficiency:  Don’t Repeat Yourself.  

One of the tools available to help you with this are Code Snippets.  ArcGIS 9.3 products ship with hundreds of these snippets you can quickly and easily find and use, but how can you create them, add to this repository, and share them with others?

Back on July 14th, Don Kemlage from the ArcGIS SDK team posted a video here on the blog to describe what snippets are, how to get to the ones we provide with ArcGIS, and how to use the Snippet Finder.   At about 10:50 minutes into that video, Don mentions briefly that developers can make their own snippets too.  In this post here, we wanted to dig a little more into that, and provide some tips on how to do it in more detail.

Frameworks such as Visual Studio and Eclipse provide several ready-to-use Code Snippets.  You can even add your own snippets into the library, organizing them into a directory structure by the subject or task they accomplish. Creating your own code snippets helps you and your team members have snippets which are greatly customized for your development.

Code snippets are defined in XML format and are stored with the *.snippet file extension. You can use your favorite XML or text editor or Visual studio or Eclipse to create and maintain them.

 

Creating Code Snippets in Visual Studio 2005/2008

MSDN has a nice concise “How To” article on creating code snippets.

In short, using Visual Studio 2005/2008 start with the File > New > File > XML File menu item.  That allows you to create the new file and save it in place, ready for editing.  Then the next step is to plug in the required information to make it an individual code snippet. Let’s show you an example code snippet, then further below we’ll explore the tags one by one.

 

Let’s walk through it, top to bottom.

CodeSnippets
The <CodeSnippets> element is the root element of the code snippet XML schema and has xmlns attribute value.

CodeSnippet
The  <CodeSnippet> element is used to create an individual code snippet and this is where all declarations on your snippet must reside.

Header, Title, Shortcut, Description, Author, SnippetTypes
The <CodeSnippet> tag has a <Header> section that contains information needed by the IDE in these additional tags.  Visual Studio gives you a description of what each one does when you hover your mouse on these tags. 

Snippet
The <Snippet> tag is a little bit more complex. It contains both the <References> and <Code> tags.

References
 The <References> tag is used by the IDE to add references to the project when the snippet is inserted. In this example, the code snippet adds a reference to ESRI.ArcGIS.esriSystem.dll when the snippet is inserted. Note that Visual C# code snippets do not support the References section, so a reference to ESRI.ArcGIS.esriSystem.dll must be added to the project manually.

Code
The <Code> tag contains the specific code to insert as <Code Language=”VB”> that says that the language of the code snippet is Visual Basic. All snippet code must be placed between <![CDATA[ and ]]> brackets. You can also mention (in comments) what ArcGIS Products and which versions (9.2, 9.3) can use this snippet and any other namespaces that you wish the user imports before adding.

Ok, so after doing this a couple of times they are pretty simple to create.  And whether you write them using Visual Studio or a plain text editor, give each one a *.snippet file extension and use the Tools > Code Snippets Manager menu item to ensure the IDE knows where these folders are.

Code Snippets not only provide a wide variety of productivity-enhancing solutions and their real power lies in their extensibility. Give them a shot.

Contributed by Sirisha Karamchedu from ESRI Educational Services

Posted in Developer | Tagged , , , | 2 Comments