Archive for September, 2007

How to get the deleted rows from SaveFormData

September 10, 2007
 
IRRecordset2 rstDeleted;
rstDeleted = (IRRecordset2) pForm.SecondaryFromVariantArray(
                                    Recordsets, “Assistants”);
 
foreach (object deletedId in rstDeleted.DeletedRecordIds)
{
    //Do Something with your id here
}
Advertisements

Hide Foreign Key Field

September 10, 2007
 
'**********************************************************************
' Name    : HideForeignFieldEx
' Purpose : To Hide FK Field using DHTML
'**********************************************************************
' Inputs:
'   sTabName : tab name   
'   sSegmentName : segment name       
'   sFieldName : field name
' Returns:
'   N/A
'**********************************************************************
Sub HideForeignFieldEx(sTabName, sSegmentName, sFieldName) 
    
    Dim oField 
    Set oField = UIMaster.RUICenter.GetForeignFieldEx(sTabName, _ 
                                    sSegmentName, sFieldName)
    Dim oTDs    
    Dim oTD
    
    'Hide the label
    UIMaster.RUICenter.GetFieldLabelEx(sTabName, _ 
                       sSegmentName, sFieldName).style.display = "none" 
    'Hide the Input
    oField.InputElement.style.display = "none" 
    Set oTDs = oField.ParentElement.GetElementsByTagName("TD")
    For Each oTD In oTDs
        oTD.style.display = "none"
    Next
End Sub