R
Raquel
Hello,
I am very new in VBA for MS Project and I am very lost. :-((
Let me share my problem with you:
I need to check if a task has a Calendar associated.
What I am doing is:
For Each t In ActiveProject.Tasks
If t.Calendar <> "None" Then
.......
End If
but this only works with English installations and I need a multilingual
tool, so...
My next step was try to translate the "None" to the user language. But I
need the Project installation language (not the PC one...)
I have this already done in excel:
Public Sub TranslateConstantToLocalLanguage()
Dim lang As String
lang = Application.International(xlCountryCode)
If lang = 49 Then
cNone = "Ohne" ' German
ElseIf lang = 34 Then
cNone = "Ninguno" ' Spanish
Else: cNone = "None" ' default English
End If
End Sub
but in MS Project Application object has no International method. :-((
So, my question is:
Does anybody know the name constant where None value is stored for doing
If t.Calendar <> pjNoneValue Then...
If not, does anybody know how to get the MS Project language installation?
Any clue will be appreciated.
Thanks in advance,
Raquel
I am very new in VBA for MS Project and I am very lost. :-((
Let me share my problem with you:
I need to check if a task has a Calendar associated.
What I am doing is:
For Each t In ActiveProject.Tasks
If t.Calendar <> "None" Then
.......
End If
but this only works with English installations and I need a multilingual
tool, so...
My next step was try to translate the "None" to the user language. But I
need the Project installation language (not the PC one...)
I have this already done in excel:
Public Sub TranslateConstantToLocalLanguage()
Dim lang As String
lang = Application.International(xlCountryCode)
If lang = 49 Then
cNone = "Ohne" ' German
ElseIf lang = 34 Then
cNone = "Ninguno" ' Spanish
Else: cNone = "None" ' default English
End If
End Sub
but in MS Project Application object has no International method. :-((
So, my question is:
Does anybody know the name constant where None value is stored for doing
If t.Calendar <> pjNoneValue Then...
If not, does anybody know how to get the MS Project language installation?
Any clue will be appreciated.
Thanks in advance,
Raquel