Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Msgbox question

Is it possible I can obtain the Msgbox-button text?
If you issue a msgbox command like:
Msgbox "Question", vbDefaultButton1 + vbYesNoCancel

in a English Excel it will be displayed like the following:


Title: Microsoft Excel
Text: Question
Buttons: <Yes <No <Cancel

but in Spanish Excel it will be displayed like this:

Title: Microsoft Excel
Text: Question
Buttons: <Si <No <Cancelar

I need the text Yes,No,Cancel or Si,No,Cancelar, previous
to the issuing of the message box, because my "Text" has
that text on it.

Thanks
Francisco Mariscal

fcomariscal at hotmail dot com
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Msgbox question

Pacho no entiendo explicate mejor
"Pancho" wrote in message
...
Is it possible I can obtain the Msgbox-button text?
If you issue a msgbox command like:
Msgbox "Question", vbDefaultButton1 + vbYesNoCancel

in a English Excel it will be displayed like the following:


Title: Microsoft Excel
Text: Question
Buttons: <Yes <No <Cancel

but in Spanish Excel it will be displayed like this:

Title: Microsoft Excel
Text: Question
Buttons: <Si <No <Cancelar

I need the text Yes,No,Cancel or Si,No,Cancelar, previous
to the issuing of the message box, because my "Text" has
that text on it.

Thanks
Francisco Mariscal

fcomariscal at hotmail dot com



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Msgbox question

Jose, Gracias por contestar, lo que tengo es un letrero
que le pide al usuario :
Archivo Ya existe desea crear uno Nuevo?
<Yes para crear uno nuevo borrando el anterior
<No para abrir el archivo anterior y usarlo
<Cancel para Cancelar y no hacer nada

pero esos letreros de Yes, No, Cancel debo poder
cambiarlos dependiendo del idioma del Excel (Es una rutina
con usuarios, Brasileños, Norteamericanos, españoles e
Italianos)
Y el mensaje esta usando actualmente una instruccion
MsgBox, por eso necesito saber que palabras usa Excel en
cada uno de los idiomas para ponerle a los botones de
YesNOCancel,
Y queria ver si es posible saberlo directamente de los
botones?

Gracias
Francisco Mariscal
fcomariscal at hotmail dot com

-----Original Message-----
Pacho no entiendo explicate mejor
"Pancho" wrote in

message
...
Is it possible I can obtain the Msgbox-button text?
If you issue a msgbox command like:
Msgbox "Question", vbDefaultButton1 + vbYesNoCancel

in a English Excel it will be displayed like the

following:


Title: Microsoft Excel
Text: Question
Buttons: <Yes <No <Cancel

but in Spanish Excel it will be displayed like this:

Title: Microsoft Excel
Text: Question
Buttons: <Si <No <Cancelar

I need the text Yes,No,Cancel or Si,No,Cancelar,

previous
to the issuing of the message box, because my "Text" has
that text on it.

Thanks
Francisco Mariscal

fcomariscal at hotmail dot com



.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,327
Default Msgbox question

Hi Francisco

I think that is close to impossible from what I've seen on newsgroups like
"microsoft.public.win32.programmer.internation al".

But if english, spanish and maybe a few other languages are what you need;
you can obtain Excel's language version with
Application.International(xlCountryCode) and do a select case ti decide
which message to use. Determining Windows' (=Application.OperatingSystem)
language version is far trickier, but see
http://www.microsoft.com/globaldev/d...efault.mspx#Q4

--
HTH. Best wishes Harald
Followup to newsgroup only please

"Pancho" skrev i melding
...
Is it possible I can obtain the Msgbox-button text?
If you issue a msgbox command like:
Msgbox "Question", vbDefaultButton1 + vbYesNoCancel

in a English Excel it will be displayed like the following:


Title: Microsoft Excel
Text: Question
Buttons: <Yes <No <Cancel

but in Spanish Excel it will be displayed like this:

Title: Microsoft Excel
Text: Question
Buttons: <Si <No <Cancelar

I need the text Yes,No,Cancel or Si,No,Cancelar, previous
to the issuing of the message box, because my "Text" has
that text on it.

Thanks
Francisco Mariscal

fcomariscal at hotmail dot com



  #5   Report Post  
Posted to microsoft.public.excel.programming
jaf jaf is offline
external usenet poster
 
Posts: 300
Default Msgbox question

Hi Pancho,
If you only have a few strings to deal with you can do something like this.

'in a public module
Dim MyLangID As String, MyStrings(2) As String

Sub test()
Set objLangSet = Application.LanguageSettings

If objLangSet.LanguageID(msoLanguageIDInstall) = 1033 Then
MyLangID = "English"
MyStrings(0) = "Question"
MyStrings(1) = "Error"
Else
MyLangID = "Español "
MyStrings(0) = "Pregunta"
MyStrings(1) = "Error"
End If
Debug.Print MyLangID, MyStrings(0), MyStrings(1)
End Sub

Sub anywhere()
Msgbox MyString(0), vbDefaultButton1 + vbYesNoCancel

End Sub

--

John

johnf202 at hotmail dot com


"Pancho" wrote in message
...
Is it possible I can obtain the Msgbox-button text?
If you issue a msgbox command like:
Msgbox "Question", vbDefaultButton1 + vbYesNoCancel

in a English Excel it will be displayed like the following:


Title: Microsoft Excel
Text: Question
Buttons: <Yes <No <Cancel

but in Spanish Excel it will be displayed like this:

Title: Microsoft Excel
Text: Question
Buttons: <Si <No <Cancelar

I need the text Yes,No,Cancel or Si,No,Cancelar, previous
to the issuing of the message box, because my "Text" has
that text on it.

Thanks
Francisco Mariscal

fcomariscal at hotmail dot com





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how can I get a msgbox? AND Excel Discussion (Misc queries) 0 February 12th 09 12:47 PM
msgbox question Wu Excel Discussion (Misc queries) 2 November 9th 08 11:26 AM
msgbox muddan madhu Excel Worksheet Functions 2 April 14th 08 05:06 AM
MsgBox Question Chip Pearson Excel Programming 1 September 29th 03 05:56 PM
MsgBox redmad Excel Programming 1 August 1st 03 12:18 AM


All times are GMT +1. The time now is 06:40 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"