Quantcast
Channel: Forums - ArcGIS for Desktop - General
Viewing all articles
Browse latest Browse all 2328

Authorizing ArcGIS 10 using ASR files

$
0
0
I am trying to activate the ArcGIS Engine with the ASR file. I am following the sample in the document.
But when we run our application, It still can't find the ArcGIS Engine license.

And I find out there one extra step user need to do. After installed the ArcEngine user need to start the ArcGIS administrator Wizard and select the "ArcGIS Engine (Single Use)" and click ok, After that everything works fine. Attached the screen shot.
Attachment 21642

My question is: Is there any way to automated this selection in the code? So user does not need to start ArcGIS administrator Wizard.

Here is the code to activate the license
Code:

    Public Sub ActivateArcEngine()
        RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.Engine)
        Dim aoAuth As IAuthorizeLicense = New AoAuthorizeLicense()
       
        Dim strASR as String = "ASRxxx"
        Dim password As String = "xxxx"

        Try
            aoAuth.AuthorizeASR(strASR, password)
        Catch ex As COMException
            Dim lastError As String = String.Empty
            Dim err As Integer = aoAuth.LastError(lastError)
            Console.Out.WriteLine(err.ToString + ":" + lastError)
        End Try
    End Sub

Attached Thumbnails
Click image for larger version

Name:	InstallArcEngine.jpg‎
Views:	N/A
Size:	45.8 KB
ID:	21642  

Viewing all articles
Browse latest Browse all 2328

Trending Articles