Re: API:Only Data field names and Ids

2014-08-20 Thread LJ LongWing
no clue in .NET


On Wed, Aug 20, 2014 at 9:39 AM, Sweety  wrote:

> Thanks LJ. I am also sure how to restrict a function to fetch only three
> values in .Net.
>
> How can I find the field label name using field id and view id? Any
> function ?
>
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-20 Thread Sweety
Thanks LJ. I am also sure how to restrict a function to fetch only three values 
in .Net.

How can I find the field label name using field id and view id? Any function ?

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-20 Thread LJ LongWing
Sweety,
As I don't use the .NET, I can't give direct help, but in the Java version,
there in a way to specify which attributes of a field you want to pull
back, with the default being 'all'...if all you are looking for is those 3
attributes, but you are pulling back ALL attributes of all fields, needless
to say, you are pulling back WAY more data than you want, so if you can
figure out how to limit the attributes returned to the 3 you are looking
for, it'll greatly increase your performance.

Now, relating to the 'label', this is also a field attribute, but is part
of an attribute map, because there is 1 label for each view of the form,
based on the ID's of the views, so, you will need to do a 'for' within your
current for loop to pull out each of the labels, and likely store those in
an array, hash, etc, but the information should be available in what you
are already pulling back.


On Wed, Aug 20, 2014 at 9:00 AM, Sweety  wrote:

> I am using .Net APIs for this program. Below program is working fine but
> it is taking 5 to 10 minutes to fetch the fields.
>
> Dim Result = Access.server.GetAllFields("HPD:Help Desk").Values
> Dim name, Id As String
> Dim Datatype As Integer
> For Each VARIABLE In Result
> name = (DirectCast(VARIABLE, BMC.ARSystem.Field).Name)
> Id = (DirectCast(VARIABLE, BMC.ARSystem.Field).Id)
> Datatype = (DirectCast(VARIABLE,
> BMC.ARSystem.Field).DataType)
> Next
>
> One more thing, I want to know the field label names of a view. How can I
> do that?
>
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-20 Thread Sweety
I am using .Net APIs for this program. Below program is working fine but it is 
taking 5 to 10 minutes to fetch the fields.

Dim Result = Access.server.GetAllFields("HPD:Help Desk").Values
Dim name, Id As String
Dim Datatype As Integer
For Each VARIABLE In Result
name = (DirectCast(VARIABLE, BMC.ARSystem.Field).Name)
Id = (DirectCast(VARIABLE, BMC.ARSystem.Field).Id)
Datatype = (DirectCast(VARIABLE, BMC.ARSystem.Field).DataType)
Next

One more thing, I want to know the field label names of a view. How can I do 
that?

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-15 Thread Sweety
Tried some tricks and found the cause;

 MsgBox("Hello1")
Dim Result = Access.server.GetAllFields("HPD:Help Desk").Values
 MsgBox("Hello2")

Hello1 is displaying when I call a function but not Hello2. May be issue with a 
GetAllFields method only.

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-15 Thread Sweety
Hi Dean,

I converted your code to VB.Net still not working

 Dim Result = Access.server.GetAllFields("HPD:Help Desk").Values

For Each VARIABLE In Result
MsgBox(DirectCast(VARIABLE, BMC.ARSystem.Field).Name)
MsgBox(DirectCast(VARIABLE, BMC.ARSystem.Field).Id)
MsgBox(DirectCast(VARIABLE, BMC.ARSystem.Field).DataType)
Next

program hangs for a long time without any outcome. I have to abort it to stop 
the program.

Can you suggest?

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-15 Thread Sweety
Hello LJ,

---Code-
 Dim fieldsArrayList
Dim fieldsIdsArray
fieldsArrayList = Access.server.GetListField("HPD:Help Desk")
fieldsIdsArray = fieldsArrayList.ToArray()
fieldsArrayList = Nothing
Dim i, ARfieldObject, fieldsNamesArray()
ReDim fieldsNamesArray(UBound(fieldsIdsArray))
For i = LBound(fieldsIdsArray) To UBound(fieldsIdsArray)
fieldsIdsArray(i) = CLng(fieldsIdsArray(i))
ARfieldObject = Access.server.GetField("HPD:Help Desk", 
fieldsIdsArray(i))
fieldsNamesArray(i) = ARfieldObject.Name
ListBox1.Items.Add(fieldsNamesArray(i))
Next
---

Where in my code I should check the field type? Do you see any issue in my 
code? It is taking very long time to fetch the field names

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-14 Thread LJ LongWing
Sweety,
Once you have the Field, you can use a .getDataType(), which returns an
Int, which you can then compare with DataType.* where * is the type of
field that you are looking for.


On Thu, Aug 14, 2014 at 12:51 PM, Sweety Khanna 
wrote:

> Hi Misi,
>
> How to check the datatype of the field??
>
>
> On 8/8/14, Misi Mladoniczky  wrote:
> > Hi,
> >
> > The ARGetMultipleFields() which will give you enough details to figure
> out
> > which fieldids you want.
> >
> > You must look at the data type of the field to determine if it is a data
> > bearing field.
> >
> > If the data type is <= 14 the field can hold data. You should use the
> > constant
> > AR_MAX_STD_DATA_TYPE instead of 14 though.
> >
> > Best Regards - Misi, RRR AB, http://www.rrr.se (ARSList MVP
> 2011)
> >
> > Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13):
> > * RRR|License - Not enough Remedy licenses? Save money by optimizing.
> > * RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs.
> > Find these products, and many free tools and utilities, at http://rrr.se
> .
> >
> >> Hello List,
> >>
> >> It has been a quite long I haven't talked to you guys. Hoping all are
> good
> >> and
> >> enjoying.
> >>
> >> I want to fetch the list of data fields only with names and their ids. I
> >> have
> >> tried using method GetListField but it is giving me all the fields on
> the
> >> form
> >> including buttons, panels etc. I want to fetch only data field details
> >> from
> >> API.
> >>
> >> Any suggestions?
> >>
> >> Cheers!
> >>
> >>
> ___
> >> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> >> "Where the Answers Are, and have been for 20 years"
> >>
> >
> >
> ___
> > UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> > "Where the Answers Are, and have been for 20 years"
> >
>
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-14 Thread Sweety Khanna
Hi Misi,

