Click or drag to resize
RunGetRecordIdList Method
Gets the record id list from active search page according to GetRecordIdListEnum, selected,all or shown records.

Namespace:  Biolomics.BioCallback
Assembly:  Biolomics.BioCallback (in Biolomics.BioCallback.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public static int GetRecordIdList(
	ref List<int> p_RecIdList,
	RunGetRecordIdListEnum p_What
)

Parameters

p_RecIdList
Type: System.Collections.GenericListInt32
The record id list.
p_What
Type: Biolomics.BioCallbackRunGetRecordIdListEnum
The GetRecordIdListEnum choosen to return records.

Return Value

Type: Int32
Error code.
Examples
This is an example of use of GetSelRecordIdList to get selected records ids.
Example VB.Net
Imports System
Imports BioloMICS.BioCallback
Imports BioloMICS.SharedClasses
Imports System.Collections

Public Class Program

    <STAThread()>
    Shared Sub Main()
        Dim program As New Program
        program.RunQuery()
    End Sub

    Public Sub RunQuery()

        '    *****    Get selected record IDs    *****
        Dim RecordIdList As New Generic.List(Of Integer)
        Dim ErrorCode As Integer = Run.GetRecordIdList(RecordIdList, Run.GetRecordIdListEnum.Selected)
        Console.Write(vbCrLf & "There is " & RecordIdList.Count().ToString() & " record(s) selected")

        '    *****    Get all record IDs of the current table    *****
        ErrorCode = Run.GetRecordIdList(RecordIdList, Run.GetRecordIdListEnum.All)
        Console.Write(vbCrLf & "There is " & RecordIdList.Count().ToString() & " record(s) in the current table")

        '    *****    Get the ID list of all records displayed in the current table    *****
        ErrorCode = Run.GetRecordIdList(RecordIdList, Run.GetRecordIdListEnum.Displayed)
        If ErrorCode <> 0 Then
            Console.Write(vbCrLf & "Could not read the currently selected record ID list")
            Return
        End If
        Console.Write(vbCrLf & "There is " & RecordIdList.Count().ToString() & " record(s) displayed")
    End Sub

    '    display all recent error messages
    Public Sub DrawMessages()
        Dim ErrorList As Generic.List(Of String) = Run.GetLastErrorMessage()
        For Each errorMsg As String In ErrorList
            Console.Write(vbcrlf & errorMsg)
        Next
    End Sub
End Class
See Also