Change SPSS column width

Jun 23, 2010 at 6:44 AM

Hi All,

In variable view  In SPSS viewer, there are 2 columns 'width' and 'column' ('width' is memory allocation for a variable and 'column' is showing length in viewer). in C# I can change both of them as I want, only can change is columnWidth of SpssVariable. if chane columnWidth property  in c# both 'column' and 'width' properties have changed. is there any way to change 'width' and 'column' properties separately as I want?

 

Thanks.

Kasun.

 

Coordinator
Jun 25, 2010 at 3:29 AM

Hi Kasun,
If I understand you correctly, in the SPSS program, a variable has numbers for both a "width" and a "column".  But the SpssVariable class exposes a ColumnWidth property which seems to combine the two concepts so you can set them independently.  Is that right?
If so, I don't know how to fix that.  SPSS's data file only exposes a method called spssSetVarColumnWidth, and it just takes one number -- not two.  If you can review the SPSS documentation (available as part of the source to this project under the file "Resources\SPSS 14.0 for Windows Developer's Guide.pdf" and find the solution I'd be happy to implement it.

Jun 28, 2010 at 7:09 AM

Hi AArnott,

I found the solution for my question, actually I want to do this with SPSSString variables. in SPSSString variable there are tow properties length and columnWidth. using those variables I have able  to change 'column' and 'width' properties separately.

 

Thanks.