PolarBears was telling us:
PolarBears nous racontait que :
> What kind of a response is that?!? I simply am asking how to repeat
> the table headers on each page in Visual Basic. Previously,
> documentation had indicated that the HeadingFormat set to -1 would
> cause this. But it is not working. So I'm trying to figure out how.
> If you don't have an answer, don't reply!!
Wow... Please, take a step back!
I would love to help, this is why I asked questions. If I did not want to
help or answer, I would have ignored your post.
Please, read your original post as if you had not written it (and try to be
objective).
The only questions you had are:
"Do I need to manually check for end of page?
If so, also how would you go about that?"
You have to agree that it has nothing to do with
tbl.Rows(1).HeadingFormat = -1
working or not.
You never stated that this particular line of code was not working.
You simply stated:
<quote>
I have tried the statement:
tbl.Rows(1).HeadingFormat = -1
I am wondering since my table is being created dynamically if that is an
issue.
<end quote>
I did not see a question and asked about this issue you mentionned. I am
sorry if I was incapable of guessing that you were not getting the expected
results, especially since you did not state what you expected nor did you
describe the results you were getting. Very often in these groups people
have expectations that are beyond what the code that they are using can
produce. I am not saying this is your case, but, just to make sure, I did
try to make you write some more so that we do not waste our mutual time
trying to address an issue that is totally besides the point.
Finally, since I was not sure what the actual problem was, I asked at the
end:
"Why would you want to check for the end of the page?"
because this is a common question (People want to know the available space
at the bottom of a page before inserting something on that page, I thought
this might be something you might have been concerned about, hence my
question.)
So, now, let's try to see what your problem is.
You stated that you created a table dynamically.
Then, you ran:
tbl.Rows(1).HeadingFormat = -1
and you stated that it is not working.
The ".Rows(1).HeadingFormat = -1" part is definitely correct.
What do you mean by not working? Is the table that you created dynamically
spanning more than one page? What else does your code do to the table?
(Please, do not take this the wrong way, but in these groups, the statement
"It is not working." is one of the least useful in helping those that are
trying to understand the problem, and yet it is one of the most common.
Almost every single time, some will eventually ask "What do you mean by 'It
is not working.'?" It is much better to state the expectations and the
actual results.)
Also, what code did you use to dynamically create your table? In other
words, are you sure that "tbl" in the code you posted actually refers to the
table your code creates? Can you post that code?

Signature
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
jmarcilREMOVE@CAPSsympatico.caTHISTOO
Word MVP site: http://www.word.mvps.org