![]() |
#1 |
Участник
|
COMVariant type to work with Excel in AX
Источник: http://alexvoy.blogspot.com/2012/03/...-excel-in.html
============== To avoid eventual issues while working with Excel objects in X++, do not forget about COMVariant type in AX! Lets say we output some information directly to an Excel file and want to change the current row height based on the number of strings on notes. ... COM rng; COMVariant rowHeightVariant; real rowHeight; ... rng = wks.Range(strFmt("A%1", curRow)); cell.Value2(_route.OprNum); // to keep the current row height rowHeightVariant = rng.RowHeight(); rowHeight = rowHeightVariant.double(); ... //to adjust the row height accordingly to the number of strings in notes rng.RowHeight(rowHeight*this.countLines(notes)); ... Unfortunately, I had spent so much time trying to understand the reason of errors until I found this posting. Thank you Max! Источник: http://alexvoy.blogspot.com/2012/03/...-excel-in.html
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору. |
|
|
Опции темы | Поиск в этой теме |
Опции просмотра | |
|