Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
I am using straight table in my application. One of the column in this table contains all the values starting with 000. i.e. values are 000567858,0003434343 something like this. When I use sent to xls option. It exports the table in to xls but the column containing the above values are filtered. It removes the 000 from this column and values for this column are shown as 567858,3434343 etc in the xls.We want to export the whole value (000567858,0003434343) to the xls.
Does anybody know how to do this?
Anyhelp on this will be really appriciated.
Thanks,
Chandan
Convert it to text while loading. Something like below!
LOAD Text(userid) as userid,
password
;
LOAD * INLINE [
userid, password
0034123, 14324
0012343, 65435
0054361, 64352
0075617, 62346
]
;
[\code]
</body>
Thanks dsjain,
It is working when we are using send to Excel option. However, we have written a macro which is called on the button. The purpose of this macro to export the data from this straight table to excel file. However, the above fix is not working when we are using macro. For you reference , following is the code of the macro which is used for exporting data from straight table to excel.
sub
CopyToXL
' Set Excel App
set
XLApp = CreateObject("Excel.Application")' Define Object
True
'Visible set as true
set
XLDoc = XLApp.Workbooks.Add'Open new workbook
'--------------------------------
set
XLSheet = XLDoc.Worksheets(1)
' Get Line Chart
set
table = ActiveDocument.GetSheetObject("Table1")
' Copy table and paste into Excel
set
XLSheet = XLDoc.Worksheets(1)
true
end
sub
Where Table1 is the Object Id of the straight table.
Let me know if you need any other details on this.
Thanks dsjain,
It is working when we are using send to Excel option. However, we have written a macro which is called on the button. The purpose of this macro to export the data from this straight table to excel file. However, the above fix is not working when we are using macro. For you reference , following is the code of the macro which is used for exporting data from straight table to excel.
sub
CopyToXL
' Set Excel App
set
XLApp = CreateObject("Excel.Application")' Define Object
True
'Visible set as true
set
XLDoc = XLApp.Workbooks.Add'Open new workbook
'--------------------------------
set
XLSheet = XLDoc.Worksheets(1)
' Get Line Chart
set
table = ActiveDocument.GetSheetObject("Table1")
' Copy table and paste into Excel
set
XLSheet = XLDoc.Worksheets(1)
true
end
sub
Where Table1 is the Object Id of the straight table.
Let me know if you need any other details on this.
Hi Mahajan!
I don't how to do that in your case. If I get to know any solution I will let you know.
Thanks and Regards,
Rikab
does any one got the answer for this ?? i m facing similar problem.
Hi Mahajan
I found a way!!! Instead of using copytabletoclipboard.. Use copytext to clipboard.
Copytable to clipboard removes all the formatting applied to the columns.
Copy text to clipboard retains the formatting but the column names will be missed. But you can hardcode the column names and push the data to next row.
Hope it is clear.