POST
|
hi, I've recently deployed a custom application to a client and discovered that they're unable to see the symbol style but they're able view the name of the symbol in the symbology control, i build this application in windows7 and client is using XP,please help me out of this Thanks in advance Sujay
... View more
09-26-2011
07:07 PM
|
0
|
0
|
887
|
POST
|
Dim sInstall As String = ReadRegistry("SOFTWARE\ESRI\CoreRuntime") Dim path As String = System.IO.Path.Combine(sInstall, "Styles") Dim pofd As OpenFileDialog = New OpenFileDialog() pofd.CheckPathExists = True pofd.CheckFileExists = True pofd.RestoreDirectory = True pofd.InitialDirectory = path pofd.Multiselect = False pofd.Title = "Symbols" pofd.Filter = "ESRI Style Set Files (*.ServerStyle)|*.ServerStyle" If pofd.ShowDialog() = System.Windows.Forms.DialogResult.OK Then 'Load the style file into the SymbologyControlz AxSymbologyControlMxd.LoadStyleFile(pofd.FileName) AxSymbologyControlMxd.Update() AxSymbologyControlMxd.Refresh() End If
... View more
05-19-2011
04:54 AM
|
0
|
0
|
163
|
POST
|
Below is the code, i hope it will helpful Public Class pAttributeQuery Private m_pmapcontrol As IMapControl2 #Region "Private Variables" Private _strExpression As String 'Private _aryFieldNames As Array Private _strPrimaryField As String #End Region #Region "Public Events" Public Event ExpressionChanged(ByVal sender As Object, ByVal e As ExpressionChangeEventArgs) #End Region Public Sub pAttributeQuery_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'im plnam As String = PlyrName.SelectedIndex For i As Integer = 0 To GTZform.AxMapControl1.LayerCount - 1 Dim play As ILayer = GTZform.AxMapControl1.get_Layer(i) PlyrName.Items.Add(play.Name) PlyrName.SelectedIndex = 0 Next End Sub Private Sub PlyrName_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles PlyrName.SelectedIndexChanged Dim plyr As ILayer = GTZform.AxMapControl1.get_Layer(PlyrName.SelectedIndex) Dim plyrFil As ILayerFields plyrFil = plyr pID.Items.Clear() Dim ii As Integer For ii = 0 To plyrFil.FieldCount - 1 Dim pfield As IField = plyrFil.Field(ii) pID.Items.Add(pfield.Name) Next End Sub Private Sub pID_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles pID.SelectedIndexChanged Dim fl As IFeatureLayer = GTZform.AxMapControl1.get_Layer(PlyrName.SelectedIndex) Dim il As ILayerFields = fl Dim i As Long i = il.FindField(pID.SelectedItem) pIDFieldEXP.Items.Clear() Dim fcc As IFeatureCursor = fl.Search(Nothing, False) Dim ff As IFeature = fcc.NextFeature Do Until ff Is Nothing pIDFieldEXP.Items.Add(ff.Value(i)) ff = fcc.NextFeature Loop End Sub Private Sub AddFieldToExpression(ByVal strField As String) Dim strExpression As String = txtExpression.Text.Trim 'If strExpression = "" Then ' _strExpression = """" + strField.Trim + """" + "" 'Else ' _strExpression = _strExpression + " & "" "" & """"" + strField.Trim + """" + "" 'End If txtExpression.Text = _strExpression '"OBJECTID" & " " & [Shape_Length] End Sub Private Sub pID_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles pID.DoubleClick AddFieldToExpression(pID.SelectedItem.ToString) End Sub Private Sub pIDFieldEXP_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles pIDFieldEXP.DoubleClick 'AddFieldToExpression(pIDFieldEXP.SelectedItem.ToString) txtExpression.Text = txtExpression.Text + pIDFieldEXP.SelectedItem.ToString End Sub Private Sub pClean_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) 'txtExpression.Text = "" 'AddFieldToExpression(_strPrimaryField) End Sub Private Sub pCancel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles pCancel.Click Me.Dispose() End Sub Private Sub pApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles pApply.Click Dim pEQuearyRes As String = txtExpression.Text Dim pfeaturelayer As ESRI.ArcGIS.Carto.IFeatureLayer pfeaturelayer = GTZform.AxMapControl1.get_Layer(PlyrName.SelectedIndex) GTZform.AxMapControl1.Refresh() Dim pfeatureclass As ESRI.ArcGIS.Geodatabase.IFeatureClass = pfeaturelayer.FeatureClass 'If pfeaturelayer IsNot Nothing Then Dim pQuerfilter As ESRI.ArcGIS.Geodatabase.IQueryFilter = New ESRI.ArcGIS.Geodatabase.QueryFilterClass() pQuerfilter.WhereClause = pEQuearyRes Dim pfeatureselection As ESRI.ArcGIS.Carto.IFeatureSelection = TryCast(pfeaturelayer, ESRI.ArcGIS.Carto.IFeatureSelection) 'directcast pfeatureselection.SelectFeatures(pQuerfilter, esriSelectionResultEnum.esriSelectionResultNew, False) ' End If If pfeatureclass.FeatureCount(pQuerfilter) = Nothing Then MessageBox.Show("No Items Selected") Else MessageBox.Show("No of Selected Items : " & pfeatureclass.FeatureCount(pQuerfilter)) End If GTZform.AxMapControl1.ActiveView.PartialRefresh(ESRI.ArcGIS.Carto.esriViewDrawPhase.esriViewGeoSelection, Nothing, Nothing) End Sub End Class Public Class ExpressionChangeEventArgs Inherits System.EventArgs '' add local member variable to hold point label plcement angles Private _strExpression As String '' class constructor Public Sub New(ByVal strExpression As String) Me._strExpression = strExpression End Sub '' Return Expression Public ReadOnly Property Expression() As String Get Return _strExpression End Get End Property End Class
... View more
05-04-2011
05:07 AM
|
0
|
0
|
216
|
POST
|
dear lance, thanks for the reply, however i would like to tell you a little more about the application we are currently working on. We are building an Engine application using Arc Engine 9.3 can the solution you gave work in this situation? would be very thankful for you insights in this matter..
... View more
03-20-2011
09:10 PM
|
0
|
0
|
163
|
POST
|
Hi, We have an issue regarding browsing a FGDB to view its contents. We are trying to open a FGDB using Folder dialog box. But we are unable to view the standalone tables inside the database. to put is simply, if you use "ADD DATA" button in ArcGIS you can go inside a FGDB and view different data objects (Feature classes, Feature Datasets, table etc.). We want a similar method to via a folder dialog box.
... View more
03-17-2011
08:01 PM
|
0
|
3
|
2955
|
POST
|
Hi, We have a query regarding the FileGDB API. Does it need extra licensing while working with it and while deploying application based on it? We are developing a custom desktop application with standard ArcEngine license 9.3.1 and the client will be running this with a standard ArcEngine Runtime. I would further like to know if you can provide me links to demo and sample code using this API.
... View more
03-16-2011
11:19 PM
|
0
|
1
|
2798
|
POST
|
Hi i am trying to add field using GP in Arcengine but i am unable to add can anyone help me out of this below is the code i am struggling with,thanks in advance Private Sub pAField_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles pAField.Click Dim pinput As String = TextBox1.Text TextBox1.Text = pinput Dim pname As String = TextBox2.Text TextBox2.Text = pname Dim palias As String = TextBox3.Text TextBox3.Text = palias Dim ptype As String = ComboBox1.Text ComboBox1.Text = ptype Dim plength As Integer = Convert.ToInt32(TextBox4.Text) Dim pFScale As String = Convert.ToInt32(TextBox5.Text) Dim pPrecsion As String = Convert.ToInt32(TextBox6.Text) Dim Pfield As New AddField(pinput, pname, ptype) With Pfield .field_alias = palias '.field_type = ComboBox1.SelectedText.ToString .field_length = plength .field_scale = pFScale 'field_precision = pPrecsion End With Dim GP As ESRI.ArcGIS.Geoprocessor.Geoprocessor = New ESRI.ArcGIS.Geoprocessor.Geoprocessor() GP.Execute(Pfield, Nothing) MessageBox.Show("Completed") End Sub
... View more
03-01-2011
11:44 PM
|
0
|
3
|
852
|
POST
|
Hi,i am trying to add field using GP in arc engine but unable to add field, please help me how to add field, below is my code Private Sub CreateField_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CreateField.Click Dim text As String = TextBox1.Text TextBox1.Text = text 'get Field name from textbox Dim FName As String = FieldNameTxtB.Text FieldNameTxtB.Text = FName 'get Field name from textbox Dim FAlias As String = FieldAliasTxtB.Text FieldAliasTxtB.Text = FAlias 'get field type from combobox Dim FType As String = FieldTypeCMB.Text FieldTypeCMB.Text = FType 'get field lenght as integer from textbox Dim FLength As Integer = Convert.ToInt32(FieldLengthTxtB.Text) Dim addfield As ESRI.ArcGIS.DataManagementTools.AddField = New ESRI.ArcGIS.DataManagementTools.AddField() addfield.in_table = text addfield.field_name = FName addfield.field_alias = FAlias addfield.field_type = FType addfield.field_length = FLength Dim pddfield As ESRI.ArcGIS.Geoprocessor.Geoprocessor = New ESRI.ArcGIS.Geoprocessor.Geoprocessor() pddfield.Execute(addfield, Nothing) MessageBox.Show("Completed") End Sub
... View more
02-24-2011
09:27 PM
|
0
|
1
|
2516
|
POST
|
try this sample http://edndoc.esri.com/arcobjects/9.2/net/667d20df-d51e-4766-8ca0-c8b0cb924e5d.htm
... View more
02-10-2011
07:38 PM
|
0
|
0
|
109
|
POST
|
AS IGXdialog interface belongs to destop ,so i cant use in arcengine
... View more
02-02-2011
06:35 PM
|
0
|
0
|
491
|
POST
|
Thank you very much for replaying,i am trying arcengine,i created a form which will will export shape file to feature class (FileGDB---->Dataset----->Featureclass),can you please provide any code
... View more
02-01-2011
06:30 PM
|
0
|
0
|
491
|
POST
|
this is the code i wrote Private Sub OpenDialog_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenDialog.Click Dim openFileDialog As System.Windows.Forms.OpenFileDialog = New System.Windows.Forms.OpenFileDialog openFileDialog.InitialDirectory = "c:\" openFileDialog.Filter = "File GBD (*.GDB)|*.GDB" openFileDialog.FilterIndex = 2 openFileDialog.RestoreDirectory = True openFileDialog.Multiselect = False If openFileDialog.ShowDialog = System.Windows.Forms.DialogResult.OK Then
... View more
02-01-2011
12:51 AM
|
0
|
0
|
491
|
POST
|
I am trying to browse File geodatabase using common dialog box and open the feature dataset and then feature class in arcengine9.31 but unable to do it can any one help me
... View more
01-29-2011
01:58 AM
|
0
|
8
|
3098
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|