Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Can QlikView export a table contents in fixed Width text by one button and what macros should I have?
E.g. Let's say I have a table with the following data:
Name: Number:
Mary Johnson 1029384756
My source file should have a single space to divide and a Name of 30 symbols and a Number of 10 symobols.
Look at the attached file
Not sure if this is suitable, however my approach would be to pad out each column:
Load script:
Name & if(len(Name) <= 30, repeat( ' ', (30-len(Name)) ), 'String too long' & repeat( ' ', 15) ) as fw_Name
macro:
set foo = ActiveDocument.GetSheetObject("TB01")
foo.Export "C:\test.txt" , ""
depending on what you are doing with those fields elsewhere in the app, you may need to create a copy load and copy objects that are purely for the padded out values and use those for exporting, whilst preserving the originals for calculations etc.
Thanks adamvaughan for your fast answer,
but I need VB macro to set formating, 'cause I want to modify some charts data..