With ActiveSheet
...
.Cells(row, col) = "Update"
...
End With
I found there the equivalent is xlSet but it does not work as
mentioned in http://msdn.microsoft.com/en-us/library/bb687835.aspx
Also is there anyway to set the caller cell to wrap text if my UDF in
the xll return a native data type char* with multiple newline?
Please advise.
I reference the example code from http://msdn.microsoft.com/en-us/library/bb687826.aspx:
short WINAPI xlSetExample(short int iVal)
{
XLOPER xRef, xValue;
xRef.xltype = xltypeSRef;
xRef.val.sref.count = 1;
xRef.val.sref.ref.rwFirst = 204;
xRef.val.sref.ref.rwLast = 205;
xRef.val.sref.ref.colFirst = 1;
xRef.val.sref.ref.colLast = 1;
xValue.xltype = xltypeInt;
xValue.val.w = iVal;
Excel4(xlSet, 0, 2, &xRef, &xValue);
return 1;
}
This function is call from a thread but the worksheet freezes
immediately after calling the excel function. Any idea why?