spss script

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

spss script

Ignace Butaye
Anybody who knows how to change the script:

How can the following script be adapted for the whole output file

http://www.spsstools.net/Scripts/OutputFormat/SizeLabelsToAvoidLine-Wrapping
.txt

this script applies only to one pivot table and I want to apply this to all
pivot tables

thanks,

Ignace Butaye
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: spss script

George Emerson D'Umbra
Hi all,

I am posting it again as text because the list rejects .sbs as attachments.
What kind of extensions can we attach?
Regards,
George


Option Explicit

Sub Main

 Dim objOutputDoc As ISpssOutputDoc
 Dim objItems As ISpssItems
 Dim objItem As ISpssItem
 Dim objPivotTable As PivotTable

 Dim intCount As Integer    'total number of output items
    Dim intIndex As Integer    'loop counter, corresponds index (position)
of each item

    Set objOutputDoc = objSpssApp.GetDesignatedOutputDoc
 Set objItems = objOutputDoc.Items

 intCount = objItems.Count  'Count method returns the number

    objOutputDoc.ClearSelection

 For intIndex = 0 To intCount - 1

  Set objItem = objItems.GetItem(intIndex)
        If objItem.SPSSType = 5 Then

   Set objPivotTable = objItem.ActivateTable
   Call SetPivotTableColumnLabelsToNoWrap (objPivotTable)
   Call SetPivotTableRowLabelsToNoWrap (objPivotTable)
   objItem.Deactivate

  End If
    Next


End Sub


----- Original Message -----
From: "Ignace Butaye" <[hidden email]>
To: <[hidden email]>
Sent: Friday, February 16, 2007 2:09 PM
Subject: spss script


> Anybody who knows how to change the script:
>
> How can the following script be adapted for the whole output file
>
> http://www.spsstools.net/Scripts/OutputFormat/SizeLabelsToAvoidLine-Wrapping
> .txt
>
> this script applies only to one pivot table and I want to apply this to
> all
> pivot tables
>
> thanks,
>
> Ignace Butaye
> [hidden email]