Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to change column data type in a child table on runtime

Status
Not open for further replies.

Cucciolatam

Programmer
Jan 19, 2009
7
IT
I have to tranfer data from a child table to Excel, but this child table is created on runtime and all column are string. I need to transform some of these into number or date but I didn't find the function.. maybe it doesn't exists.. or maybe there is a library that I don't have...
The version of my Centura is 2.1 PTF 4 (I know, we are behind the times with the updating!!)
I hope someone could help me!
Thanks!
 
Have you seen M!Table for exporting TableWindows to Excel - doesnt care what type of column you have. If not, I can direct you to it.

or try SAL function:

nColId = SalTblCreateColumnEx( hWndTbl, nColumnPos, nDispWidth, strTitle, nMaxChars, nDatatype )

Creates a table window column using a data type that you specify, at runtime.
When you return to design mode, SQLWindows destroys the column.

Parameters

hWndTbl Window Handle. The handle (or name) of a table window.
nColumnPos Number. The Column Position
nDispWidth Number. The display width of the column in inches.
strTitle String. The column title.
nMaxChars Number. The maximum number of characters that the column can contain.
nDatatype Number. One of the constants DT_String, DT_Number, or DT_DateTime. Any other value will cause an error.
Return Value

nColId is the Column Identifier of the new column. nColld is negative one (-1) if an error occurs.




See me at:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top