MSI Factory 2.3

MSI.ViewGetColumnInfo

MSI.ViewGetColumnInfo

This is the first topic This is the last topic  

MSI.ViewGetColumnInfo

This is the first topic This is the last topic  

OverviewExamples

number MSI.ViewGetColumnInfo (

number hView,

number ColumnInfo )

Example 1

hDatabase = MSI.GetActiveDatabase(_hInstall);

if (hDatabase ~= 0) then

 

   strQuery = "SELECT * FROM `Feature`";

   hView = MSI.DatabaseOpenView(hDatabase, strQuery);

 

   if (hView ~= 0) then

 

       hRecord = MSI.ViewGetColumnInfo(hView, MSICOLINFO_NAMES);

       nNumFields = MSI.RecordGetFieldCount(hRecord);

 

       if (nNumFields > 0) then

 

           strMessage = "The column names of the Feature table are:\r\n\r\n";

           for index = 1, nNumFields do

               strRecordString = MSI.RecordGetString(hRecord, index);

               strMessage = strMessage..strRecordString.."\r\n";

           end

 

           Dialog.Message("Column Names", strMessage);

       end

 

       MSI.CloseHandle(hRecord);

       MSI.ViewClose(hView);

       MSI.CloseHandle(hView);

 

   end

 

   MSI.CloseHandle(hDatabase);

end

Gets the names of the columns in the "Features" table and shows them in a dialog message.

See also: Related Actions


Learn More: Indigo Rose Software - MSI Factory - Buy Now - Contact Us