MS Project Automation - Show hidden field

P

Phil Johnson

Hello,

I have written a C# utility that creates an MS Project file and it's great,
the only thing is I populate one of the fields (text1) that is not displayed
by default in a new file.

I cannot find a way of displaying or hiding fields via code.

If anybody knows how to do this in any language (C#, VB, VBA etc) then
please let me know... if I know the method call I should be able to work out
how to do it in C#.
 
P

pderrow

Hello,

I have written a C# utility that creates an MS Project file and it's great,
the only thing is I populate one of the fields (text1) that is not displayed
by default in a new file.

I cannot find a way of displaying or hiding fields via code.

If anybody knows how to do this in any language (C#, VB, VBA etc) then
please let me know... if I know the method call I should be able to work out
how to do it in C#.


You probably worked this part out, but if you record a macro of the
'show' column you get this VBA:

Sub showColumn()
' Macro showColumn
SelectTaskColumn Column:="Name"

TableEdit Name:="&Entry", TaskTable:=True, NewName:="",
FieldName:="", NewFieldName:="Text1", Title:="", Width:=10, Align:=2,
ShowInMenu:=True, LockFirstColumn:=True, DateFormat:=255,
RowHeight:=1, ColumnPosition:=1, AlignTitle:=1

TableApply Name:="&Entry"
End Sub

Good luck,
Phil
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top