Thread: Command Button
View Single Post
  #4   Report Post  
Cindy M -WordMVP-
 
Posts: n/a
Default

Hi ?B?SmFjayBHaWxsZXNwaWU=?=,

OK... It looks like, due to the sort process, the button control is being
removed, then recreated. What about splitting the table header row from the
rest of the table? Split the table, then format the paragraph mark between the
two with a 1 pt font and minimal line spacing, so that it appears to be the
same table. Then change the macro accordingly (2nd table in the doc, no header
in the table).

The code is very simple and this snippet
shows how the buttons and subs are being renamed:


Private Sub btnDueDate_Click() 'Intial value
ActiveDocument.Tables(1).Select
ActiveDocument.Tables(1).Sort excludeheader, 5
End Sub

Private Sub btnDueDate1111_Click() ' renamed value after the command button
has been clicked 4x.


Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :-)