Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
I have a listbox and I have for example 3 numbers selected and I only want to copy these numbers to excel.
my code right now is:
ActiveDocument.GetSheetObject("LB07").Restore
ActiveDocument.GetSheetObject("LB07").CopyTableToClipboard true
XLSheet.Paste XLSheet.Range("B2")
XLSheet.Cells.EntireColumn.AutoFit
ActiveDocument.GetApplication.WaitForIdle
ActiveDocument.ClearCache
the problem is that this code copys the whole listbox to excel but I only want the 3 selected values to be copyed. How can I do this?
regards
MT
Use a table box instead of the listbox. Or use an expression aggr(MyField, MyField) for the listbox instead of the field MyField.
ok it is a quiet good workaround but I am not really satisfied. but thanks for your help
regards,
MT