topic
stringlengths
1
63
text
stringlengths
1
577k
Buttonbar en una posición fija
No quiero ser pesimista pero a menos que toques el código de la clase no vas a poder porque la buttonbar se crea por defecto Top y solo puede manejar controles Button y no otros ( solo puedes fijar controles no button una vez creada ). Si intentas, una vez creada, cambiar su posición verás que tira un error ( es lo que te está pasando en este momento ). Lo que se me ocurre es que en la clase le pongas por defecto que sea Float. Espero te sirva.
Buttonbar en una posición fija
Patricio Probé, tu propuesta pero no funciona. Es porque si le pongo solo oDlg, ya los elementos no forman parte de la Buttonbar, porque esta solo permite incluir botones por definición; el poner oDlg:oBar es para que a pesar de no ser botones se incluyan en la barra. jresojeda Igual me bota error; creo que no es lo mismo crear la barra con New() que con NewAt(), revisando el codigo y la sintaxis de creación tienen diferencias. Saludos y gracias por su respuesta Fernando Espinoza
Buttonbar en una posición fija
Amigo... Quizá el problema es que la barra está en el diálogo. Yo lo pruebo en una ventana oWndChild y funciona bien.
Buttonbar en una posición fija
Eduardo Podrías poner un poco de tu código de creación de la ventana, o enviarlo a mi correo: <!-- e --><a href="mailto:nanoespinoza@hotmail.com">nanoespinoza@hotmail.com</a><!-- e -->
Buttonbar en una posición fija
Eduardo Ya probe con ventanas MDI y me sale el mismo error. Voy a poner todo mi código (donde da error), y una imagen para q tengan una idea mas clara: [code=fw:32tlcrtf]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">FUNCTION</span> Bitacora<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"RichEdit.ch"</span><br /><span style="color: #00D7D7;">#define</span> FW_BOLD         <span style="color: #000000;">700</span><br /><span style="color: #00C800;">LOCAL</span> oFont, oFont2, oGet, hDLL := LoadLibrary<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Riched20.dll"</span> <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">PRIVATE</span> oDlg, oPrueba1, cDatos:=cResultados:=<span style="color: #ff0000;">""</span>, dFecha:=CToD<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"  /  /    "</span><span style="color: #000000;">&#41;</span>, m_FILE:=SPACE<span style="color: #000000;">&#40;</span><span style="color: #000000;">8</span><span style="color: #000000;">&#41;</span>, oFont3<br /><span style="color: #00C800;">PRIVATE</span> oRtf, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">7</span><span style="color: #000000;">&#93;</span>, lBold, lItalic, lUnderline<br />SET _3DLOOK <span style="color: #0000ff;">ON</span><br />* Lectura de datos y resultados del día de hoy<br /><span style="color: #00C800;">IF</span> FILE<span style="color: #000000;">&#40;</span>RUTRES+<span style="color: #ff0000;">"BITACORA.DBF"</span><span style="color: #000000;">&#41;</span><br />    USE &RUTRES.BITACORA<br />    <span style="color: #0000ff;">INDEX</span> <span style="color: #0000ff;">ON</span> DIA <span style="color: #0000ff;">TO</span> &RUTRES.BITACORA<br />    <span style="color: #00C800;">IF</span> DBSeek<span style="color: #000000;">&#40;</span> DATE<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        cResultados=RESULTADOS<br />        cDatos=DATOS<br />    <span style="color: #00C800;">ELSE</span><br />        cResultados=<span style="color: #ff0000;">""</span><br />        cDatos=<span style="color: #ff0000;">""</span><br />    <span style="color: #00C800;">ENDIF</span><br /><span style="color: #00C800;">ELSE</span><br />    <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"No existe el archivo de bitácora"</span>+CRLF+<span style="color: #ff0000;">"Volveremos al menú principal"</span>, <span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span><br />    FreeLibrary<span style="color: #000000;">&#40;</span>hDLL<span style="color: #000000;">&#41;</span><br />    DBCloseArea<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />    RETU .T.<br /><span style="color: #00C800;">ENDIF</span><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont  <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Arial"</span>         <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-14</span><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont2 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-11</span><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont3 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-12</span><br />* <span style="color: #0000ff;">Define</span> dialogo<br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">OF</span> oVent <span style="color: #0000ff;">FROM</span> <span style="color: #000000;">10</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">417</span>,<span style="color: #000000;">762</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Bitácora de SicefWin"</span><br />    oDlg:<span style="color: #000000;">nStyle</span> := nOr<span style="color: #000000;">&#40;</span> oDlg:<span style="color: #000000;">nStyle</span>, <span style="color: #000000;">4</span> <span style="color: #000000;">&#41;</span><br />    * Control MiCalendario<br />    oPrueba1:= TMiCalendario<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>: <span style="color: #00C800;">New</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">5</span>, <span style="color: #000000;">5</span>,<span style="color: #000000;">120</span>,<span style="color: #000000;">120</span>, oDlg, oFont<span style="color: #000000;">&#41;</span><br />    oPrueba1:<span style="color: #000000;">FijaClrDomingo</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#123;</span>rgb<span style="color: #000000;">&#40;</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span><span style="color: #000000;">&#41;</span>,;   <span style="color: #B900B9;">//Color borde superior   // Para pintar los domingos de otro color...</span><br />                              rgb<span style="color: #000000;">&#40;</span> <span style="color: #000000;">220</span>, <span style="color: #000000;">220</span>, <span style="color: #000000;">220</span><span style="color: #000000;">&#41;</span>,;   <span style="color: #B900B9;">//Color relleno</span><br />                                      rgb<span style="color: #000000;">&#40;</span> <span style="color: #000000;">128</span>, <span style="color: #000000;">128</span>, <span style="color: #000000;">128</span><span style="color: #000000;">&#41;</span>,;   <span style="color: #B900B9;">//Color borde inferior</span><br />                                      rgb<span style="color: #000000;">&#40;</span>   <span style="color: #000000;">0</span>,   <span style="color: #000000;">0</span>,   <span style="color: #000000;">0</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span> <span style="color: #B900B9;">//color texto....</span><br />    oPrueba1:<span style="color: #000000;">bAction</span> := <span style="color: #000000;">&#123;</span> |dFechaControl| <span style="color: #000000;">&#40;</span>LeeResultados<span style="color: #000000;">&#40;</span>dFechaControl<span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, ;<br />        oRtf:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    oPrueba1:<span style="color: #000000;">bCambioMes</span> := <span style="color: #000000;">&#123;</span> || FijarFestivos<span style="color: #000000;">&#40;</span> oPrueba1 <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>        <span style="color: #B900B9;">// Al cambiar de mes... se asignan nuevos festivos...</span><br /><br />    * <span style="color: #0000ff;">Say</span> y Gets con los resultados en el día seleccionado<br />    @ <span style="color: #000000;">4</span>,<span style="color: #000000;">130</span> <span style="color: #0000ff;">SAY</span> <span style="color: #ff0000;">"Resultados en el día seleccionado:"</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">COLOR</span> CLR_RED,GetSysColor<span style="color: #000000;">&#40;</span><span style="color: #000000;">15</span><span style="color: #000000;">&#41;</span><br />    @ <span style="color: #000000;">11</span>,<span style="color: #000000;">130</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> cResultados MEMO <span style="color: #0000ff;">OF</span> oDlg READONLY <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">240</span>,<span style="color: #000000;">55</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">FONT</span> oFont2 ;<br />        <span style="color: #0000ff;">COLOR</span> RGB<span style="color: #000000;">&#40;</span><span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span><span style="color: #000000;">&#41;</span>, RGB<span style="color: #000000;">&#40;</span><span style="color: #000000;">231</span>,<span style="color: #000000;">235</span>,<span style="color: #000000;">222</span><span style="color: #000000;">&#41;</span><br />        oGet:<span style="color: #000000;">cToolTip</span> := <span style="color: #ff0000;">"Resultados en el día seleccionado"</span><br /><br />    @ <span style="color: #000000;">68</span>,<span style="color: #000000;">130</span> <span style="color: #0000ff;">SAY</span> <span style="color: #ff0000;">"HECHOS relevantes del día seleccionado:"</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">120</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">COLOR</span> CLR_RED,GetSysColor<span style="color: #000000;">&#40;</span><span style="color: #000000;">15</span><span style="color: #000000;">&#41;</span><br /><br />    * Editor de texto RichEdit para detalles o cronicas<br />    @ <span style="color: #000000;">89</span>,<span style="color: #000000;">130</span> RICHEDIT oRtf <span style="color: #0000ff;">VAR</span> cDatos <span style="color: #0000ff;">OF</span> oDlg FILE cDatos <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">240</span>,<span style="color: #000000;">99</span> <span style="color: #0000ff;">FONT</span> oFont3<br />        *<span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Enable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        *<span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> <span style="color: #000000;">&#40;</span> RefreshButtonBar<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Enable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oRtf:<span style="color: #000000;">cToolTip</span>:=<span style="color: #ff0000;">"Vista de los hechos relevantes del día seleccionado"</span><br />        oRtf:<span style="color: #000000;">nClrText</span>:=CLR_GRAY<br />        oRtf:<span style="color: #000000;">SetFontName</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Ms Sans Serif"</span><span style="color: #000000;">&#41;</span><br />        oRtf:<span style="color: #000000;">SetFontSize</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">11</span><span style="color: #000000;">&#41;</span><br /><br />    * Botones de control<br />    @ <span style="color: #000000;">188</span>,<span style="color: #000000;">310</span> BUTTONBMP oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"     &Grabar Datos"</span> BITMAP <span style="color: #ff0000;">"SAVE"</span> TEXTRIGHT <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">60</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>cDatos:=oRTF:<span style="color: #000000;">SaveAsRTF</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, GrabaBtcr<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"No ha habido cambios en el texto"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Graba datos del campo Hechos relevantes del día"</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />    @ <span style="color: #000000;">147</span>,<span style="color: #000000;">5</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Seleccionar &día"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">54</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgYesNo<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"¿Pierde los cambios que realizó en Hechos?"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span><span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgGet<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Seleccionar día"</span>,<span style="color: #ff0000;">"Ingresar día a consultar:"</span>,@dFecha,<span style="color: #000000;">&#41;</span>, oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span> dFecha <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span>, ;<br />        LeeResultados<span style="color: #000000;">&#40;</span>dFecha<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span><span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgGet<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Seleccionar día"</span>,<span style="color: #ff0000;">"Ingresar día a consultar:"</span>,@dFecha,<span style="color: #000000;">&#41;</span>, oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span> dFecha <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span>, ;<br />        LeeResultados<span style="color: #000000;">&#40;</span>dFecha<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Seleccionar un día específico"</span><br /><br />    @ <span style="color: #000000;">147</span>,<span style="color: #000000;">70</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"&Ir al día de hoy"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">54</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgYesNo<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"¿Pierde los cambios que realizó en Hechos?"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Ir al día de hoy"</span><br /><br />    @ <span style="color: #000000;">166</span>,<span style="color: #000000;">5</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Día &anterior"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">54</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgYesNo<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"¿Pierde los cambios que realizó en Hechos?"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">-1</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span>, ;<br />        oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> , <span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">-1</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span>, ;<br />        oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Pasa al día anterior"</span><br /><br />    @ <span style="color: #000000;">166</span>,<span style="color: #000000;">70</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Día si&guiente"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">54</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgYesNo<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"¿Pierde los cambios que realizó en Hechos?"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">+1</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span>, ;<br />        oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> , <span style="color: #000000;">&#41;</span>, ;<br />        <span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">IrFecha</span><span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">+1</span><span style="color: #000000;">&#41;</span>, LeeResultados<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span>, ;<br />        oRTF:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRTF:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #0000ff;">Update</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Pasa al día siguiente"</span><br /><br />    @ <span style="color: #000000;">185</span>,<span style="color: #000000;">5</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">6</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"&Regrabar resultados"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">68</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> MsgMeter<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#123;</span>|oMet,oText,oDlg,lEnd| RegrabaRes<span style="color: #000000;">&#40;</span>oMet,oText,oDlg,@lEnd<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#125;</span>,<span style="color: #ff0000;">"Procesando..."</span>, <span style="color: #ff0000;">"Por favor, espere"</span><span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">6</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Regraba todos los resultados históricos de todos los torneos"</span><br /><br />    @ <span style="color: #000000;">185</span>,<span style="color: #000000;">79</span> BUTTONBMP oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">7</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"            &Salir"</span> BITMAP <span style="color: #ff0000;">"CANCELAR"</span> TEXTRIGHT <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">45</span>,<span style="color: #000000;">12</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRTF:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> MsgYesNo<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"¿Pierde los cambios que realizó en Hechos?"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span>, ;<br />        oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>cDatos:=oRTF:<span style="color: #000000;">SaveAsRTF</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, GrabaBtcr<span style="color: #000000;">&#40;</span>oPrueba1:<span style="color: #000000;">dFechaControl</span><span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">7</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cToolTip</span>=<span style="color: #ff0000;">"Salir"</span><br />    oDlg:<span style="color: #000000;">bInit</span>  := <span style="color: #000000;">&#123;</span> || RefreshBar<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    *oDlg:<span style="color: #000000;">bValid</span> := <span style="color: #000000;">&#123;</span> || RefreshBar<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    oDlg:<span style="color: #000000;">oClient</span> = oRtf<br />    *oDlg:<span style="color: #000000;">lHelpIcon</span>:= .F.  <span style="color: #B900B9;">// comentado al probar con Window</span><br /><span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> <span style="color: #000000;">&#40;</span>oDlg:<span style="color: #000000;">SetIcon</span><span style="color: #000000;">&#40;</span>oApp:<span style="color: #000000;">cIcono</span><span style="color: #000000;">&#41;</span>, Centra<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span>, CargaBarra<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span>, ;<br />    oRtf:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>,  ;<br />    oRtf:<span style="color: #000000;">bChange</span>:=<span style="color: #000000;">&#123;</span> || <span style="color: #000000;">&#40;</span> RefreshButtonBar<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">IsModify</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Enable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, ;<br />    Eval<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">bChange</span> <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, .F.<span style="color: #000000;">&#41;</span><br />    *oRtf:<span style="color: #000000;">LoadAsRTF</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span>cDatos<span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">bChange</span>:=<span style="color: #000000;">&#123;</span> || RefreshButtonBar<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, Eval<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">bChange</span> <span style="color: #000000;">&#41;</span>, ;<br />    <span style="color: #B900B9;">// el valor .F. al final en ON INIT es para q cambie el focus inicial grabado en los recursos</span><br />    <span style="color: #B900B9;">// la Button Bar en los dialog se carga a través de ON INIT</span><br /><span style="color: #00C800;">IF</span> oDlg:<span style="color: #000000;">nResult</span>=<span style="color: #000000;">1</span><br />    <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Datos se grabaron con éxito"</span>,<span style="color: #ff0000;">"Atención"</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">ENDIF</span><br /><span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont<br /><span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont2<br /><span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont3<br />FreeLibrary<span style="color: #000000;">&#40;</span>hDLL<span style="color: #000000;">&#41;</span><br />DBCloseArea<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br />*FDF Bitacora<br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> RefreshBar<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">LOCAL</span> oBar := oDlg:<span style="color: #000000;">oBar</span>:<span style="color: #000000;">aControls</span><br />    <span style="color: #00C800;">IF</span> Len<span style="color: #000000;">&#40;</span> oDlg:<span style="color: #000000;">oWndClient</span>:<span style="color: #000000;">aWnd</span> <span style="color: #000000;">&#41;</span> == <span style="color: #000000;">1</span><br />        AEval<span style="color: #000000;">&#40;</span> oBar, <span style="color: #000000;">&#123;</span> |x, y| <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> y == <span style="color: #000000;">1</span>, x:<span style="color: #000000;">Enable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, x:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, <span style="color: #000000;">1</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span>   <span style="color: #B900B9;">// no hace nada, porq la barra de botones está reducida, sin los primeros botones Save, ...</span><br />        AEval<span style="color: #000000;">&#40;</span> oBar, <span style="color: #000000;">&#123;</span> |x| x:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, <span style="color: #000000;">1</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><span style="color: #00C800;">RETURN</span> .t.<br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> RefreshButtonBar<span style="color: #000000;">&#40;</span> oDlg <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">LOCAL</span> oBar   := oDlg:<span style="color: #000000;">oBar</span>:<span style="color: #000000;">aControls</span><br />    <span style="color: #00C800;">LOCAL</span> aChar  := REGetCharFormat<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">LOCAL</span> nAlign := REGetParaFormat<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">&#41;</span><br />    oBar<span style="color: #000000;">&#91;</span> <span style="color: #000000;">6</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := lBold      := aChar<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> == FW_BOLD<br />    oBar<span style="color: #000000;">&#91;</span> <span style="color: #000000;">7</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := lItalic    := aChar<span style="color: #000000;">&#91;</span><span style="color: #000000;">6</span><span style="color: #000000;">&#93;</span><br />    oBar<span style="color: #000000;">&#91;</span> <span style="color: #000000;">8</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := lUnderline := aChar<span style="color: #000000;">&#91;</span><span style="color: #000000;">7</span><span style="color: #000000;">&#93;</span><br />    oBar<span style="color: #000000;">&#91;</span> <span style="color: #000000;">9</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := nAlign == PFA_LEFT<br />    oBar<span style="color: #000000;">&#91;</span><span style="color: #000000;">10</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := nAlign == PFA_CENTER<br />    oBar<span style="color: #000000;">&#91;</span><span style="color: #000000;">11</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := nAlign == PFA_RIGHT<br />    oBar<span style="color: #000000;">&#91;</span><span style="color: #000000;">12</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">lPressed</span> := nAlign == PFA_JUSTIFY<br />    oBar<span style="color: #000000;">&#91;</span><span style="color: #000000;">13</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">VarPut</span><span style="color: #000000;">&#40;</span> aChar<span style="color: #000000;">&#91;</span><span style="color: #000000;">14</span><span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span>                 <span style="color: #B900B9;">// Font</span><br />    oBar<span style="color: #000000;">&#91;</span><span style="color: #000000;">14</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">VarPut</span><span style="color: #000000;">&#40;</span> aChar<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span>                 <span style="color: #B900B9;">// Tamaño del font, es 9 por omisión</span><br />    AEval<span style="color: #000000;">&#40;</span> oBar, <span style="color: #000000;">&#123;</span> |x| <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> x:<span style="color: #000000;">lWhen</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, x:<span style="color: #000000;">Enable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, x:<span style="color: #000000;">Disable</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, x:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, <span style="color: #000000;">1</span>, <span style="color: #000000;">14</span> <span style="color: #000000;">&#41;</span><br />RETU .T.<br />*FDF RefreshButtonBar<br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> CargaBarra<span style="color: #000000;">&#40;</span>oDlg<span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> oBar, oCursor, hDC, aFonts, oClp, oBold, oItalic, oUnderline, oItem, cFont, oSize, nSize:=<span style="color: #000000;">10</span><br />hDC    := GetDC<span style="color: #000000;">&#40;</span> oDlg:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">&#41;</span><br />aFonts := ASort<span style="color: #000000;">&#40;</span> GetFontNames<span style="color: #000000;">&#40;</span> hDC <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />ReleaseDC<span style="color: #000000;">&#40;</span> oDlg:<span style="color: #000000;">hWnd</span>, hDC <span style="color: #000000;">&#41;</span><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">CURSOR</span> oCursor HAND<br /><span style="color: #0000ff;">DEFINE</span> CLIPBOARD oClp <span style="color: #0000ff;">OF</span> oDlg FORMAT <span style="color: #0000ff;">TEXT</span><br />* Controles de la <span style="color: #0000ff;">ButtonBar</span><br />@ <span style="color: #000000;">150</span>,<span style="color: #000000;">260</span> <span style="color: #0000ff;">BUTTONBAR</span> oBar <span style="color: #0000ff;">OF</span> oDlg 3DLOOK <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">480</span>,<span style="color: #000000;">27</span> BUTTONSIZE <span style="color: #000000;">24</span>,<span style="color: #000000;">24</span> TOP<br />   <span style="color: #B900B9;">// 1</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Cut"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Cortar"</span> NOBORDER ;<br />        <span style="color: #0000ff;">WHEN</span> <span style="color: #000000;">&#40;</span> ! Empty<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">GetSel</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> .and. ! oRtf:<span style="color: #000000;">lReadOnly</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">Cut</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Cierra archivo abierto"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 2</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Copy"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Copiar"</span> NOBORDER ;<br />        <span style="color: #0000ff;">WHEN</span> <span style="color: #000000;">&#40;</span> ! Empty<span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">GetSel</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">Copy</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Copiar"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 3</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Paste"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Pegar"</span> NOBORDER ;<br />        <span style="color: #0000ff;">WHEN</span> <span style="color: #000000;">&#40;</span> ! Empty<span style="color: #000000;">&#40;</span> oClp:<span style="color: #000000;">GetText</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> .and. ! oRtf:<span style="color: #000000;">lReadOnly</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">Paste</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Pegar"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 4</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Undo"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Deshacer"</span> NOBORDER ;<br />        <span style="color: #0000ff;">WHEN</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SendMsg</span><span style="color: #000000;">&#40;</span> EM_CANUNDO <span style="color: #000000;">&#41;</span> != <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">Undo</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Deshacer"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 5</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Redo"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Rehacer"</span> NOBORDER ;<br />        <span style="color: #0000ff;">WHEN</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SendMsg</span><span style="color: #000000;">&#40;</span> EM_CANREDO <span style="color: #000000;">&#41;</span> != <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">Redo</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Rehacer"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 6</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBold <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Bold"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Negrita"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> lBold := !lBold, oBold:<span style="color: #000000;">lPressed</span> := lBold, oBold:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, ;<br />                    oRtf:<span style="color: #000000;">SetBold</span><span style="color: #000000;">&#40;</span> lBold <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Negrita"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 7</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oItalic <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Italic"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Italica"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> lItalic := !lItalic, oItalic:<span style="color: #000000;">lPressed</span> := lItalic, oItalic:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, ;<br />                    oRtf:<span style="color: #000000;">SetItalic</span><span style="color: #000000;">&#40;</span> lItalic <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Italica"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 8</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oUnderline <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Underline"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Subrayado"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> lUnderline := !lUnderline, oUnderline:<span style="color: #000000;">lPressed</span> := lUnderline, oUnderline:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, ;<br />                    oRtf:<span style="color: #000000;">SetUnderline</span><span style="color: #000000;">&#40;</span> lUnderline <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Subrayado"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 9</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Left"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Alinea a la izquierda"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetAlign</span><span style="color: #000000;">&#40;</span> PFA_LEFT <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Alinea a la izquierda"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 10</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Center"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Alinea al centro"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetAlign</span><span style="color: #000000;">&#40;</span> PFA_CENTER <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Alinea al centro"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 11</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Right"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Alinea a la derecha"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetAlign</span><span style="color: #000000;">&#40;</span> PFA_RIGHT <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Alinea a la  derecha"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 12</span><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Justify"</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Justifica a ambos lados"</span> NOBORDER ;<br />        <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetAlign</span><span style="color: #000000;">&#40;</span> PFA_JUSTIFY <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ;<br />        TOOLTIP <span style="color: #ff0000;">"Justifica a ambos lados"</span> TRANSPARENT <span style="color: #0000ff;">CENTER</span><br />   <span style="color: #B900B9;">// 13</span><br />    @ <span style="color: #000000;">153</span>,<span style="color: #000000;">561</span> <span style="color: #0000ff;">COMBOBOX</span> oItem <span style="color: #0000ff;">VAR</span> cFont <span style="color: #0000ff;">ITEMS</span> aFonts <span style="color: #0000ff;">OF</span> oDlg:<span style="color: #000000;">oBar</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">133</span>,<span style="color: #000000;">120</span> <span style="color: #0000ff;">FONT</span> oFont3 ;<br />        <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetFontName</span><span style="color: #000000;">&#40;</span> oItem:<span style="color: #000000;">VarGet</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oItem:<span style="color: #000000;">cToolTip</span> := <span style="color: #ff0000;">"Nombre de fuente"</span><br />   <span style="color: #B900B9;">// 14</span><br />    @ <span style="color: #000000;">153</span>,<span style="color: #000000;">695</span> <span style="color: #0000ff;">GET</span> oSize <span style="color: #0000ff;">VAR</span> nSize <span style="color: #0000ff;">OF</span> oDlg:<span style="color: #000000;">oBar</span> <span style="color: #0000ff;">FONT</span> oFont3 <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">21</span>,<span style="color: #000000;">21</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"99"</span> SPINNER <span style="color: #0000ff;">MIN</span> <span style="color: #000000;">6</span> <span style="color: #0000ff;">MAX</span> <span style="color: #000000;">99</span> <span style="color: #0000ff;">RIGHT</span> ;<br />        <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> <span style="color: #000000;">&#40;</span> oRtf:<span style="color: #000000;">SetFontSize</span><span style="color: #000000;">&#40;</span> oSize:<span style="color: #000000;">VarGet</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, oRtf:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />        oSize:<span style="color: #000000;">Set3DLook</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />        oSize:<span style="color: #000000;">cToolTip</span> := <span style="color: #ff0000;">"Tamaño de fuente"</span><br /><br />    AEval<span style="color: #000000;">&#40;</span> oBar:<span style="color: #000000;">aControls</span>, <span style="color: #000000;">&#123;</span> |x| x:<span style="color: #000000;">nLeft</span> += <span style="color: #000000;">226</span>, x:<span style="color: #000000;">nRight</span> += <span style="color: #000000;">226</span> <span style="color: #000000;">&#125;</span>, <span style="color: #000000;">14</span> <span style="color: #000000;">&#41;</span><br /><br />    oBar:<span style="color: #000000;">bLClicked</span> := <span style="color: #000000;">&#123;</span> || <span style="color: #00C800;">nil</span> <span style="color: #000000;">&#125;</span><br />    oBar:<span style="color: #000000;">bRClicked</span> := <span style="color: #000000;">&#123;</span> || <span style="color: #00C800;">nil</span> <span style="color: #000000;">&#125;</span><br /><br />    AEval<span style="color: #000000;">&#40;</span> oBar:<span style="color: #000000;">aControls</span>, <span style="color: #000000;">&#123;</span> |x| x:<span style="color: #000000;">oCursor</span> := oCursor <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><br />    * Solo para comprobar cuantos elementos tienen la barra<br />    ? <span style="color: #ff0000;">"Elementos de la barra: "</span>+Str<span style="color: #000000;">&#40;</span> Len<span style="color: #000000;">&#40;</span> oBar:<span style="color: #000000;">aControls</span> <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">3</span> <span style="color: #000000;">&#41;</span><br /><br />RETU .T.<br />*FDF CargaBarra<br /><br /> </div>[/code:32tlcrtf] La imagen de lo que quiero, justo antes del siguiente mensaje de error: Aplicación =========== Ruta y nombre: C:\SICEF_~1\SicefWin.Exe (32 bits) Tama±o: 1,329,664 bytes Tiempo desde inicio: 0 hours 1 mins 54 secs Error ocurrido en: 11/01/2010, 10:42:52 Descripción de error: Error BASE/1004 Class: 'NIL' has no exported method: ACONTROLS Args: [ 1] = U Stack Calls =========== Llamado de ACONTROLS(0) Llamado de REFRESHBUTTONBAR(0) Llamado de (b)BITACORA(0) Llamado de (b)BITACORA(0) Llamado de TDIALOG:INITIATE(705) Llamado de TDIALOG:HANDLEEVENT(912) Llamado de DIALOGBOXINDIRECT(0) Llamado de TDIALOG:ACTIVATE(273) Llamado de BITACORA(0) Llamado de (b)MENU_H(0) Llamado de TMENU:COMMAND(437) Llamado de TWINDOW:COMMAND(1003) Llamado de TWINDOW:HANDLEEVENT(0) Llamado de _FWH(3333) Llamado de WINRUN(0) Llamado de TWINDOW:ACTIVATE(952) Llamado de INICIO(0) [img] <!-- m --><a class="postlink" href="http://img3.imageshack.us/img3/9493/pantallasicef.jpg">http://img3.imageshack.us/img3/9493/pantallasicef.jpg</a><!-- m --> [/img] Como verán es un dialogo, donde inserto un control MiCalendario y un control RichEdit, con la ButtonBar ubicada del medio a la derecha.
Buttonbar en una posición fija
Fernando, > Pero usando el mismo código con una Buttonbar fija, todo funciona bien Creala fija y luego haz: [code=fw:382o0apl]<div class="fw" id="{CB}" style="font-family: monospace;"><br />oDlg:<span style="color: #000000;">oBar</span> = <span style="color: #00C800;">nil</span><br />oDlg:<span style="color: #000000;">oTop</span> = <span style="color: #00C800;">nil</span><br />oBar:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> nRow, nCol <span style="color: #000000;">&#41;</span> <span style="color: #B900B9;">// la posición en donde quieras situarla</span><br />&nbsp;</div>[/code:382o0apl]
Buttonbar en una posición fija
Antonio Ya probé su sugerencia; creo la buttonbar fija al Tope (Top), no da error, la cargo desde ON INIT, se crea con los 14 controles; la muevo a la nueva posición luego de creada la barra, en ON INIT con los comandos que me indicaste; pero al moverse a la nueva posición y volver a ejecutarse la función RefreshButtonBar() cuando el control RichEdit tiene el foco, de nuevo aparece el error: Aplicación =========== Ruta y nombre: C:\SICEF_~1\SicefWin.Exe (32 bits) Tama±o: 1,329,664 bytes Tiempo desde inicio: 0 hours 1 mins 28 secs Error ocurrido en: 11/01/2010, 19:16:57 Descripción de error: Error BASE/1004 Class: 'NIL' has no exported method: ACONTROLS Args: [ 1] = U Stack Calls =========== Llamado de ACONTROLS(0) Llamado de REFRESHBUTTONBAR(0) Llamado de (b)BITACORA(0) Llamado de (b)TRICHEDIT:TRICHEDIT(64) Llamado de TRICHEDIT:CHANGE(0) Llamado de TCONTROL:HANDLEEVENT(1426) Llamado de TRICHEDIT:HANDLEEVENT(623) Llamado de _FWH(3333) Llamado de DIALOGBOXINDIRECT(0) Llamado de TDIALOG:ACTIVATE(273) Llamado de BITACORA(0) Llamado de (b)MENU_H(0) Llamado de TMENU:COMMAND(437) Llamado de TWINDOW:COMMAND(1003) Llamado de TWINDOW:HANDLEEVENT(0) Llamado de _FWH(3333) Llamado de WINRUN(0) Llamado de TWINDOW:ACTIVATE(952) Llamado de INICIO(0)
Buttonbar en una posición fija
Fernando, Es que oDlg:oBar se hace nil y entonces la llamada a oDlg:oBar:aControls genera el error. Deberias pasarle oBar a RefreshButtonBar( oBar ) en vez de pasarle oDlg
Buttonbar en una posición fija
Maestro Antonio; ahora si funciona muy bien, era como usted indico. Solo un favor más, al mover de posición la barra, se muestra un marco que termina fuera del dialogo, como hago para que no se pinte ese marco. Saludos y gracias
Buttonbar estilo 2010 ( Solucionado )
Colegas, estoy migrando una aplicación de FWH 14.12 a FWH 16.12. La ButtonBar tiene estilo 2010 pero ahora difieren. Adjunto imágenes Con FWH14.12 [img:1pm4bzjh]http&#58;//i65&#46;tinypic&#46;com/9vaa83&#46;jpg[/img:1pm4bzjh] Con FWH16.12 [img:1pm4bzjh]http&#58;//i63&#46;tinypic&#46;com/2jecp60&#46;jpg[/img:1pm4bzjh] Probé con el estilo 2013 y es parecido pero las imágenes de los botones se ve el fondo del bitmap. Con la versión anterior esto no ocurria. Alguna idea ? Muchas gracias. Saludos
Buttonbar estilo 2010 ( Solucionado )
He utilizado el bitmap "previous.bmp" de la carpeta "bitmaps\32x32" Estilo 2010 [img:de9js7hp]https&#58;//s30&#46;postimg&#46;org/5t7w4prb5/child04&#46;png[/img:de9js7hp] Estilo 2013 [img:de9js7hp]https&#58;//s28&#46;postimg&#46;org/9dmcux4v1/child05&#46;png[/img:de9js7hp]
Buttonbar estilo 2010 ( Solucionado )
Gracias Cristobal por tu respuesta pero no soluciona mi problema, supongo que hay compatibilidad hacia atrás. No dudo que usando los bitmaps que proporciona FW funcionen como en tu caso pero yo utilizo otros y obtengo el resultado que muestro en la imagen que postee en este hilo. El mismo bitmap en dos versiones diferentes de FWH no se ven de la misma manera, incluso con la clausula 2010 si paso el ratón sobre él, uno se ilumina con un degradado amarillo estilo 2007 y el otro es azul. Intenté con el estilo 2013 que es mas parecido a lo que necesito pero el fondo del bitmap no se pinta y se ve blanco. Esto tiene alguna solución ? Muchas gracias. Saludos
Buttonbar estilo 2010 ( Solucionado )
Horacio, no tengo constancia de haber modificado los estilos anteriores Pero, si puedes proporcionar el recurso que utilizas con gusto lo pruebo
Buttonbar estilo 2010 ( Solucionado )
Cristobal, mañana te mando el recurso ya que lo tengo en la empresa. Muchas gracias. Saludos
Buttonbar estilo 2010 ( Solucionado )
Buen día Cristobal, adonde mando el recuros ? Saludos
Buttonbar estilo 2010 ( Solucionado )
Horacio Consider this code ... [code=fw:ykxzkhhv]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTONBAR</span> oBar <span style="color: #0000ff;">OF</span> oWind <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">80</span>,<span style="color: #000000;">58</span> <span style="color: #000000;">2010</span>    <br />       oBar:<span style="color: #000000;">SetColor</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">0</span><span style="color: #000000;">&#41;</span><br />                             <br />       oBar:<span style="color: #000000;">bClrGrad</span> = <span style="color: #000000;">&#123;</span> || <span style="color: #000000;">&#123;</span> <span style="color: #000000;">&#123;</span> <span style="color: #000000;">0.10</span>,<span style="color: #000000;">15724527</span>,<span style="color: #000000;">7303023</span> <span style="color: #000000;">&#125;</span>, ;<br />                       <span style="color: #000000;">&#123;</span> <span style="color: #000000;">0.10</span>,<span style="color: #000000;">7303023</span>,<span style="color: #000000;">15724527</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span><br /><br />      <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBtn1 <span style="color: #0000ff;">of</span> oBar <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> _VehBrow<span style="color: #000000;">&#40;</span> oWind <span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> ;<br />              <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Car"</span>,;<br />                       <span style="color: #ff0000;">"Car"</span>,;<br />                       <span style="color: #ff0000;">"Car"</span>;<br />              <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Veh<span style="color: #000000;">\E</span>q<span style="color: #000000;">\B</span>oat"</span> ;<br />              TOOLTIP <span style="color: #ff0000;">"Vehicles and Equipment Information"</span><br />       oBtn1:<span style="color: #000000;">lTransparent</span> = .T.      <span style="color: #B900B9;">// <-----  add this line</span><br /> </div>[/code:ykxzkhhv] Try adding oBtn1:lTransparent = .t. after your Button Command .. Rick Lipkin
Buttonbar estilo 2010 ( Solucionado )
[quote="horacio":3pykyaxx]Buen día Cristobal, adonde mando el recuros ? Saludos[/quote:3pykyaxx] Horacio, a mi cuenta de correo
Buttonbar estilo 2010 ( Solucionado )
Rick, thanks for your reply. With your code I get this [img:1kzvfeiy]http&#58;//i67&#46;tinypic&#46;com/or8n0l&#46;jpg[/img:1kzvfeiy] Saludos
Buttonbar estilo 2010 ( Solucionado )
Cristobal, enviado. Saludos
Buttonbar estilo 2010 ( Solucionado )
Cristobal, ya lo solucioné. Tenia en la compilación el archivo fwbmp.c de la versión FWH 14.12. Mil disculpas y muchas gracias por tu tiempo. Saludos
Buttonbar estilo 2010 ( Solucionado )
[quote="horacio":18tc99nf]Cristobal, enviado. Saludos[/quote:18tc99nf] No me ha llegado Pero me alegro que lo hayas solucionado
Buttonbar help
Hi, I have a buttonbar in resource but the size after compile dont respect the resource size, see the image below: [img:3jc2a22t]https&#58;//i&#46;ibb&#46;co/gjRFBFs/Buttonbar&#46;jpg[/img:3jc2a22t] In my code I use this: REDEFINE BUTTONBAR oBar10 ID 100 OF oDlg20 How I can adjust? Thanks in advance
Buttonbar help
[quote="wartiaga":17rdqro8]Hi, I have a buttonbar in resource but the size after compile dont respect the resource size, see the image below: In my code I use this: REDEFINE BUTTONBAR oBar10 ID 100 OF oDlg20 How I can adjust? Thanks in advance[/quote:17rdqro8] Try with oBar10:nRight := 300 ( or any value ), after the REDEFINE If it does not work, try putting this instruction in the ON INIT clause of the dialog or container window
Buttonbar help
[quote="cnavarro":3k12vvl0][quote="wartiaga":3k12vvl0]Hi, I have a buttonbar in resource but the size after compile dont respect the resource size, see the image below: In my code I use this: REDEFINE BUTTONBAR oBar10 ID 100 OF oDlg20 How I can adjust? Thanks in advance[/quote:3k12vvl0] Try with oBar10:nRight := 300 ( or any value ), after the REDEFINE If it does not work, try putting this instruction in the ON INIT clause of the dialog or container window[/quote:3k12vvl0] Thanks but no success in both options.
Buttonbar help
Also, try with oBar10:Move( ..... ) METHOD ( on init clause )
Buttonbar help
[quote="cnavarro":2mp5y4lq]Also, try with oBar10:Move( ..... ) METHOD ( on init clause )[/quote:2mp5y4lq] Move works but just move the bar not change the size.
Buttonbar help
I think method Move allow change size, not? [quote:4ozugoem] Move( nTop, nLeft, nWidth, nHeight, lRepaint ) [/quote:4ozugoem]
Buttonbar help
[quote="cnavarro":27vaqlnj]I think method Move allow change size, not? [quote:27vaqlnj] Move( nTop, nLeft, nWidth, nHeight, lRepaint ) [/quote:27vaqlnj][/quote:27vaqlnj] Thank you! It's work! Do you know how i display the buttonbar with border? oBar10:nStyle := WS_BORDER not work.
Buttonbar linea inferior
Hola a todos, Quizas la pregunta es simple, pero no encuentro la forma de hacerlo... es posible hacer que no se muestre la linea inferior en una barra de botones, [url=https&#58;//imgbb&#46;com/:1cdr1rur][img:1cdr1rur]https&#58;//i&#46;ibb&#46;co/QM5fNDg/buttonbar2&#46;jpg[/img:1cdr1rur][/url:1cdr1rur] Este es mi codigo: function Main() local oWnd, oBar, oMsgBar, oBtn, oBrush, oFont DEFINE BRUSH oBrush COLOR RGB(255,255,255) DEFINE FONT oFont NAME "TAHOMA" SIZE 0,-14 DEFINE WINDOW oWnd BRUSH oBrush TITLE "Mi Barra de botones" DEFINE BUTTONBAR oBar OF oWnd SIZE 80,80 2007 oBar:SetFont( oFont ) oBar:SetColor(0) oBar:bClrGrad := { | lPressed | If( ! lPressed,; { { 1, nRGB( 255, 255, 255 ), nRGB( 255, 255, 255 ) } },; { { 1, nRGB( 253, 254, 255 ), nRGB( 192, 192, 192 ) } } ) } DEFINE BUTTON oBtn OF oBar PROMPT "Nuevo" FILE "..\bitmaps\32x32\new.bmp" DEFINE BUTTON oBtn OF oBar PROMPT "Abrir" FILE "..\bitmaps\32x32\open.bmp" DEFINE BUTTON oBtn OF oBar PROMPT "Editar" FILE "..\bitmaps\32x32\edit.bmp" ACTIVATE WINDOW oWnd maximized RELEASE BRUSH oBrush RELEASE FONT oFont return nil Muchas gracias, Saludos,
Buttonbar linea inferior
Quizás así ? [code=fw:1sejx9iy]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTONBAR</span> oBar <span style="color: #0000ff;">OF</span> oWnd <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">80</span>,<span style="color: #000000;">80</span> <span style="color: #000000;">2007</span> NoBorder<br />&nbsp;</div>[/code:1sejx9iy]
Buttonbar linea inferior
Mira si és esto: [code=fw:2mggbd3e]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"FiveWin.Ch"</span><br /><br /><span style="color: #00C800;">FUNCTION</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oWnd, oBar, oMsgBar, oBtn, oBrush, oFont<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BRUSH</span> oBrush <span style="color: #0000ff;">COLOR</span> RGB<span style="color: #000000;">&#40;</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"TAHOMA"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, - <span style="color: #000000;">14</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">BRUSH</span> oBrush <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Mi Barra de botones"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTONBAR</span> oBar <span style="color: #0000ff;">OF</span> oWnd <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">80</span>, <span style="color: #000000;">80</span> <span style="color: #000000;">2015</span> NOBORDER &nbsp;<span style="color: #B900B9;">// aqui</span><br /><br />&nbsp; &nbsp;oBar:<span style="color: #000000;">SetFont</span><span style="color: #000000;">&#40;</span> oFont <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;oBar:<span style="color: #000000;">SetColor</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;oBar:<span style="color: #000000;">bClrGrad</span> := <span style="color: #000000;">&#123;</span> | lPressed | <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> ! lPressed, ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span> <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1</span>, nRGB<span style="color: #000000;">&#40;</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">&#41;</span>, nRGB<span style="color: #000000;">&#40;</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span>, ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span> <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1</span>, nRGB<span style="color: #000000;">&#40;</span> <span style="color: #000000;">253</span>, <span style="color: #000000;">254</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">&#41;</span>, nRGB<span style="color: #000000;">&#40;</span> <span style="color: #000000;">192</span>, <span style="color: #000000;">192</span>, <span style="color: #000000;">192</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBtn <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Nuevo"</span> FILE <span style="color: #ff0000;">"..<span style="color: #000000;">\b</span>itmaps<span style="color: #000000;">\3</span>2x32<span style="color: #000000;">\n</span>ew.bmp"</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBtn <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Abrir"</span> FILE <span style="color: #ff0000;">"..<span style="color: #000000;">\b</span>itmaps<span style="color: #000000;">\3</span>2x32<span style="color: #000000;">\o</span>pen.bmp"</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBtn <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Editar"</span> FILE <span style="color: #ff0000;">"..<span style="color: #000000;">\b</span>itmaps<span style="color: #000000;">\3</span>2x32<span style="color: #000000;">\e</span>dit.bmp"</span><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">maximized</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">BRUSH</span> oBrush<br />&nbsp; &nbsp;<span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont<br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">nil</span><br />&nbsp;</div>[/code:2mggbd3e] Saludos.
Buttonbar linea inferior
Hola, lo logre de la siguiente forma: obar:WinStyle(WS_BORDER, .F.) Muchas gracias, saludos,
Buttonbar question
Hello, How can I check if a buttonbar is enabled or disabled? Thanks a lot in advance.
Buttonbar question
Michel, MsgInfo( IsWindowEnabled( oBar:hWnd ) ) Is that what you mean ?
Buttonbar question
Antonio, Yes, that's it. Thank you very much.
Buttonbar with a get a Combox
I want to put a get and a combobox and two say controls in a buttonbar I use a logical value ltoolbar to display the buttonbar or not when I view it the controls (get, combobox and says) are not visible then if the user passes the mouse over the controls they appear I encountered this problem if I use a buttonbar in a dialog, while in a window it seems to work well
Buttonbar with a get a Combox
Do you have a simple example for testing? ¿Tienes un ejemplo simple para probar?
Buttonbar with a get a Combox
I re-Write the function and now it seems run ok It is very strange [url=https&#58;//postimg&#46;cc/qz60LC5N:1pas0e5i][img:1pas0e5i]https&#58;//i&#46;postimg&#46;cc/qz60LC5N/d&#46;png[/img:1pas0e5i][/url:1pas0e5i] [url=https&#58;//postimg&#46;cc/TK8xHYzC:1pas0e5i][img:1pas0e5i]https&#58;//i&#46;postimg&#46;cc/TK8xHYzC/e&#46;png[/img:1pas0e5i][/url:1pas0e5i] But there is an error on search [url:1pas0e5i]http&#58;//forums&#46;fivetechsupport&#46;com/viewtopic&#46;php?f=3&t=41453&start=0&sid=ec33ff690daae4f356fad968d228e219[/url:1pas0e5i]
Buttonbar y Outlook2003
Hola amigosQuiero poner otra barra de botones en la parte derecha del splitter, y debajo de ella un xbrowse y no se como hacerlo, ya que si me refiero a oWnd, me la planta encima de la que ya hay. Pongo una imagen pazra ver si me explico[url=http&#58;//imageshack&#46;us:2aildbdq][img:2aildbdq]http&#58;//img206&#46;imageshack&#46;us/img206/6951/splitwk8&#46;png[/img:2aildbdq][/url:2aildbdq][url=http&#58;//g&#46;imageshack&#46;us/img206/splitwk8&#46;png/1/:2aildbdq][img:2aildbdq]http&#58;//img206&#46;imageshack&#46;us/img206/splitwk8&#46;png/1/w750&#46;png[/img:2aildbdq][/url:2aildbdq]SaludosJose Luis
Buttonbar y Outlook2003
[quote="JoseLuis":14tuxlo1]Hola amigos Quiero poner otra barra de botones en la parte derecha del splitter, y debajo de ella un xbrowse y no se como hacerlo, ya que si me refiero a oWnd, me la planta encima de la que ya hay. Pongo una imagen pazra ver si me explico Saludos Jose Luis[/quote:14tuxlo1]Prueba esto:Utiliza TPanel y creas el rectangulo conforme al bottom o height de la barra de botones, y desde la columna derecha del spliter, hasta el ancho y altura que desees. Luego creas tu nueva barra de botones como un control dentro de TPanel.Espero te ayude.Francisco
Buttonbmp and image
Hi, How i can change a bitmap of a buttonbmp in execution time? The bitmap are in resource file. Thanks in advance.
Buttonbmp and image
function FromResources() local oDlg DEFINE DIALOG oDlg RESOURCE "Test" REDEFINE [color=#4000FF:pram3ifz]BUTTONBMP[/color:pram3ifz] oBtn1 ID 10 OF oDlg ; ACTION MsgInfo( "XP themes aware Button Bitmaps" ) [color=#FF0000:pram3ifz]oBtn1:LoadBitmap( "Alert" )[/color:pram3ifz] // [color=#008080:pram3ifz]from resource [/color:pram3ifz] // Button 2 changes on Action BMP of Button 1 // ---------------------------------------------------- REDEFINE BUTTONBMP oBtn2 ID 20 OF oDlg ; ACTION ( [color=#FF0000:pram3ifz]oBtn1:LoadBitmap( "Arrow" ), oBtn1:Refresh()[/color:pram3ifz] ) ; // [color=#008000:pram3ifz]from Resource[/color:pram3ifz] BITMAP "..\bitmaps\16x16\garrow.bmp" PROMPT "&Test" TEXTRIGHT // [color=#008000:pram3ifz]from Disk[/color:pram3ifz] ACTIVATE DIALOG oDlg return nil Best Regards Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: -->
Buttonbmp and image
[quote="ukoenig":2bc7bq7u]function FromResources() local oDlg DEFINE DIALOG oDlg RESOURCE "Test" REDEFINE [color=#4000FF:2bc7bq7u]BUTTONBMP[/color:2bc7bq7u] oBtn1 ID 10 OF oDlg ; ACTION MsgInfo( "XP themes aware Button Bitmaps" ) [color=#FF0000:2bc7bq7u]oBtn1:LoadBitmap( "Alert" )[/color:2bc7bq7u] // [color=#008080:2bc7bq7u]from resource [/color:2bc7bq7u] // Button 2 changes on Action BMP of Button 1 // ---------------------------------------------------- REDEFINE BUTTONBMP oBtn2 ID 20 OF oDlg ; ACTION ( [color=#FF0000:2bc7bq7u]oBtn1:LoadBitmap( "Arrow" ), oBtn1:Refresh()[/color:2bc7bq7u] ) ; // [color=#008000:2bc7bq7u]from Resource[/color:2bc7bq7u] BITMAP "..\bitmaps\16x16\garrow.bmp" PROMPT "&Test" TEXTRIGHT // [color=#008000:2bc7bq7u]from Disk[/color:2bc7bq7u] ACTIVATE DIALOG oDlg return nil Best Regards Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: -->[/quote:2bc7bq7u] Thank you!
Buttonbmp problems with the march release
Hello, I have a problem using buttonbmp with this latest fwh release. When I use a buttonbmp from resource the bitmap appairs centered on the button over the text. There wasn't any problems with the February release when using the CANCEL TEXTRIGHT clause all runned fine. Any ideas ? Thanks in advance Best Regards. Marco
Buttonbmp problems with the march release
Marco, The TEXTRIGHT clause is not directly supported by FWH Class TButtonBmp. Are you using Rossine's modified Class ?
Buttonbmp problems with the march release
I am using at this moment only the standard FWH classes but with the previous FWH version I used a modified button and buttonbmp class (I don't know if they coming from Rossine) I made a self-cont sample that show the problem at <!-- w --><a class="postlink" href="http://www.softwarexp.co.uk/beta/sample.zip">www.softwarexp.co.uk/beta/sample.zip</a><!-- w --> Is there any solution using the standard class ? Thanks in advance Best Regards, Marco Turco
Buttonbmp problems with the march release
Marco, We email you Class TButtonBmp modified to allow TEXT... clause and FiveWin.ch. Your sample works ok using TEXTRIGHT clause.
Buttonbmp problems with the march release
Great !! It runs fine. Many thanks for the support. Best Regards, Marco Turco
Buttonbmp problems with the march release
Antonio Fwh 2.5 Users can use this modified TbtnBmp class or just the ones with 2.7 If so, can you send it to me or post it here... Allthoug I have Rossines Modificactions, I tried just to use formal Clases ( not 3º party ones ) Thanks in advance.
Buttonbmp problems with the march release
Adolfo, We have implemented the same command extension as Rossine, though the class just uses one bitmap. Anyhow, you can use Rossine's one as it is compatible with FWH.
Buttons from TaskBar
Hi, all ! How can I get a list of app buttons from Windows 10 TaskBar ?
Buttons from TaskBar
1. Create file XML. sample [code=fw:1azebv4a]<div class="fw" id="{CB}" style="font-family: monospace;"><?xml version=<span style="color: #ff0000;">"1.0"</span> encoding=<span style="color: #ff0000;">"utf-8"</span>?><br /><LayoutModificationTemplate<br />&nbsp; &nbsp; xmlns=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/LayoutModification"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">defaultlayout</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/FullDefaultLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">start</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/StartLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">taskbar</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/TaskbarLayout"</span><br />&nbsp; &nbsp; Version=<span style="color: #ff0000;">"1"</span>><br />&nbsp; <CustomTaskbarLayoutCollection><br />&nbsp; &nbsp; <defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">UWA</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.MicrosoftEdge_8wekyb3d8bbwe!MicrosoftEdge"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">DesktopApp</span> DesktopApplicationLinkPath=<span style="color: #ff0000;">"%APPDATA%<span style="color: #000000;">\M</span>icrosoft<span style="color: #000000;">\W</span>indows<span style="color: #000000;">\S</span>tart Menu<span style="color: #000000;">\P</span>rograms<span style="color: #000000;">\S</span>ystem Tools<span style="color: #000000;">\F</span>ile Explorer.lnk"</span> /><br />&nbsp; &nbsp; &nbsp; </taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; </defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp;</CustomTaskbarLayoutCollection><br /></LayoutModificationTemplate></div>[/code:1azebv4a] Sample configuration of the taskbar added to the Start layout XML file [code=fw:1azebv4a]<div class="fw" id="{CB}" style="font-family: monospace;"><?xml version=<span style="color: #ff0000;">"1.0"</span> encoding=<span style="color: #ff0000;">"utf-8"</span>?><br /><LayoutModificationTemplate<br />&nbsp; &nbsp; xmlns=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/LayoutModification"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">defaultlayout</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/FullDefaultLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">start</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/StartLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">taskbar</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/TaskbarLayout"</span><br />&nbsp; &nbsp; Version=<span style="color: #ff0000;">"1"</span>><br />&nbsp; <LayoutOptions StartTileGroupCellWidth=<span style="color: #ff0000;">"6"</span> StartTileGroupsColumnCount=<span style="color: #ff0000;">"1"</span> /><br />&nbsp; <DefaultLayoutOverride><br />&nbsp; &nbsp; <StartLayoutCollection><br />&nbsp; &nbsp; &nbsp; <defaultlayout:<span style="color: #000000;">StartLayout</span> GroupCellWidth=<span style="color: #ff0000;">"6"</span> xmlns:<span style="color: #000000;">defaultlayout</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/FullDefaultLayout"</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; <start:<span style="color: #000000;">Group</span> <span style="color: #0000ff;">Name</span>=<span style="color: #ff0000;">"Life at a glance"</span> xmlns:<span style="color: #000000;">start</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/StartLayout"</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <start:<span style="color: #000000;">Tile</span> <span style="color: #0000ff;">Size</span>=<span style="color: #ff0000;">"2x2"</span> Column=<span style="color: #ff0000;">"0"</span> Row=<span style="color: #ff0000;">"0"</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.MicrosoftEdge_8wekyb3d8bbwe!MicrosoftEdge"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <start:<span style="color: #000000;">Tile</span> <span style="color: #0000ff;">Size</span>=<span style="color: #ff0000;">"2x2"</span> Column=<span style="color: #ff0000;">"4"</span> Row=<span style="color: #ff0000;">"0"</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.Windows.Cortana_cw5n1h2txyewy!CortanaUI"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <start:<span style="color: #000000;">Tile</span> <span style="color: #0000ff;">Size</span>=<span style="color: #ff0000;">"2x2"</span> Column=<span style="color: #ff0000;">"2"</span> Row=<span style="color: #ff0000;">"0"</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.BingWeather_8wekyb3d8bbwe!App"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; </start:<span style="color: #000000;">Group</span>> &nbsp; &nbsp; &nbsp; &nbsp;<br />&nbsp; &nbsp; &nbsp; </defaultlayout:<span style="color: #000000;">StartLayout</span>><br />&nbsp; &nbsp; </StartLayoutCollection><br />&nbsp; </DefaultLayoutOverride><br />&nbsp; &nbsp; <CustomTaskbarLayoutCollection><br />&nbsp; &nbsp; &nbsp; <defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">UWA</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.MicrosoftEdge_8wekyb3d8bbwe!MicrosoftEdge"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">DesktopApp</span> DesktopApplicationLinkPath=<span style="color: #ff0000;">"%APPDATA%<span style="color: #000000;">\M</span>icrosoft<span style="color: #000000;">\W</span>indows<span style="color: #000000;">\S</span>tart Menu<span style="color: #000000;">\P</span>rograms<span style="color: #000000;">\S</span>ystem Tools<span style="color: #000000;">\F</span>ile Explorer.lnk"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; </taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; &nbsp; </defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp; &nbsp; </CustomTaskbarLayoutCollection><br /></LayoutModificationTemplate></div>[/code:1azebv4a] [b:1azebv4a]Keep the default apps and add custom apps[/b:1azebv4a] [code=fw:1azebv4a]<div class="fw" id="{CB}" style="font-family: monospace;"><?xml version=<span style="color: #ff0000;">"1.0"</span> encoding=<span style="color: #ff0000;">"utf-8"</span>?><br /><LayoutModificationTemplate<br />&nbsp; &nbsp; xmlns=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/LayoutModification"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">defaultlayout</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/FullDefaultLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">start</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/StartLayout"</span><br />&nbsp; &nbsp; xmlns:<span style="color: #000000;">taskbar</span>=<span style="color: #ff0000;">"http://schemas.microsoft.com/Start/2014/TaskbarLayout"</span><br />&nbsp; &nbsp; Version=<span style="color: #ff0000;">"1"</span>><br />&nbsp; <CustomTaskbarLayoutCollection><br />&nbsp; &nbsp; <defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">DesktopApp</span> DesktopApplicationLinkPath=<span style="color: #ff0000;">"%ALLUSERSPROFILE%<span style="color: #000000;">\M</span>icrosoft<span style="color: #000000;">\W</span>indows<span style="color: #000000;">\S</span>tart Menu<span style="color: #000000;">\P</span>rograms<span style="color: #000000;">\A</span>ccessories<span style="color: #000000;">\P</span>aint.lnk"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">UWA</span> AppUserModelID=<span style="color: #ff0000;">"Microsoft.Reader_8wekyb3d8bbwe!Microsoft.Reader"</span> /><br />&nbsp; &nbsp; &nbsp; &nbsp; <taskbar:<span style="color: #000000;">DesktopApp</span> DesktopApplicationLinkPath=<span style="color: #ff0000;">"%appdata%<span style="color: #000000;">\M</span>icrosoft<span style="color: #000000;">\W</span>indows<span style="color: #000000;">\S</span>tart Menu<span style="color: #000000;">\P</span>rograms<span style="color: #000000;">\S</span>ystem Tools<span style="color: #000000;">\C</span>ommand Prompt.lnk"</span> /><br />&nbsp; &nbsp; &nbsp; </taskbar:<span style="color: #000000;">TaskbarPinList</span>><br />&nbsp; &nbsp; </defaultlayout:<span style="color: #000000;">TaskbarLayout</span>><br />&nbsp; </CustomTaskbarLayoutCollection><br /></LayoutModificationTemplate></div>[/code:1azebv4a] before [img:1azebv4a]https&#58;//docs&#46;microsoft&#46;com/it-it/windows/configuration/images/taskbar-default&#46;png[/img:1azebv4a] after [img:1azebv4a]https&#58;//docs&#46;microsoft&#46;com/it-it/windows/configuration/images/taskbar-default-plus&#46;png[/img:1azebv4a] other info you can found at <!-- m --><a class="postlink" href="https://docs.microsoft.com/it-it/windows/configuration/configure-windows-10-taskbar#configurazione-di-esempio-della-barra-delle-applicazioni-aggiunta-al-file-xml-del-layout-start">https://docs.microsoft.com/it-it/window ... yout-start</a><!-- m -->
Buttons from TaskBar
Thank You, Silvio ! I will try
Buttons of ButtonBar syntax
Ok 2 questions: 1. Regular buttons of ButtonBars when disabled will automatically adjust the image to indicate the state unless the button bar use the [b:1vhqpgo4]2007[/b:1vhqpgo4] clause; in which case an image to represent the disabled state must be supplied. Is this understanding correct? 2. Looking at the header file, I find [b:1vhqpgo4]DEFINE BUTTON of oBar[/b:1vhqpgo4] accepts up to 4 image: [code=fw:1vhqpgo4]<div class="fw" id="{CB}" style="font-family: monospace;"><br />#xcommand <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #000000;">&#91;</span> <oBtn> <span style="color: #000000;">&#93;</span> ;<br />             <span style="color: #000000;">&#91;</span> <bar: <span style="color: #0000ff;">OF</span>, <span style="color: #0000ff;">BUTTONBAR</span> > <oBar> <span style="color: #000000;">&#93;</span> ;<br />             <span style="color: #000000;">&#91;</span> <resource: <span style="color: #0000ff;">NAME</span>, <span style="color: #0000ff;">RESNAME</span>, RESOURCE> <cResName1> ;<br />                <span style="color: #000000;">&#91;</span>,<cResName2><span style="color: #000000;">&#91;</span>,<cResName3><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span>,<cResName4><span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#93;</span> ;<br /> </div>[/code:1vhqpgo4] I assume [i:1vhqpgo4]cResName1[/i:1vhqpgo4] indicate the image for normal state while the rest is for disabled, mouse over and something-which-I-don't-know. So the question is, which represents which? TIA
Buttons of ButtonBar syntax
1. Yes 2. Resources / Bitmaps 1. Normal 2. Pressed 3. Disabled 4. Mouse Over
Buttons of ButtonBar syntax
Thanks Rao. I've edited <!-- m --><a class="postlink" href="http://wiki.fivetechsoft.com/doku.php?id=fivewin_commands_bar">http://wiki.fivetechsoft.com/doku.php?i ... mmands_bar</a><!-- m --> a bit to reflect this. Antonio, Would it be possible, even if using ButtonBar 2007, if [i:1n6c1fe9]cResName3[/i:1n6c1fe9] is not supplied then TBtnBmp class would automatically use [i:1n6c1fe9]cResName1[/i:1n6c1fe9] and grey it out? Would be very helpful especially to those who have lots of buttons on the toolbar. TIA
Buttons on ButtonBar FWH 904
Buttonbars built with bitmaps / resources are working well for me on my XP computer. But when I install the application on Win200 or Win2003 server, I can not see the bitmaps on the buttons. All was working well with FWH903. Now, when I compiled and linked old source of btnbmp.prg of FWH903 with my FWH904 application, bitmaps are appearing properly now. Some incompatibility in the revision to btnbmp.prg in version 904. This is brought to the notice of Mr Antonio.
Buttons on ButtonBar FWH 904
[quote="nageswaragunupudi":3l69liom]Buttonbars built with bitmaps / resources are working well for me on my XP computer. But when I install the application on Win200 or Win2003 server, I can not see the bitmaps on the buttons.[/quote:3l69liom]Dear Rao: I think this problem was solved with FWH 9.04 last delivery, check this link: <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=15252&hilit=hasalpha">viewtopic.php?f=3&t=15252&hilit=hasalpha</a><!-- l --> Best regards. Manuel Mercado.
Buttons on meta-files
Hello, A application that I wrote is generating drawing by using meta-files. Then I display them and by using oMeta:blClicked := {|nRow, nCol, nKeyFlags| myfunc(nRow, nCol, nKeyFlags)} I check where the mouse is clicked, then I jump to another drawing. I was wondering that I can use some kind of buttons, it would me easyer because than I don't calculate the area's where the mouse can be clicked. The area's are not always on the same place, and the number of areas can be different. Thanks, Marc
Buttons on meta-files
Marc, You can place a pushbutton on top of a metafile, the usual way: @ ..., ... BUTTON ... OF oMetaFile SIZE ..., ... ACTION ...
Buttons on meta-files
Thanks Antonio, it's working very nice. Is there a way to change the color. I already used button1:color(..,..) but this seems not to work. I use FWH707 Thanks, Marc
Buttons on meta-files
Marc, If you need to change the buttons colors, then use a BTNBMP instead of a BUTTON: @ ..., ... BTNBMP ... OF oMetaFile SIZE ..., ... ACTION ...
Buttons on meta-files
Antonio, What is the use of the 3th bitmap? The second is the one displayed while pressing the button, I never see the 3th. Marc
Buttons on meta-files
Marc, It is shown when the button is disabled
Buttons on meta-files
Antonio, Do I have to release the buttons while ending the window with the buttons? If I call the BTNBMP the first time, everthing is fine. The second time, the text in the buttons are missind, and the other text on the screen are bold. I already tried oBtn:end() with no result. Marc
Buttons on meta-files
Marc, > Do I have to release the buttons while ending the window with the buttons? No, its not needed as they will be automatically destroyed > If I call the BTNBMP the first time, everthing is fine. The second time, the text in the buttons are missind, and the other text on the screen are bold. > Have you defined a font for the buttons ? If yes, do this: oFont:nCount++
Buttons on meta-files
Antonio, Do I have to put this each time before creating a button like this : [code:1x9m1nph]aadd&#40;metatoetsen,nil&#41; schermfont &#58;nCount++ @ y_cor&#40;y+4&#41;, x_cor&#40;x-1 &#41; BTNBMP metatoetsen&#91;len&#40;metatoetsen&#41;&#93; RESOURCE 'GEEL','GEEL2' PROMPT text of oMeta SIZE x_cor&#40;52&#41;,x_cor&#40;13&#41; FONT schermfont action ganaarpunt&#40;text&#41; PIXEL aadd&#40;metatoetsen,nil&#41; schermfont &#58;nCount++ @ y_cor&#40;y+4&#41;, x_cor&#40;x-11&#41; BTNBMP metatoetsen&#91;len&#40;metatoetsen&#41;&#93; RESOURCE 'GEEL','GEEL2' PROMPT ct of oMeta SIZE x_cor&#40;10&#41;,x_cor&#40;13&#41; FONT schermfont action ganaarpunt&#40;text&#41; PIXEL [/code:1x9m1nph] Marc
Buttons on meta-files
Marc, Just one call to schermfont:nCount++ should be enought
Buuuuuuuuu Function ChangeRes no funciona bien :(
encontre en el foro la Function ChangeRes pero no me funciona bien y me deja a 16 bits de color y toda la resolucion mas baja de mi computadora use todas estas resoluciones y ninguna funciona siempre me pone a la mas baja y a 16 bits de color <!-- s:cry: --><img src="{SMILIES_PATH}/icon_cry.gif" alt=":cry:" title="Crying or Very sad" /><!-- s:cry: --> MENUITEM "640x480" ACTION ChangeRes(640,480) MENUITEM "800x600" ACTION ChangeRes(800,600) MENUITEM "1024x768" ACTION ChangeRes(1024,768) MENUITEM "1280x1024" ACTION ChangeRes(1280,1024) Saludos <!-- s:? --><img src="{SMILIES_PATH}/icon_confused.gif" alt=":?" title="Confused" /><!-- s:? --> Aida
Buzzer en CE 5.0
hola, necesito que un Honeywell ScanPal 5100 emita un sonido después de leer un codigo de barras y comprobar que existe dicho codigo. En el emulador suena usando MsgBeep y MessageBeep, pero en el Pocket no suena nada. El pocket tiene instalado Windows CE 5.00 y en el panel de control hay un icono llamado Buzzer donde permite activar y desactivar el sonido de "System" y de "Scan", ya he probado con todas las combinaciones. Creo que el problema puede ser que la función MsgBeep usa el driver del sonido y como este pocket solo tiene el altavoz no recibe la orden. Espero sus comentarios.
Buzzer en CE 5.0
Prueba a usar la función Tone(), por ejemplo: Tone( 500, 2 )
Buzzer en CE 5.0
Es la primera función que usé y en el emulador (wincearm) no se oía, así que la descarté. La he probado ahora directamente en el Scanpal 5100 y tampoco se oye. Gracias por la ayuda.
Buzzer en CE 5.0
Igual tendras que usar un aviso visual tipo MsgInfo() en vez de un sonido
Buzzer en CE 5.0
Ya le aparece al usuario una MsgInfo cuando se lee un codigo de barras que no está en la base de datos de artículos, pero en el Pocket no suena nada y el usuario sigue pasando el escaner por los siguientes artículos sin percatarse que en la pantalla hay un mensaje de error. El problema ocurre porque en los artículos hay dos códigos de barras, el preimpreso del fabricante y una pegatina que tiene el código de barras correcto, y pasa a veces que el escaner lee el del fabricante. La idea es descativar el pitido del escaner cuando lee el codigo de barras y que sea el programa el que de un pitido de aprobación si el código es correcto o un pitido de error cuando sea incorrecto. He intentado usar la función Beep (), pero no la reconoce FiveWin PocketPC.
Buzzer en CE 5.0
Prueba a usar la función PlaySound() que parece que puede servirte: [url:3ragmtqq]http&#58;//msdn&#46;microsoft&#46;com/en-us/library/windows/desktop/dd743680(v=vs&#46;85)&#46;aspx[/url:3ragmtqq]
Buzzer en CE 5.0
Hola, he tenido que retomar este tema de hacer sonar un Scanpal 5100. Antonio, la función PlaySound no sé como incorporarla en mi prg, al ser una función en C necesitaría que me explicaras un poco como puedo usarla en mi programa. Gracias.
Buzzer en CE 5.0
Gabriel, Añade este código a tu PRG principal: [code=fw:2esqu9b6]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#pragma</span> BEGINDUMP<br /><br /><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <hbapi.h><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">&#40;</span> SNDPLAYSOUND <span style="color: #000000;">&#41;</span> <span style="color: #B900B9;">// ( <cSndName>, <nMode> )  --> <lSuccess></span><br /><span style="color: #000000;">&#123;</span><br />   hb_retl<span style="color: #000000;">&#40;</span> sndPlaySound<span style="color: #000000;">&#40;</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> HB_ISNUM<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span> LPSTR <span style="color: #000000;">&#41;</span> hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span>, hb_parc<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>,<br />                        <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> hb_pcount<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> > <span style="color: #000000;">1</span>, hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span>, SND_ASYNC <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>;<br /><span style="color: #000000;">&#125;</span><br /><br /><span style="color: #00D7D7;">#pragma</span> ENDDUMP<br /> </div>[/code:2esqu9b6]
Buzzer en CE 5.0
Prueba asi [code=fw:1ltvkuii]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00D7D7;">#pragma</span> BEGINDUMP<br /><br /><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <hbapi.h><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">&#40;</span> SNDPLAYSOUND <span style="color: #000000;">&#41;</span> <span style="color: #B900B9;">// ( <cSndName>, <nMode> )  --> <lSuccess></span><br /><span style="color: #000000;">&#123;</span><br />   hb_retl<span style="color: #000000;">&#40;</span> sndPlaySound<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> HB_ISNUM<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> ? <span style="color: #000000;">&#40;</span> LPSTR <span style="color: #000000;">&#41;</span> hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> | hb_parc<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>,<br />                        <span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> hb_pcount<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> > <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> ? hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span> | SND_ASYNC <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>;<br /><span style="color: #000000;">&#125;</span><br /><br /><span style="color: #00D7D7;">#pragma</span> ENDDUMP<br /> <br /><br /><br /> </div>[/code:1ltvkuii] O tambien [code=fw:1ltvkuii]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#define</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span>x,y,z<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#40;</span><span style="color: #000000;">&#40;</span>x<span style="color: #000000;">&#41;</span>?<span style="color: #000000;">&#40;</span>y<span style="color: #000000;">&#41;</span>:<span style="color: #000000;"><span style="color: #000000;">&#40;</span>z</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:1ltvkuii]
Buzzer en CE 5.0
Hola, al ejecutar buildce.bat en el siguiente comando : [color=#4040BF:2axvmbv2]%vcdir%\bin\clarm -W3 -c /DARM /DUNICODE /I%hdir%\include /I%fwppc%\include icm.c [/color:2axvmbv2] me da estos warning [color=#4040BF:2axvmbv2]icm.c icm.prg(74) : warning C4013: 'IF' undefined; assuming extern returning int icm.prg(74) : warning C4047: 'function' : 'const unsigned short *' differs in levels of indirection from 'int ' icm.prg(74) : warning C4024: 'sndPlaySoundW' : different types for formal and actual parameter 1 [/color:2axvmbv2] y al final al linkar [color=#4040BF:2axvmbv2]icm.obj : error LNK2019: unresolved external symbol IF referenced in function HB_FUN_SNDPLAYSOUND icm.exe : fatal error LNK1120: 1 unresolved externals[/color:2axvmbv2] No reconoce la función IF (), he copiado la función SNDPLAYSOUND tal cual me la puso Antonio y no encuentro error en la sintaxis.
Buzzer en CE 5.0
Muchas gracias, he usado la clausula #define y ha generado el EXE. Voy a probarlo en el ordenador de mano.
Buzzer en CE 5.0
Gabriel, Se me pasó el quitar el IF() como muy bien ha hecho Cristobal
Buzzer en CE 5.0
Hola de nuevo, no he conseguido nada con la funcion SndPlaySound. He buscado en Internet y parece ser que el Pocket no tiene tarjeta de sonido y solo es posible hacer sonar el Buzzer. Para ello es necesario tener tu propia función y en este Post he encontrado una que parece ser que lo hace. Necesito que me la pudierais traducir para usar en FiveWin. Muchas gracias. [quote:rclxvad7]You can just write a stream interface driver to access some I/O ports. There's a sample using 8253 buzzer, but the I/O ports should depend on your BIOS setting.[/quote:rclxvad7] [code=fw:rclxvad7]<div class="fw" id="{CB}" style="font-family: monospace;"> BOOL MyBeep<span style="color: #000000;">&#40;</span>DWORD dwFreq, DWORD dwDuration<span style="color: #000000;">&#41;</span><br /><span style="color: #000000;">&#123;</span><br />_outp<span style="color: #000000;">&#40;</span>0x43, 0xb6<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Set Buzzer</span><br />_outp<span style="color: #000000;">&#40;</span>0x42, LOBYTE<span style="color: #000000;">&#40;</span>0x1234dc / dwFreq<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Frequency LSB</span><br />_outp<span style="color: #000000;">&#40;</span>0x42, HIBYTE<span style="color: #000000;">&#40;</span>0x1234dc / dwFreq<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Frequency MSB</span><br />_outp<span style="color: #000000;">&#40;</span>0x61, _inp<span style="color: #000000;">&#40;</span>0x61<span style="color: #000000;">&#41;</span> | 0x3<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Start beep</span><br /><span style="color: #0000ff;">Sleep</span><span style="color: #000000;">&#40;</span>dwDuration<span style="color: #000000;">&#41;</span>;<br />_outp<span style="color: #000000;">&#40;</span>0x61, _inp<span style="color: #000000;">&#40;</span>0x61<span style="color: #000000;">&#41;</span> & 0xfc<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// End beep</span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">TRUE</span>;<br /><span style="color: #000000;">&#125;</span> </div>[/code:rclxvad7]
Buzzer en CE 5.0
Gabriel, Salvo que esté equivocado, _outp() e _inp() no están disponibles en aplicaciones de 32 bits. De todas formas aqui tienes la función para Harbour: [code=fw:2ek7p3z6]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">&#40;</span> MYBEEP <span style="color: #000000;">&#41;</span> <span style="color: #B900B9;">// nFreq, nDuration</span><br /><span style="color: #000000;">&#123;</span><br />&nbsp; &nbsp;_outp<span style="color: #000000;">&#40;</span>0x43, 0xb6<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Set Buzzer</span><br />&nbsp; &nbsp;_outp<span style="color: #000000;">&#40;</span>0x42, LOBYTE<span style="color: #000000;">&#40;</span>0x1234dc / hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Frequency LSB</span><br />&nbsp; &nbsp;_outp<span style="color: #000000;">&#40;</span>0x42, HIBYTE<span style="color: #000000;">&#40;</span>0x1234dc / hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Frequency MSB</span><br />&nbsp; &nbsp;_outp<span style="color: #000000;">&#40;</span>0x61, _inp<span style="color: #000000;">&#40;</span>0x61<span style="color: #000000;">&#41;</span> | 0x3<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// Start beep</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">Sleep</span><span style="color: #000000;">&#40;</span> hb_parnl<span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>;<br />&nbsp; &nbsp;_outp<span style="color: #000000;">&#40;</span>0x61, _inp<span style="color: #000000;">&#40;</span>0x61<span style="color: #000000;">&#41;</span> & 0xfc<span style="color: #000000;">&#41;</span>; <span style="color: #B900B9;">// End beep</span><br />&nbsp; &nbsp;hb_retl<span style="color: #000000;">&#40;</span> <span style="color: #00C800;">TRUE</span> <span style="color: #000000;">&#41;</span>;<br /><span style="color: #000000;">&#125;</span> <br />&nbsp;</div>[/code:2ek7p3z6]
Buzzer en CE 5.0
Muchas gracias Antonio, es verdad las funciones _outp() e _inp() no están para 32 bits, he buscado alguna equivalente, pero parece que no se puede acceder directamente a los puertos según he leido. Bueno, creo que no es posible hacer sonar el ScanPal 5100. Un saludo.
Bye-bye Google Code
<!-- m --><a class="postlink" href="http://google-opensource.blogspot.com/2015/03/farewell-to-google-code.html">http://google-opensource.blogspot.com/2 ... -code.html</a><!-- m -->
Bye-bye Google Code
I have to migrate several projects to Bitbucket Thanks for the reminder <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Bye-bye Google Code
You're welcome <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
Bypass window valid statement
Friends,I have a main Window with the following code[code:pg9eyvzo]nScrHeight&#58;=GetSysMetrics&#40;1&#41; // Screen Height nScrWidth &#58;=GetSysMetrics&#40;0&#41; // Screen Width DEFINE WINDOW oWnd FROM 1, 1 TO nScrHeight, nScrWidth MDI ; TITLE "Accounting Software" ; MENU BuildMenu&#40;&#41; ; COLOR "B/W" ACTIVATE WINDOW oWnd MAXIMIZED ; ON INIT Select_Co&#40;&#41;; VALID MsgYesNo&#40; "Do you want to quit this application ?" &#41; [/code:pg9eyvzo] I am calling a function Select_Co() to display a Login Dialog which asks the user for a valid username and password. The dialog also contains a Login Button and Cancel Button. Suppose the user press the Cancel button, then [b:pg9eyvzo]I need to end the application without executing the Valid statement in the Man Window.[/b:pg9eyvzo] My Intention is that if the user press cancel button from the Login Dialog, then End the application at that point itself without executing the VALID MsgYesNo( "Do you want to quit this application ?" ) I am asking this question just to know whether we have some commands to force the End. The other possible work around is to use a variable to hold a logical value to identify whether the user pressed cancel button without a proper Login. And use that variable to decide whether to execute the Valid of oWnd. For eg: [code:pg9eyvzo]ACTIVATE WINDOW oWnd MAXIMIZED; ON INIT Select_Co&#40;&#41;; VALID if&#40;mValidLogin,MsgYesNo&#40; "Do you want to quit this application ?" &#41;,&#46;T&#46;&#41; [/code:pg9eyvzo] I just wanted to know whether other alternatives are availabe or not and that I am doing it in the right way or not. Regards Anser Screen Snapshots Login Screen [url=http&#58;//img529&#46;imageshack&#46;us/my&#46;php?image=loginwindowio6&#46;jpg:pg9eyvzo][img:pg9eyvzo]http&#58;//img529&#46;imageshack&#46;us/img529/3517/loginwindowio6&#46;th&#46;jpg[/img:pg9eyvzo][/url:pg9eyvzo] Main Window Valid screen [url=http&#58;//img214&#46;imageshack&#46;us/my&#46;php?image=exitconfirmationsf2&#46;jpg:pg9eyvzo][img=http://img214.imageshack.us/img214/9291/exitconfirmationsf2.th.jpg][/url:pg9eyvzo] If you notice my Login screen, the size of the text box for user name and password different. I need the text box of both the usname and password to be same. Right now I have used to say and get. The fields variable size of both usrname and password are different. Is there any way to overcome this display problem faced by me. My code for the Login Dialog [code:pg9eyvzo]mUserName&#58;=spac&#40;30&#41; *--- See the variable size it is 30 mPass&#58;=spac&#40;20&#41; *--- Size is only 20 DEFINE DIALOG oDlg TITLE "Login" @01,02 say "Login Name" @02,02 say "Password" @01,06 get mUserName picture "@!" valid !empty&#40;mUserName&#41; @02,06 get mPass picture "@!" valid !empty&#40;mPass&#41; @03,08 BUTTON oBtn PROMPT "Login" ACTION &#123; || mResult&#58;=ValidateLogin&#40;&#41;,; if&#40;mResult,oDlg&#58;End&#40;&#41;,if&#40;nNoOfTries > 2,oWnd&#58;End&#40;&#41;,&#41; &#41; &#125; @03,15 BUTTON "Cancel" ACTION &#123; oDlg&#58;End&#40;&#41;,oWnd&#58;End&#40;&#41;&#125; CANCEL ACTIVATE DIALOG oDlg CENTERED [/code:pg9eyvzo]Right now I am not used with using the resources to design the dialogs and windows. I thought I will try by the coding way and later as I advance in my learning skills I' ll start using the resources and the usage of "redefine".RegardsAnser[/img]
Bypass window valid statement
Here you have a working example. Please notice the use of SIZE in the GETs (can be used for other controls too) and how oWnd:bValid is set to nil:test.prg[code:105ly2o7] #include "FiveWin&#46;ch" function Main&#40;&#41; local oWnd DEFINE WINDOW oWnd ACTIVATE WINDOW oWnd MAXIMIZED ; ON INIT Login&#40; oWnd &#41; ; VALID MsgYesNo&#40; "Do you want to end ?" &#41; return nil function Login&#40; oWnd &#41; local oDlg, mUserName &#58;= Space&#40; 30 &#41;, mPass &#58;= Space&#40; 20 &#41; DEFINE DIALOG oDlg TITLE "Login" @ 01, 02 SAY "Login Name" @ 02, 02 SAY "Password" @ 01&#46;2, 06 GET mUserName PICTURE "@!" VALID ! Empty&#40; mUserName &#41; SIZE 90, 12 @ 02&#46;3, 06 GET mPass PICTURE "@!" VALID ! Empty&#40; mPass &#41; SIZE 90, 12 @ 03, 08 BUTTON oBtn PROMPT "Login" ; ACTION &#40; mResult &#58;= &#46;T&#46;, If&#40; mResult,oDlg&#58;End&#40;&#41;, If&#40; nNoOfTries > 2, &#40; oWnd&#58;bValid &#58;= nil, oWnd&#58;End&#40;&#41; &#41;,&#41; &#41; &#41; @ 03, 15 BUTTON "Cancel" ACTION &#40; oDlg&#58;End&#40;&#41;, oWnd&#58;bValid &#58;= nil, oWnd&#58;End&#40;&#41; &#41; CANCEL ACTIVATE DIALOG oDlg CENTERED return nil [/code:105ly2o7]
Bypass window valid statement
Thankyou Antonio,You gave me exactly what I needed. By the way I forgot to ask in my post on how to use the mask in get for passwords entries.RegardsAnser
Bypass window valid statement
@ 02.3, 06 GET mPass PICTURE "@!" VALID ! Empty( mPass ) SIZE 90, 12 [b:wk19sgnw]PASSWORD[/b:wk19sgnw]
Bypass window valid statement
[quote="Antonio Linares":pynjco9s]@ 02.3, 06 GET mPass PICTURE "@!" VALID ! Empty( mPass ) SIZE 90, 12 [b:pynjco9s]PASSWORD[/b:pynjco9s][/quote:pynjco9s]Thank you Antonio,Just now I got it from TestPass.Prg in Samples tooRegardsAnser
Bypass window valid statement
Antonio,How can I control ESC and Close button in this example. Thanks,[quote="Antonio Linares":c7exvnnb]Here you have a working example. Please notice the use of SIZE in the GETs (can be used for other controls too) and how oWnd:bValid is set to nil: test.prg [code:c7exvnnb] #include "FiveWin&#46;ch" function Main&#40;&#41; local oWnd DEFINE WINDOW oWnd ACTIVATE WINDOW oWnd MAXIMIZED ; ON INIT Login&#40; oWnd &#41; ; VALID MsgYesNo&#40; "Do you want to end ?" &#41; return nil function Login&#40; oWnd &#41; local oDlg, mUserName &#58;= Space&#40; 30 &#41;, mPass &#58;= Space&#40; 20 &#41; DEFINE DIALOG oDlg TITLE "Login" @ 01, 02 SAY "Login Name" @ 02, 02 SAY "Password" @ 01&#46;2, 06 GET mUserName PICTURE "@!" VALID ! Empty&#40; mUserName &#41; SIZE 90, 12 @ 02&#46;3, 06 GET mPass PICTURE "@!" VALID ! Empty&#40; mPass &#41; SIZE 90, 12 @ 03, 08 BUTTON oBtn PROMPT "Login" ; ACTION &#40; mResult &#58;= &#46;T&#46;, If&#40; mResult,oDlg&#58;End&#40;&#41;, If&#40; nNoOfTries > 2, &#40; oWnd&#58;bValid &#58;= nil, oWnd&#58;End&#40;&#41; &#41;,&#41; &#41; &#41; @ 03, 15 BUTTON "Cancel" ACTION &#40; oDlg&#58;End&#40;&#41;, oWnd&#58;bValid &#58;= nil, oWnd&#58;End&#40;&#41; &#41; CANCEL ACTIVATE DIALOG oDlg CENTERED return nil [/code:c7exvnnb][/quote:c7exvnnb]
Bypass window valid statement
Hakan,[code:cwj64q4g]nStyle &#58;=nOR&#40; DS_MODALFRAME, WS_POPUP, WS_CAPTION &#41; // Removes the ? and x from the dialogue title bar DEFINE DIALOG oDlg TITLE "Login" style nStyle [/code:cwj64q4g]RegardsAnser
Bypass window valid statement
Thanks Anser,It removed the ? and x from dialog bar, but ESC key still works.How can i cancel the ESC key?Thanks again.[quote="anserkk":25n4n4v6]Hakan, [code:25n4n4v6]nStyle &#58;=nOR&#40; DS_MODALFRAME, WS_POPUP, WS_CAPTION &#41; // Removes the ? and x from the dialogue title bar DEFINE DIALOG oDlg TITLE "Login" style nStyle [/code:25n4n4v6] Regards Anser[/quote:25n4n4v6]
Bypass window valid statement
Hakan,you may try this:[code:dmd06vjw] ACTIVATE DIALOG oDlg VALID !GETKEYSTATE&#40; VK_ESCAPE &#41; [/code:dmd06vjw]Regards,Detlef
Bypass window valid statement
Full control on ESC and Close:[code:3jr5cz4a] #include "FiveWin&#46;ch" function Main&#40;&#41; local oWnd DEFINE WINDOW oWnd ACTIVATE WINDOW oWnd MAXIMIZED ; ON INIT Login&#40; oWnd &#41; ; VALID MsgYesNo&#40; "Do you want to end ?" &#41; return nil function Login&#40; oWnd &#41; local oDlg, mUserName &#58;= Space&#40; 30 &#41;, mPass &#58;= Space&#40; 20 &#41;, lOk &#58;= &#46;F&#46; DEFINE DIALOG oDlg TITLE "Login" @ 01, 02 SAY "Login Name" @ 02, 02 SAY "Password" @ 01&#46;2, 06 GET mUserName PICTURE "@!" VALID ! Empty&#40; mUserName &#41; SIZE 90, 12 @ 02&#46;3, 06 GET mPass PICTURE "@!" VALID ! Empty&#40; mPass &#41; SIZE 90, 12 PASSWORD @ 03, 08 BUTTON oBtn PROMPT "Login" ; ACTION &#40; lOk &#58;= &#46;T&#46;, oDlg&#58;End&#40;&#41; &#41; @ 03, 15 BUTTON "Cancel" ACTION &#40; lOk &#58;= &#46;F&#46;, oDlg&#58;End&#40;&#41; &#41; CANCEL ACTIVATE DIALOG oDlg CENTERED if ! lOk oWnd&#58;bValid = nil oWnd&#58;End&#40;&#41; endif return nil [/code:3jr5cz4a]
Bypass window valid statement
Thanks Deflet, Antonio,Both solution is worked for me.
Byte Array with Parameter in CApi
Hi, I have a function which would like to call by parameters PRG: NRet: = CBIOS_UPWLogin ("demo\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00") Lib: libcbios.a is available // in cbios.h DWORD WINAPI CBIOS_UPWLogin (BYTE bUPW [0x10]); // The funcion without parameters is ok HB_FUNC (CBIOS_UPWLOGIN) { DWORD dwRet; BYTE bPass [] = "demo\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"; DwRet = CBIOS_UPWLogin (bPass); Hb_retnl ((LONG) dwRet); } How does the C function with parameter transfer look like? Greeting Manfred
Byte Array with Parameter in CApi
[quote="Gross":1fzo69sb]Hi, I have a function which would like to call by parameters PRG: NRet: = CBIOS_UPWLogin ("demo\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00") Lib: libcbios.a is available // in cbios.h DWORD WINAPI CBIOS_UPWLogin (BYTE bUPW [0x10]); // The funcion without parameters is ok HB_FUNC (CBIOS_UPWLOGIN) { DWORD dwRet; BYTE bPass [] = "demo\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"; DwRet = CBIOS_UPWLogin (bPass); Hb_retnl ((LONG) dwRet); } How does the C function with parameter transfer look like? Greeting Manfred[/quote:1fzo69sb] [code=fw:1fzo69sb]<div class="fw" id="{CB}" style="font-family: monospace;">BYTE bPass <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#93;</span> = hb_parc<span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span>;</div>[/code:1fzo69sb] EMG