How to check the datatype of the field??


On 8/8/14, Misi Mladoniczky  wrote:
> Hi,
>
> The ARGetMultipleFields() which will give you enough details to figure out
> which fieldids you want.
>
> You must look at the data type of the field to determine if it is a data
> bearing field.
>
> If the data type is <= 14 the field can hold data. You should use the
> constant
> AR_MAX_STD_DATA_TYPE instead of 14 though.
>
> Best Regards - Misi, RRR AB, http://www.rrr.se (ARSList MVP 2011)
>
> Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13):
> * RRR|License - Not enough Remedy licenses? Save money by optimizing.
> * RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs.
> Find these products, and many free tools and utilities, at http://rrr.se.
>
>> Hello List,
>>
>> It has been a quite long I haven't talked to you guys. Hoping all are good
>> and
>> enjoying.
>>
>> I want to fetch the list of data fields only with names and their ids. I
>> have
>> tried using method GetListField but it is giving me all the fields on the
>> form
>> including buttons, panels etc. I want to fetch only data field details
>> from
>> API.
>>
>> Any suggestions?
>>
>> Cheers!
>>
>> ___
>> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
>> "Where the Answers Are, and have been for 20 years"
>>
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-08 Thread LJ LongWing
Sweety,
I would recommend using this method.  the 'fieldTypeMask' should use
Contstants.AR_Field_TYPE_DATA, this will give you only fields.  Secondly,
with the 'FieldCriteria' object, you can specify what data to pull back, so
you want ID and Name only, you specify it there.

getListFieldObjects

public List 
>
*getListFieldObjects*(String

formName,
   int fieldTypeMask,
   long changedSince,
   FieldCriteria

criteria)
throws ARException


Returns detailed information for all (accessible) Field

objects
that match with the given criteria.

*Parameters:*formName - the name of the form containing the field to
retrievefieldTypeMask - A bit mask value to specify types of the field.
They are: bit 0: Constants.AR_FIELD_TYPE_DATA

retrieve
data fields bit 1: Constants.AR_FIELD_TYPE_TRIM

retrieve
trim fields bit 2: Constants.AR_FIELD_TYPE_CONTROL

retrieve
control fields bit 3: Constants.AR_FIELD_TYPE_PAGE

retrieve
page fields bit 4: Constants.AR_FIELD_TYPE_PAGE_HOLDER

retrieve
page holder fields bit 5: Constants.AR_FIELD_TYPE_TABLE

retrieve
table fields bit 6: Constants.AR_FIELD_TYPE_COLUMN

retrieve
column fields bit 7: Constants.AR_FIELD_TYPE_ATTACH

retrieve
attachment fields bit 8: Constants.AR_FIELD_TYPE_ATTACH_POOL

retrieve
attachment pool fields Constants.AR_FIELD_TYPE_ALL

retrieve
all type of fieldschangedSince - A timestamp that limits the fields
retrieved to those modified after the specified time. Specify 0 for this
parameter to retrieve fields with any modification timestamp.criteria - the
infomation to retrieve*Throws:*ARException

-
if information is not returned


On Fri, Aug 8, 2014 at 5:34 AM, Sweety  wrote:

> Hello List,
>
> It has been a quite long I haven't talked to you guys. Hoping all are good
> and enjoying.
>
> I want to fetch the list of data fields only with names and their ids. I
> have tried using method GetListField but it is giving me all the fields on
> the form including buttons, panels etc. I want to fetch only data field
> details from API.
>
> Any suggestions?
>
> Cheers!
>
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


Re: API:Only Data field names and Ids

2014-08-08 Thread Misi Mladoniczky
Hi,

The ARGetMultipleFields() which will give you enough details to figure out
which fieldids you want.

You must look at the data type of the field to determine if it is a data
bearing field.

If the data type is <= 14 the field can hold data. You should use the constant
AR_MAX_STD_DATA_TYPE instead of 14 though.

Best Regards - Misi, RRR AB, http://www.rrr.se (ARSList MVP 2011)

Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13):
* RRR|License - Not enough Remedy licenses? Save money by optimizing.
* RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs.
Find these products, and many free tools and utilities, at http://rrr.se.

> Hello List,
>
> It has been a quite long I haven't talked to you guys. Hoping all are good and
> enjoying.
>
> I want to fetch the list of data fields only with names and their ids. I have
> tried using method GetListField but it is giving me all the fields on the form
> including buttons, panels etc. I want to fetch only data field details from
> API.
>
> Any suggestions?
>
> Cheers!
>
> ___
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
> "Where the Answers Are, and have been for 20 years"
>

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"


API:Only Data field names and Ids

2014-08-08 Thread Sweety
Hello List,

It has been a quite long I haven't talked to you guys. Hoping all are good and 
enjoying.

I want to fetch the list of data fields only with names and their ids. I have 
tried using method GetListField but it is giving me all the fields on the form 
including buttons, panels etc. I want to fetch only data field details from API.

Any suggestions?

Cheers!

___
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"