topic
stringlengths 1
63
| text
stringlengths 1
577k
⌀ |
---|---|
quiero comenzar con el nuevo editor | gracias a todos.
paso mi email |
quiero comenzar con el nuevo editor | Gracias Jose Vicente
Aquí pongo el enlace invitación
<!-- m --><a class="postlink" href="https://join.slack.com/t/fivedit/shared_invite/zt-iysbat0g-Tkhyg89~pffB5J6RNCUGhQ">https://join.slack.com/t/fivedit/shared ... 5J6RNCUGhQ</a><!-- m -->
( Consejo: Borra tu cuenta de correo del post anterior ) |
quiero comenzar con el nuevo editor | consulta. no tiene un importador de configuracion?
ahi estoy en el foro.
gracias. |
quiero darle mas espacio entre linea y linea a TREE | Hola.
Quiero que las lineas de los item esten mas separados. como hago?
[quote:1e0dsihu]+ item 1
|
|
+item 2
[/quote:1e0dsihu]
seria espacio entre "item 1" y "item 2" |
quiero darle mas espacio entre linea y linea a TREE | Si lo muestras con un xbrowse, podes cambiar el alto de la fila con:
[code=fw:2y5ek5gs]<div class="fw" id="{CB}" style="font-family: monospace;">oBrw:<span style="color: #000000;">nRowHeight</span> := nnn</div>[/code:2y5ek5gs] |
quiero darle mas espacio entre linea y linea a TREE | no es un browsrr estimado. |
quiero darle mas espacio entre linea y linea a TREE | Es un TTreeView?
En ese caso con oTree:SetItemHeight( nnn ) |
quiero darle mas espacio entre linea y linea a TREE | ahora si!
gracias |
quiero definir fuentes que esten disponible en toda la app | ola.
tengo varias clases, cada una hace su cometido en la app,
y todas tienen browser.
quier definir "algo" pienso en una clase pero no me estaria funcionando, para definir algunas fuentes y que pueda
utilizarla desde las diferentes clases que tengo.
he hecho esto:
[code=fw:3qp00lvs]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">CLASS</span> TFuentes<br /> <span style="color: #00C800;">DATA</span> oFontEncabezado<br /> <span style="color: #00C800;">DATA</span> oFontCelda<br /><br /> <span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">new</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> CONSTRUCTOR<br /><span style="color: #00C800;">ENDCLASS</span><br /><span style="color: #B900B9;">//------------------------------------------------------------------------------</span><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">new</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TFuentes<br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFontEncabezado</span> <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;">16</span> bold<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFontCelda</span> <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;">16</span><br /><br /> <span style="color: #00C800;">RETURN</span> <span style="color: #000000;">(</span> <span style="color: #00C800;">Self</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//------------------------------------------------------------------------------</span><br /> </div>[/code:3qp00lvs]
pero si la llamo como ser desde mi clase que quiero utilizarla me dice que no la encuentra
[code=fw:3qp00lvs]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">CLASS</span> TApp <span style="color: #0000ff;">FROM</span> TFuentes<br />.....<br /><span style="color: #00C800;">endclass</span><br />....<br /><br />with object ::<span style="color: #000000;">oBrw</span><br /> WITH OBJECT :<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span><br /> :<span style="color: #000000;">cHeader</span> := <span style="color: #ff0000;">"Id"</span><br /> :<span style="color: #000000;">nWidth</span> := <span style="color: #000000;">80</span><br /> :<span style="color: #000000;">nHeadStrAlign</span> := AL_CENTER<br /><br /> :<span style="color: #000000;">oHeaderFont</span> := ::<span style="color: #000000;">oFontEncabezado</span><br /> :<span style="color: #000000;">oDataFont</span> := ::<span style="color: #000000;">oFontCelda</span><br /> END WITH<br /> </div>[/code:3qp00lvs]
cual es el problema? que la fuente no se muestra y si hago esto:
[code=fw:3qp00lvs]<div class="fw" id="{CB}" style="font-family: monospace;">fwdbg ::<span style="color: #000000;">oFontEncabezado</span></div>[/code:3qp00lvs]
no me devuelve nda. ni si quiera una referencia al afuente |
quiero definir fuentes que esten disponible en toda la app | Hola
Me parece que la clase TApp no debería definirse como FROM TFuentes
Yo haría asi:
[code=fw:1x0c3qdc]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">CLASS</span> TApp<br /><br /><span style="color: #00C800;">DATA</span> oFuentes<br />.....<br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TApp<br /><br /> ::<span style="color: #000000;">oFuentes</span> := TFuentes<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />....<br /><br /><br /><span style="color: #B900B9;">// Para el browse:</span><br /><br />with object ::<span style="color: #000000;">oBrw</span><br /><br /> WITH OBJECT :<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span><br /><br /> :<span style="color: #000000;">cHeader</span> := <span style="color: #ff0000;">"Id"</span><br /> :<span style="color: #000000;">nWidth</span> := <span style="color: #000000;">80</span><br /> :<span style="color: #000000;">nHeadStrAlign</span> := AL_CENTER<br /><br /> :<span style="color: #000000;">oHeaderFont</span> := ::<span style="color: #000000;">oFuentes</span>:<span style="color: #000000;">oFontEncabezado</span><br /> :<span style="color: #000000;">oDataFont</span> := ::<span style="color: #000000;">oFuentes</span>:<span style="color: #000000;">oFontCelda</span><br /><br /> END WITH<br /><br /> </div>[/code:1x0c3qdc]
Saludos |
quiero definir fuentes que esten disponible en toda la app | [code=fw:1ys78cfd]<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: #B900B9;">//----CLasse</span><br /><br /><span style="color: #00C800;">CLASS</span> TPublic<br /><br /> <span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> CONSTRUCTOR<br /><br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPublic<br /><br /> <span style="color: #00C800;">Public</span> TFecha, oFont, oFnt, oFont1, oFont2, oFont3<br /><br /> TFecha := Date<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-14</span> BOLD<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFnt <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-12</span> BOLD<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont1 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Calibri"</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;">"Segoe UI Light"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-18</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;">"Segoe UI"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-26</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">Self</span><br /><br /><span style="color: #B900B9;">//-------Seus PRGs - Para Pegar Variaveis publicas</span><br /><span style="color: #B900B9;">// Datos := TPublic():New()</span><br /><br /><span style="color: #B900B9;">// ? TFecha</span><br /> </div>[/code:1ys78cfd]
Regards, saludos. |
quiero definir fuentes que esten disponible en toda la app | [quote="TecniSoftware":2au4q1rw]Hola
Me parece que la clase TApp no debería definirse como FROM TFuentes
Yo haría asi:
[code=fw:2au4q1rw]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">CLASS</span> TApp<br /><br /><span style="color: #00C800;">DATA</span> oFuentes<br />.....<br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TApp<br /><br /> ::<span style="color: #000000;">oFuentes</span> := TFuentes<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />....<br /><br /><br /><span style="color: #B900B9;">// Para el browse:</span><br /><br />with object ::<span style="color: #000000;">oBrw</span><br /><br /> WITH OBJECT :<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span><br /><br /> :<span style="color: #000000;">cHeader</span> := <span style="color: #ff0000;">"Id"</span><br /> :<span style="color: #000000;">nWidth</span> := <span style="color: #000000;">80</span><br /> :<span style="color: #000000;">nHeadStrAlign</span> := AL_CENTER<br /><br /> :<span style="color: #000000;">oHeaderFont</span> := ::<span style="color: #000000;">oFuentes</span>:<span style="color: #000000;">oFontEncabezado</span><br /> :<span style="color: #000000;">oDataFont</span> := ::<span style="color: #000000;">oFuentes</span>:<span style="color: #000000;">oFontCelda</span><br /><br /> END WITH<br /><br /> </div>[/code:2au4q1rw]
Saludos[/quote:2au4q1rw]
Consulto, pero al hacerl FROM... estoy heredando los metodos y datos de TFuentes... o no? |
quiero definir fuentes que esten disponible en toda la app | [quote="karinha":9qfexpjh][code=fw:9qfexpjh]<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: #B900B9;">//----CLasse</span><br /><br /><span style="color: #00C800;">CLASS</span> TPublic<br /><br /> <span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> CONSTRUCTOR<br /><br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPublic<br /><br /> <span style="color: #00C800;">Public</span> TFecha, oFont, oFnt, oFont1, oFont2, oFont3<br /><br /> TFecha := Date<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-14</span> BOLD<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFnt <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-12</span> BOLD<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont1 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Calibri"</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;">"Segoe UI Light"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-18</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;">"Segoe UI"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-26</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">Self</span><br /><br /><span style="color: #B900B9;">//-------Seus PRGs - Para Pegar Variaveis publicas</span><br /><span style="color: #B900B9;">// Datos := TPublic():New()</span><br /><br /><span style="color: #B900B9;">// ? TFecha</span><br /> </div>[/code:9qfexpjh]
Regards, saludos.[/quote:9qfexpjh]
hola pero si defino como DATA en vez de "public" se estaria heredando tambien las data... o no es lo mismo que en "C"? |
quiero definir fuentes que esten disponible en toda la app | Yo lo utilizo asi:
[code=fw:3ehfjlq0]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">class</span> tapp<br /><br /> <span style="color: #00C800;">DATA</span> aWFont <span style="color: #0000ff;">INIT</span> <span style="color: #000000;">{</span><span style="color: #000000;">}</span> <span style="color: #B900B9;">//-- Array de Fonts </span><br />...<br />...<br />...<br /><span style="color: #00C800;">endclass</span><br /> </div>[/code:3ehfjlq0]
en tu programa inicial
[code=fw:3ehfjlq0]<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 />MEMVAR oApp<br /><br /><span style="color: #00C800;">function</span> main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> oApp := TApp<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />..<br />..<br /> IniciarFonts<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />..<br />..<br />..<br />AEval<span style="color: #000000;">(</span> oApp:<span style="color: #000000;">aWFont</span>, <span style="color: #000000;">{</span>|e| IIF<span style="color: #000000;">(</span>e!=<span style="color: #00C800;">Nil</span>, e:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, <span style="color: #00C800;">Nil</span> <span style="color: #000000;">)</span><span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">return</span> .t.<br /><br /><span style="color: #00C800;">Function</span> IniciarFonts<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /><br /> oApp:<span style="color: #000000;">aWFont</span> := ARRAY<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Segoe WP"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-17</span> <span style="color: #B900B9;">// OK</span><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Segoe WP"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-27</span> <span style="color: #B900B9;">// OK</span><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Sagoe UI Light"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-14</span> <span style="color: #B900B9;">// OK</span><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">4</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Segoe UI Light"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-32</span> <span style="color: #B900B9;">// Titulos Gigantes en cualquier Dialogo</span><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">5</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Segoe UI Light"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-20</span> <span style="color: #B900B9;">// OK</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:3ehfjlq0]
y en los programas individuales se utiliza como siempre
[code=fw:3ehfjlq0]<div class="fw" id="{CB}" style="font-family: monospace;"><br />...<br />...<br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">-16</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"N° Contrato"</span> <span style="color: #0000ff;">FONT</span> oApp:<span style="color: #000000;">aWFont</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span><br />...<br />...<br /> </div>[/code:3ehfjlq0]
Saludos |
quiero definir fuentes que esten disponible en toda la app | Hola
Pude resolverlo de esta forma: no entiendo aun porque no se inicializan los objetos automaticamente...
[code=fw:3s27ibb2]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"FiveWin.Ch"</span><br /><br /><span style="color: #00C800;">CLASS</span> TFuentes<br /> <span style="color: #00C800;">data</span> oFont1<br /> <span style="color: #00C800;">data</span> oFont2<br /><br /> <span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> CONSTRUCTOR<br /><br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TFuentes<br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont1</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-14</span> BOLD<br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont2</span> <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Ms Sans Serif"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">00</span>, <span style="color: #000000;">-14</span> <br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #000000;">(</span><span style="color: #00C800;">Self</span><span style="color: #000000;">)</span><br /><br />------------------------------------------------<br /><br /><span style="color: #B900B9;">//despues del FROM la clase que primero tiene que ir es TFuentes, sino no funciona (no lo entiendo)</span><br /><br /><span style="color: #00C800;">class</span> TAPP <span style="color: #0000ff;">FROM</span> TFuentes, T....<br /> .....<br /> <span style="color: #00C800;">method</span> <span style="color: #00C800;">new</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> constructor<br /> ...<br />end <span style="color: #00C800;">class</span><br /><br /><span style="color: #00C800;">method</span> <span style="color: #00C800;">new</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">class</span> TApp<br /> ...<br /> ...<br /> ::<span style="color: #00C800;">Super</span>:<span style="color: #00C800;">new</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #B900B9;">// con esto inicializa TFuentes (no entiendo porque no fuiona si la primer clase despues del FROM no es TFuentes</span><br /> ...<br /><span style="color: #00C800;">return</span> <span style="color: #000000;">(</span><span style="color: #00C800;">self</span><span style="color: #000000;">)</span><br /><br /> </div>[/code:3s27ibb2] |
quiero poner en español el EditSource() (Solucionado) | Hola quiero poner en español los botones del EditSource() en que archivo lo encuentro ya lo busque en xbrowse.prg en xbrowser y no esta <!-- s:shock: --><img src="{SMILIES_PATH}/icon_eek.gif" alt=":shock:" title="Shocked" /><!-- s:shock: -->
Gracias <!-- s:mrgreen: --><img src="{SMILIES_PATH}/icon_mrgreen.gif" alt=":mrgreen:" title="Mr. Green" /><!-- s:mrgreen: -->
Saluditos <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> |
quiero poner en español el EditSource() (Solucionado) | \fwh\source\classes\datarow.prg.
Find
METHOD DlgButtons( oDlg, oPanel, lNavigate, lReadOnly, nGets ) CLASS TDataRow
In this method change the Tooltips from English to Spanish and link the revised program with your application |
quiero poner en español el EditSource() (Solucionado) | Gracias... <!-- s:) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":)" title="Smile" /><!-- s:) -->
Thank you... <!-- s:mrgreen: --><img src="{SMILIES_PATH}/icon_mrgreen.gif" alt=":mrgreen:" title="Mr. Green" /><!-- s:mrgreen: -->
???? ???? ??????? ... <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
Saluditos... <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
???? ????? ????? ?? <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
Best regards <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> |
quiero poner en español el EditSource() (Solucionado) | Nages, why not use fw languague funcions ? |
quiero tomar el valor que almacena MAKETOTALS | hola.
Necesito tomar el valor de MAKETOTALS de un xbrowser para poder utilizarlo,
como lo hago?
gracias. |
quiero tomar el valor que almacena MAKETOTALS | Suponiendo que queres tomar el valor del total de la columna 6
[code=fw:183bvofr]<div class="fw" id="{CB}" style="font-family: monospace;"><br />oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">6</span><span style="color: #000000;">]</span>:<span style="color: #000000;">nTotal</span><br /> </div>[/code:183bvofr] |
quiero tomar el valor que almacena MAKETOTALS | [quote="cmsoft":2y0gjc3p]Suponiendo que queres tomar el valor del total de la columna 6
[code=fw:2y0gjc3p]<div class="fw" id="{CB}" style="font-family: monospace;"><br />oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">6</span><span style="color: #000000;">]</span>:<span style="color: #000000;">nTotal</span><br /> </div>[/code:2y0gjc3p][/quote:2y0gjc3p]
gracias! |
quitar boton | Hola:
Como podria quitar el boton que aparece en la barra de tareas de la ventana principal de la aplicación sin quitar o ocultar esta.
Un saludo
Carlos |
quitar boton | Carlos,
Te refieres a la barra inferior de la pantalla principal de Windows ? |
quitar boton | Hola Antonio
Si me refiero a la barra de tareas de windows la que esta a la derecha del boton de inocio.
en la otra pregunta que he realizado la del PREVIEW cuando cambie en
source\classes\rpreview.prg este archivo el tpreview.prg le tendria que incluir como un fuente más o como incluiria la modificacion, perdona la pregunta si es muy tonta pero me atasco mucho.
Un saludo
Carlos |
quitar boton | Carlos,
Si, una vez modifiques rpreview.prg, lo compilas y lo enlazas como si fuese otro PRG más de tu aplicación |
quitar boton | Gracias Antonio ya lo he echo pero todavia no he dado con el lugar donde pone el menu y la barra de tareas del menu principal yo sigo hasta que de con ello.
Lo del boton no es posible quitarlo.
Un saludo
Carlos |
quitar color a columna xbrowse | Amigos
cuando abro el xbrowse la primera col sale de color celeste
quiero que al dar click a la 2da columna lo pinte de celeste (eso esta resuelto)
pero mi duda es quitarle el color a la primera col?
[code=fw:2bxgdibz]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">XBROWSE</span> oBrw ;<br /> FIELDS ARTICULO->Cod ;<br /> ,ARTICULO->DesG ;<br /> ,Transform<span style="color: #000000;">(</span>ARTICULO->Pv, <span style="color: #ff0000;">"999.9999"</span><span style="color: #000000;">)</span> ;<br /> ,<span style="color: #ff0000;">" "</span> ;<br /> FIELDSIZES <span style="color: #000000;">70</span>, <span style="color: #000000;">250</span>,<span style="color: #000000;">120</span>, <span style="color: #000000;">90</span>, <span style="color: #000000;">10</span> ;<br /> HEADERS OemToAnsi<span style="color: #000000;">(</span><span style="color: #ff0000;">"C¢digo"</span><span style="color: #000000;">)</span> ;<br /> ,OemToAnsi<span style="color: #000000;">(</span><span style="color: #ff0000;">"Descripci¢n"</span><span style="color: #000000;">)</span> ;<br /> ,<span style="color: #ff0000;">"Precio S/."</span> ;<br /> ,<span style="color: #ff0000;">" "</span> ;<br /> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">4001</span> <span style="color: #0000ff;">OF</span> oDlg ;<br /> <span style="color: #0000ff;">UPDATE</span> <br /><br /><br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bLClickHeader</span> := <span style="color: #000000;">{</span>|| ChTag<span style="color: #000000;">(</span><span style="color: #ff0000;">"ARTICULO"</span>, <span style="color: #000000;">1</span>, oBrw<span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">16054371</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span> <span style="color: #B900B9;">//==>al mostrarse el browse sale la 1era col de color celeste en el fondo</span><br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bLClickHeader</span> := <span style="color: #000000;">{</span>|| ChTag<span style="color: #000000;">(</span><span style="color: #ff0000;">"ARTICULO"</span>, <span style="color: #000000;">2</span>, oBrw<span style="color: #000000;">)</span>, oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">16054371</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span> <span style="color: #B900B9;">//hago que la 2da col se pinte de fondo celeste y como seria para quitarle el fondo a la primera col?</span><br /> </div>[/code:2bxgdibz]
Gracias |
quitar color a columna xbrowse | Haber si esto te ayuda, saludos... <!-- s:shock: --><img src="{SMILIES_PATH}/icon_eek.gif" alt=":shock:" title="Shocked" /><!-- s:shock: -->
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=6&t=30514&p=175221&hilit=color+de+columnas#p175221">viewtopic.php?f=6&t=30514&p=175221&hilit=color+de+columnas#p175221</a><!-- l -->
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=6&t=30004&p=170811&hilit=color+de+columnas#p170811">viewtopic.php?f=6&t=30004&p=170811&hilit=color+de+columnas#p170811</a><!-- l -->
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=6&t=29616&p=167335&hilit=color+de+columnas#p167335">viewtopic.php?f=6&t=29616&p=167335&hilit=color+de+columnas#p167335</a><!-- l --> |
quitar color a columna xbrowse | Gracias JoseLuis por responder, pero lo resolvi asi:
[code=fw:xgx2d2wv]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bLClickHeader</span> := <span style="color: #000000;">{</span>|| ChTag<span style="color: #000000;">(</span><span style="color: #ff0000;">"ARTICULO"</span>, <span style="color: #000000;">1</span>, oBrw<span style="color: #000000;">)</span>, oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">16054371</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span>, oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span>CLR_BLACK, CLR_WHITE<span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">}</span><br /><br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">16054371</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span> <span style="color: #B900B9;">// ==> por default pinta de celeste la primera columna</span><br /><br /> oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bLClickHeader</span> := <span style="color: #000000;">{</span>|| ChTag<span style="color: #000000;">(</span><span style="color: #ff0000;">"ARTICULO"</span>, <span style="color: #000000;">2</span>, oBrw<span style="color: #000000;">)</span>, oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">16054371</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span>, oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bClrStd</span> := <span style="color: #000000;">{</span> || <span style="color: #000000;">{</span>CLR_BLACK, CLR_WHITE<span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">}</span><br /><br /> </div>[/code:xgx2d2wv] |
quitar triangulo de la cabecera de xBrowse | Holas,
en las últimas versiones de xbrowse cuando se abre una tabla y esta tiene indices, aparece un triangulo en la cabecera de las columnas, como evito que este triangulo aparezca.
saludos
Marcelo |
quitar triangulo de la cabecera de xBrowse | asi, sin probar ni nada, se me ocurre
[code=fw:2a5o9uoo]<div class="fw" id="{CB}" style="font-family: monospace;"><br />oBrw:<span style="color: #000000;">aSortBmp</span> := <span style="color: #000000;">{</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">}</span><br /> </div>[/code:2a5o9uoo] |
quitar triangulo de la cabecera de xBrowse | Carlos,
funciono, gracias
saludos
Marcelo |
quotation for a Control | Hello.
I would like to request a quotation for a control.
I am interested in a control similar to this: <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=21772&hilit=AUTOGET">viewtopic.php?f=3&t=21772&hilit=AUTOGET</a><!-- l -->
It should work as <!-- m --><a class="postlink" href="http://jqueryui.com/demos/autocomplete/#default">http://jqueryui.com/demos/autocomplete/#default</a><!-- m -->
I may indicate either an Array or the field of a DBF.
Anyone who is interested in developing it please send me a quotation at <!-- e --><a href="mailto:[email protected]">[email protected]</a><!-- e -->
Thank you very much.
Best regards, |
quotation for a Control | U can use AUTOGET CLASS
before create an array from dbf with wich U want for sample :
AAdd( aArray, ALLTRIM(FIELD->CUSTOMER))
HERE RUN OK |
quotation for a Control | What features of the java control are you interested in that are not in the FW control?
I seem to remember that the dropdown list was one of them.
I also notice that the java control lists all items that contain the search string, not just those that start with the search string. Is that also something you want? I can't really see that as being too useful and it will slow down searching considerably.
Regards,
James |
quotation for a Control | Thank you for reply.
Please, go to <!-- m --><a class="postlink" href="http://jqueryui.com/demos/autocomplete/#default">http://jqueryui.com/demos/autocomplete/#default</a><!-- m --> and type Ja
I need the menu to let the user select Java or Javascript. This feature is not included in autoget. |
quotation for a Control | >I need the menu to let the user select Java or Javascript. This feature is not included in autoget.
So you are saying that you want the dropdown list?
I don't know about the autoget class, but in one that I wrote the user could type JA to get Java displayed in the GET. Or, they could continue to type javas to get Javascript displayed in the GET. Is this acceptable? Note that this requires five keystrokes, and the dropdown list method requires only four (j,a, down arrow, down arrow). However, these four keystrokes are actually more difficult since you have to move your hand to the arrow keys.
Regards,
James |
quotation for a Control | [quote:1yfb3kcw] Or, they could continue to type javas to get Javascript displayed in the GET. Is this acceptable[/quote:1yfb3kcw]
This is how Autoget works. But what I need is that Java and Javascript appear into a dropdown and the user could pick up one, like the example. |
quotation for a Control | Theoretically, you should be able to do this with the DROPDOWN style of the Combobox, however, it seems that a number of the control's features are broken or never worked correctly. I am looking into this.
Regards,
James |
quotation for a Control | Hello
i sent you a email with a prototypes... did you received? |
quotation for a Control | Hello.
Yes, that´s what I need.
Two little things:
When I select an Item, GET control must respect total length so I can write more words.
If I type a value not present in the Array (ae Myhouse), a double line is painted under get control.
Also, Mr. Nao told me that it would be included in FW 08 or 09.
Thank you very much. |
quotation for a Control | Daniel,
When using the combobox style DROPDOWN, I find that the Open() method is not working and the var lIncSearch is also not working (no incremental searching).
I am using FWH 10.8 so these may have been fixed since then.
Regards,
James |
quotation for a Control | James
we didn't made change in the class combobox after your version
could you provide a little sample ?
thanks
In the prototype sent to ukservise, i didn't use combobox, was a new class...
apparently Mr Rao is working in same class, i will wait for him, for now i stoped the development |
quotation for a Control | David,
Here is a sample.
James
[code=fw:zqueotl0]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #B900B9;">/*<br />Purpose: Test DROPDOWN style of Combobox<br />Date : 08/11/2011<br />Author : James Bott<br />Note : Using FWH 10.08<br />*/</span><br /><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;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> cItem:=<span style="color: #ff0000;">"Dog "</span><br /> <span style="color: #00C800;">local</span> aItems:=<span style="color: #000000;">{</span><span style="color: #ff0000;">"House"</span>, <span style="color: #ff0000;">"Car"</span>, <span style="color: #ff0000;">"Cat"</span>, <span style="color: #ff0000;">"Dog"</span>, <span style="color: #ff0000;">"Java"</span>, <span style="color: #ff0000;">"Frog"</span>, <span style="color: #ff0000;">"Javascript"</span>, <span style="color: #ff0000;">"wagon"</span><span style="color: #000000;">}</span><br /> <span style="color: #00C800;">local</span> oDlg, oCombo<br /><br /> aItems:= asort<span style="color: #000000;">(</span> aItems <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">Define</span> <span style="color: #0000ff;">dialog</span> oDlg<br /><br /> @ <span style="color: #000000;">1</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">combobox</span> oCombo;<br /> <span style="color: #0000ff;">var</span> cItem ;<br /> <span style="color: #0000ff;">items</span> aItems;<br /> <span style="color: #0000ff;">style</span> CBS_DROPDOWN;<br /> <span style="color: #0000ff;">of</span> oDlg ;<br /> <span style="color: #0000ff;">pixel</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">150</span>,<span style="color: #000000;">200</span>; <br /> <span style="color: #0000ff;">on</span> <span style="color: #00C800;">edit</span> <span style="color: #0000ff;">change</span> <span style="color: #000000;">(</span>oCombo:<span style="color: #000000;">oGet</span>:<span style="color: #000000;">varput</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"Dog "</span><span style="color: #000000;">)</span>, oCombo:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /> oCombo:<span style="color: #000000;">bGotFocus</span>:= <span style="color: #000000;">{</span>|| oCombo:<span style="color: #000000;">open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #B900B9;">// doesn't work</span><br /><br /> oCombo:<span style="color: #000000;">lIncsearch</span>:=.t. <span style="color: #B900B9;">// not working</span><br /><br /> <span style="color: #B900B9;">// This is not working.</span><br /> oCombo:<span style="color: #000000;">open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> oCombo:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">activate</span> <span style="color: #0000ff;">dialog</span> oDlg <span style="color: #0000ff;">on</span> <span style="color: #0000ff;">init</span> <span style="color: #000000;">(</span>oCombo:<span style="color: #000000;">open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">// Open() doesn't work</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">// eof</span><br /> </div>[/code:zqueotl0] |
quotation for a Control | James
about open...
[code=fw:15gm3yg1]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">/*<br />Purpose: Test DROPDOWN style of Combobox<br />Date : 08/11/2011<br />Author : James Bott<br />Note : Using FWH 10.08<br />*/</span><br /><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;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> cItem:=<span style="color: #ff0000;">"Dog "</span><br /> <span style="color: #00C800;">local</span> aItems:=<span style="color: #000000;">{</span><span style="color: #ff0000;">"House"</span>, <span style="color: #ff0000;">"Car"</span>, <span style="color: #ff0000;">"Cat"</span>, <span style="color: #ff0000;">"Dog"</span>, <span style="color: #ff0000;">"Java"</span>, <span style="color: #ff0000;">"Frog"</span>, <span style="color: #ff0000;">"Javascript"</span>, <span style="color: #ff0000;">"wagon"</span><span style="color: #000000;">}</span><br /> <span style="color: #00C800;">local</span> oDlg, oCombo<br /><br /> aItems:= asort<span style="color: #000000;">(</span> aItems <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">Define</span> <span style="color: #0000ff;">dialog</span> oDlg<br /><br /> @ <span style="color: #000000;">1</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">combobox</span> oCombo;<br /> <span style="color: #0000ff;">var</span> cItem ;<br /> <span style="color: #0000ff;">items</span> aItems;<br /> <span style="color: #0000ff;">style</span> CBS_DROPDOWN;<br /> <span style="color: #0000ff;">of</span> oDlg ;<br /> <span style="color: #0000ff;">pixel</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">150</span>,<span style="color: #000000;">200</span>; <br /> <span style="color: #0000ff;">on</span> <span style="color: #00C800;">edit</span> <span style="color: #0000ff;">change</span> <span style="color: #000000;">(</span>oCombo:<span style="color: #000000;">oGet</span>:<span style="color: #000000;">varput</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"Dog "</span><span style="color: #000000;">)</span>, oCombo:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #B900B9;">//oCombo:bGotFocus:= {|| oCombo:open() } // doesn't work</span><br /><br /> oCombo:<span style="color: #000000;">lIncsearch</span>:=.t. <span style="color: #B900B9;">// not working</span><br /><br /> <span style="color: #B900B9;">// This is not working.</span><br /> <span style="color: #B900B9;">//oCombo:open()</span><br /> <span style="color: #B900B9;">//oCombo:refresh()</span><br /> <br /> oDlg:<span style="color: #000000;">bStart</span> = <span style="color: #000000;">{</span>||oCombo:<span style="color: #000000;">open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, oCombo:<span style="color: #000000;">bGotFocus</span>:= <span style="color: #000000;">{</span>|| oCombo:<span style="color: #000000;">open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><br /> <br /> <span style="color: #0000ff;">activate</span> <span style="color: #0000ff;">dialog</span> oDlg <span style="color: #B900B9;">//on init (oCombo:open() ) // Open() doesn't work</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">// eof</span><br /> <br /> </div>[/code:15gm3yg1]
for lIncsearch i'll review the case |
quotation for a Control | David,
> oDlg:bStart = {||oCombo:open(), oCombo:bGotFocus:= {|| oCombo:open() } }
OK, this works but it has the strange side effect of changing the mouse cursor to an hourglass whenever it is over the dialog (while the control is open). Are you seeing the same thing with the newer version?
Regards,
James |
rPreveiw : EMAIL & Excel issues | I've been using a modified, older, rPreview but now could use the new one. However, I have two questions:
1) Email: To send email, rPreview creates an object which then calls the default email program. This is fine if my client has Outlook installed. However, many use online email services, so I have them setup with SMTP services. Can I do a setup for the rPreview email that specifies what email to use ? ( ie. how would they use it with GMail ? )
2) Excel: You can perform an initialization in tReport so an output can be sent to Excel. However, all of my reports are written with the Printer class directly. All of the work and logic is performed in the .PRG with output sent directly to the printer. When I activate the Preview for a report, it lays out perfectly, works with the Word interface, and works with the PDF interface. a) How could I specify bInit within that methodology, and b) What value would I use to start the report where I'm already set in my code ( rather than issuing a gotop( ) ?
Thanks. I know these have been around for awhile, but "if it aint broke, don't fix it" means my own code was working OK ... but this newer version of rPreview would be better. ( Also, I was using an external PDF converter ). |
rPreveiw : EMAIL & Excel issues | Antonio,
I pushed this up in case you missed it
Tim |
rPreveiw : EMAIL & Excel issues | Tim,
1. We are actually using MAPI to send the email:
[code=fw:nurcpheq]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">MAIL</span> oMail ;<br /> <span style="color: #0000ff;">SUBJECT</span> <span style="color: #ff0000;">"Testing..."</span> ;<br /> <span style="color: #0000ff;">TEXT</span> <span style="color: #ff0000;">"Test"</span> ;<br /> <span style="color: #0000ff;">FROM</span> USER ;<br /> RECEIPT<br /><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">MAIL</span> oMail</div>[/code:nurcpheq]
I am afraid that can not be connected with gmail, web outlook, yahoo, etc. There have been several posts about gmail here in the forums. If we find a good working one then we could include it in the preview. |
rPreveiw : EMAIL & Excel issues | Tim,
In the meantime this may help:
[url:gf3p69vy]http://superuser.com/questions/573568/gmail-as-default-windows-mail-program-not-same-as-mailto[/url:gf3p69vy]
Specially this which seems very interesting:
[quote:gf3p69vy]The open-source project Tvhgooglemapi might be a solution. Here is how it is described :
Tvhgooglemapi is a simple tool that pretends to be a real mail client to windows but really only uploads the mail to the drafts folder of gmail and then opens the draft in the default web-browser. For the user this is almost exactly the same as having the gmail web interface as the default mail-client for some windows applications (the only difference being that he has to login twice if he is not already logged in to gmail and doesn't let the tool remember the password.)[/quote:gf3p69vy] |
rPreveiw : EMAIL & Excel issues | Tim,
2. In your PRINT ... ENDPRINT code sections, simply add the PREVIEW clause:
[code=fw:25f6mbwh]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">PRINT</span> oPrn PREVIEW<br /><br /><span style="color: #0000ff;">ENDPRINT</span></div>[/code:25f6mbwh]
So the preview will appear with all its features <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
rPreveiw : EMAIL & Excel issues | Antonio,
I've had email and PDF for a number of years in a revised version of tPreview. It has worked well, and I may modify the current rPreview to do the email using it.
I solved all of my problems by having SMTP or CDO available in the system email setup. Then I simply pass the email to my system which sees how it is configured and sends it that way. I could offer the MAPI interface also.
The other issue we should address is a way to feed a TO address when we create the report. In some cases we would need to fill it in. However, if I'm looking at a document specific to a client ( ie an Invoice or Sales Report ), it would be nice for my customer to have that data filled in when the email comes up.
I still have the question about Excel. Please look at my original post for the details. I have the PREVIEW selection ... that is not the problem. I want to have the ability to export to EXCEL and that requires the bInit codeblock. How would I pass that from the PRINT object ?
Thanks. Your support is always greatly appreciated.
Tim |
rPreveiw : EMAIL & Excel issues | Tim,
The Method ToExcel() is only available for a TReport object as it uses its columns to export it to Excel.
If you could adapt your printer work as a report, then you could export it to Excel, as it would have the required columns. |
rPreveiw : EMAIL & Excel issues | Many of my reports involve categorical sums and thus are not easily handled by tReport. There is also a lot of descriptive formatting. Its not just column stuff.
I actually have many of them with an option to export to Excel. However, its done prior to passing it to rPreview.
I'll work with rPreview and modify it to meet my needs. I'll send you the changes and if you like them you can add them into the distribution.
One change you might make is to grey out the Send To Excel button when it is not a useable option.
Tim |
rPreveiw : EMAIL & Excel issues | Tim,
>
I'll work with rPreview and modify it to meet my needs. I'll send you the changes and if you like them you can add them into the distribution.
>
thanks <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
> One change you might make is to grey out the Send To Excel button when it is not a useable option
Good idea, already implemented and also for the Word button, thanks <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
rPreview PrintersMenu() problem | Hi,
when I click on the printer button in the report preview, change the printer with PrintersMenu(), and then ask to print it does not print.
The problem appeared on the terminal server windows 2008 r2. Tested on Windows 8 without Network and it worked normally.
In the example above change the printer on button of the viewer and see the result. The system will disconnect the printer.
[code=fw:1gtfckta]<div class="fw" id="{CB}" style="font-family: monospace;"><br />GetPrintDC<span style="color: #000000;">(</span> GetActiveWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">// -> Please, change de default printer in this point</span><br /><span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">(</span> PrnGetName<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">// See the new printer selected above</span><br /><span style="color: #00C800;">PRINT</span> oPrn <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"TESTING"</span>+<span style="color: #ff0000;">" ("</span>+ PrnGetName<span style="color: #000000;">(</span><span style="color: #000000;">)</span> +<span style="color: #ff0000;">")"</span> PREVIEW <span style="color: #0000ff;">MODAL</span><br /> <span style="color: #0000ff;">PAGE</span><br /> oPrn:<span style="color: #0000ff;">Say</span><span style="color: #000000;">(</span> <span style="color: #000000;">1</span>, <span style="color: #000000;">1</span>, <span style="color: #ff0000;">"Hello"</span> <span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">ENDPAGE</span><br /><br /><span style="color: #B900B9;">// CHANGE THE PRINTER in the button of the Report Preview</span><br /><br /><span style="color: #0000ff;">ENDPRINT</span><br /><span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">(</span> PrnGetName<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">// See that printer go back to the default in windows</span><br /> </div>[/code:1gtfckta] |
rPreview PrintersMenu() problem | Why the printer selection menu in the preview button shows a printer that is not installed on my Terminal Server user?
[b:22qngm5h]The preview list:[/b:22qngm5h]
CutePDF Writer
Fax
PDF reDirect Pro v2
Argox OS-214tt PPLA
\\OASYS4\Samsung SCX-4200 Series
Enviar para o OpenNote 2007
[b:22qngm5h]Printer that is not installed:[/b:22qngm5h]
CutePDF Writer
Is this the problem? |
rPreview PrintersMenu() problem | Oscar,
When you print from Terminal Server does it use remote printers or local printers ?
If local, then your PDF printer should appear |
rPreview PrintersMenu() problem | The TS prints only to printers configured on the server, even the remote are configured on the server and are printed across it. Do not take local printers to TS. |
rPreview ZOOM problem | FWH 13.09
rPreview zoom has been fine in the past. Now, when selecting the Zoom control, the display goes to the full width of the screen, but does not adjust properly on the vertical scale. Thus the letters are stretched to the point ( on a widescreen monitor ) that they are difficult to read.
Is there an adjustment we can make to the source to resolve this ?
Thanks. |
rPreview ZOOM problem | Tim
You can try?
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=6&t=27598#p154023">viewtopic.php?f=6&t=27598#p154023</a><!-- l --> |
rPreview ZOOM problem | It would appear that solution could involve changing hundreds of separate code lines.
Surely there should be a resolution within the rpreview program to correct whatever changed.
Tim |
rPreview ZOOM problem | Tim
Excuse my English, I use google translate
In version 13.08 these lines were not commented / ** / and now in the current version are discussed
Eliminating these symbols of comment / ** / to me preview works properly
Tim
Disculpe mi ingles, uso translate google
En la version 13.08 estas lineas no estaban comentadas /* */ y ahora en la version actual aparecen comentadas
Eliminando esos simbolos de comentario /* */ a mi me funciona el preview correctamente
CLASS TMetaFile
METHOD Paint
[code=fw:1kyelf1e]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> SetWindowExt<span style="color: #000000;">(</span> ::<span style="color: #000000;">hDC</span>, <span style="color: #000000;">100</span>, <span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">nVRatio</span> == <span style="color: #00C800;">nil</span><br /> ::<span style="color: #000000;">SetCoors</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">endif</span> <br /> SetViewportExt<span style="color: #000000;">(</span> ::<span style="color: #000000;">hDC</span>, <span style="color: #000000;">100</span> * ::<span style="color: #000000;">nXZoom</span>, <span style="color: #000000;">100</span> * <span style="color: #000000;">(</span> ::<span style="color: #000000;">nYZoom</span> / <span style="color: #000000;">2</span> <span style="color: #000000;">)</span> * ::<span style="color: #000000;">nVRatio</span> * ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">nWidth</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> / ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">nHeight</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> nHStep = <span style="color: #000000;">(</span> ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">nWidth</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> * <span style="color: #000000;">(</span> ::<span style="color: #000000;">nXZoom</span> - <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> / <span style="color: #000000;">9.8</span> <br /> nVStep = <span style="color: #000000;">(</span> <span style="color: #000000;">(</span> ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">nWidth</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> * ::<span style="color: #000000;">nXZoom</span> * ::<span style="color: #000000;">nVRatio</span> <span style="color: #000000;">)</span> - ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">nHeight</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> / <span style="color: #000000;">10.3</span><br /> SetViewOrg<span style="color: #000000;">(</span> ::<span style="color: #000000;">hDC</span>, -::<span style="color: #000000;">nXorig</span> * nHStep, -::<span style="color: #000000;">nYorig</span> * nVStep <span style="color: #000000;">)</span><br /> </div>[/code:1kyelf1e] |
rPreview ZOOM problem | Yes, that resolves the problem.
Was there a reason for that change, and will it cause problems elsewhere ?
Thank you. |
rPreview ZOOM problem | Tim,
I have found that on some printers it works much better without those lines.
Does it look very different without those lines there for you ? |
rPreview ZOOM problem | Cristobal,
I found this problem.
That changes in TMETAFIL.PRG resolves the problem completaly.
Thank you. |
rPreview ZOOM problem | Antonio,
Sorry I didn't respond earlier. Yes, it looks very different. With that code in place the zoomed page is almost unreadable. It simply stretches the page horizontally and it becomes quite distorted.
Tim |
rPreview ZOOM problem | I am having the same ZOOM problem with PREVIEW (having just upgraded to FWH13x).
I removed the */ comment lines in the tmetafil.prg as described without any apparent change. Is there something else I need to do to fix this?
Thanks!
on a related question....when using the PDF button on the PREVIEW screen, is there a way to make the folder option default to the last used folder as to where to place the pdf file? |
rPreview ZOOM problem | I just used the tmetafil.prg from FWH 13.08.
At the moment the problem is solved. Everything ok now. |
rPreview ZOOM problem | Thanks...I'll download 13.08 version and hopefully that will fix me too! |
rPreview ZOOM problem | FWH 13.12 (could not find 13.07 version of tmetafil)
Harbour current version as downloaded from FiveTech
I cannot get the ZOOM to work correctly on preview.
When preview comes up, the initial small rendering looks ok. When I select any zoom, they all force the page to stretch wide (virtually unreadable as described in previous posts) and choosing any of the zoom factors has no effect or change in the rendering.
I have also un-commented the section in tmetafil.prg as suggested and that has no effect either.
Help!
G |
rPreview ZOOM problem | Greg,
Send me an e-mail (<!-- e --><a href="mailto:[email protected]">[email protected]</a><!-- e -->) and I reply to you tmetafil.prg of FWH 13.08. |
rPreview ZOOM problem | Michel,
many thanks for your help <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
rPreview ZOOM problem | Michel,
Thank you very much as well! I have emailed you, but in case it doesn't come through, my email is <!-- e --><a href="mailto:[email protected]">[email protected]</a><!-- e -->
Thanks,
Greg |
rPreview ZOOM problem | Antonio . Old Tmetafile +This change solve in my brother printer.
[code=fw:2tloa84y]<div class="fw" id="{CB}" style="font-family: monospace;"><br />.......<br /><br /><span style="color: #00C800;">METHOD</span> PaintMeta<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPreview<br /><br /><span style="color: #00C800;">local</span> aSizes<br /> <br /> .....<br /><br /> <span style="color: #B900B9;">// nAspect := ::oDevice:nHorzSize() / ::oDevice:nVertSize() </span><br /><br /> aSizes:=::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">GetPhySize</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> nAspect:= aSizes<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>/aSizes<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #B900B9;">// changes for Zoom .</span><br /><br /> </div>[/code:2tloa84y] |
rPreview ZOOM problem | tmetafil.prg and printer.prg are modified to resolve these issues. |
rPreview ZOOM problem | Hello,
When it would be available please?.
Thank you. |
rPreview does not close when app closes | Hi.
I noticed that with new rPreview, the main app may close while the preview will stay open (does not close with the app). Although it stays open it becomes .NOT. operable. Any solution?
Thank you,
Reinaldo. |
rPreview does not close when app closes | Reinaldo
Can you post a little sample to show the error?
Thanks |
rPreview does not close when app closes | Hi Reinaldo,
The following code in METHOD Activate() CLASS TPreview is responsible for your pboblem.
[code=fw:1qenl2n9]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00C800;">IF</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span><br /> StopUntil<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /><span style="color: #00C800;">ENDIF</span><br /><br /> </div>[/code:1qenl2n9]
Please check wether ::lExit is assigned .T. or not.
Regards,
- Ramesh Babu P |
rPreview does not close when app closes | Please see
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=20693&p=110112&hilit=rpreview#p110112">viewtopic.php?f=3&t=20693&p=110112&hilit=rpreview#p110112</a><!-- l -->
This issue is not from the new rpreview |
rPreview does not close when app closes | Rao; Hi. Appreciate your efforts. Don't take me wrong -this is not an attack. I don't know what you mean by "is not from the new preview". Once upon a time, it was not a problem. Now it is. Is it from new-little less new-new-newest-newer..... does not matter. It is still an issue. Actually, an unresolved issue.
Daniel; Hola, que tal?. If you really want a self contained small sample, I'll be glad to provide it. But you can reproduce this problem yourself with any fw app. Just open a preview window and then close the main app window. You will see. As Rao implies, it is a documented-unresolved problem. I'm thinking that hardly anybody is using [newer] rpreviews anymore. Could this be the case?
Ramesh; Thank you. I will try removing the clause. But then again, why is it there in the first place?
With kind regards to you all,
Reinaldo. |
rPreview does not close when app closes | This happened to me when using FWH 10.12, Backward rpreview.
Repexcel I used to export to Excel, and since it is impossible for this reason. |
rPreview does not close when app closes | Jose Luis /and all others;
I think that there are better ways to export a treport to Excel. The main caveat with the way fw is doing it, is that you MUST have Excel installed on the computer. Currently I'm able to export Treports to Excel without using ole, thus you don't need to have Excel installed. This opens the door to use freely distributed Open Office or simply allow the user to create an .xls to take somewhere.
Since the "newer" rpreview allows to add buttons with actions, I thought I should make an effort to stop using my own modified rpreview and to come to the main fw rpreview distribution. Perhaps I don't quite understand many things, but I've had to make almost the same changes to the "newer" rpreview. To start with, (1) the word factor overlaps with the buttons (there is already a thread on this subject and it looks ugly), (2) then I find that if the app is themed, new buttons and actions are ignored by this "newer" rpreview, (3) if you close the parent application, rpreview windows stay open and becomes a cpu hog.... So, I've decided to change rpreview again and (1) give it a better looking appearence by implementing a graded tbar with 32 x 32 bitmaps, (2) going back to the way I add custom buttons for custom actions, (3) getting rid of IsAppThemed() everywhere and (4) commenting out the eternal while loop that may cause the window to stay open after the main app has been closed.
The reason I'm sharing this is so that maybe, and if it makes sense, rpreview will have a more stable future.
Here is how I'm adding custom buttons:
[code=fw:i1no5xnc]<div class="fw" id="{CB}" style="font-family: monospace;"><br />*--------------------------------------------------------------------------------------<br /><span style="color: #00C800;">function</span> AddExportBtns<span style="color: #000000;">(</span> oPreview, oBar, oReport <span style="color: #000000;">)</span><br /><span style="color: #00C800;">local</span> aRet<br /><span style="color: #00C800;">Local</span> cpdfName<br /><br /> cPdfName := alltrim<span style="color: #000000;">(</span> GetTempDir<span style="color: #000000;">(</span><span style="color: #000000;">)</span> + ;<br /> AllTrim<span style="color: #000000;">(</span> StrTran<span style="color: #000000;">(</span> StrTran<span style="color: #000000;">(</span> oPreview:<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">cDocument</span>, <span style="color: #ff0000;">"/"</span>, <span style="color: #ff0000;">"-"</span> <span style="color: #000000;">)</span>, <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"_"</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> + <span style="color: #ff0000;">".pdf"</span><br /><br /> aRet := <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #ff0000;">"Excel"</span>, <span style="color: #ff0000;">"Export to Excel"</span>,;<br /> <span style="color: #000000;">{</span>|| oReport:<span style="color: #000000;">SaveAs</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"EXCEL"</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, <span style="color: #ff0000;">"Excel"</span> <span style="color: #000000;">}</span>,;<br /> <span style="color: #000000;">{</span> <span style="color: #ff0000;">"Pdf"</span>, <span style="color: #ff0000;">"Export to Pdf Document"</span>,;<br /> <span style="color: #000000;">{</span> || BuildPdf<span style="color: #000000;">(</span> oPreview:<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">aMeta</span>, cpdfName, .f., .t. <span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, <span style="color: #ff0000;">"Pdf"</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><br /> <br /><span style="color: #00C800;">Return</span> aRet <br /><br /> </div>[/code:i1no5xnc]
Then on my tMReport class that inherits from treport and that is capable of producing a xls file without ole, I do this:
[code=fw:i1no5xnc]<div class="fw" id="{CB}" style="font-family: monospace;">*--------------------------------------------------------------------------------------<br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span> aTitle, aHead, aFoot, aFont, lSummary, cRptFile, ;<br /> cResName, lPrinter, lScreen, cFile, oDevice, ;<br /> cName, cTFmt, cHFmt, cFFmt <span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TMReport<br /><br /> <span style="color: #00C800;">Local</span> uReturn := <span style="color: #00C800;">Super</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> aTitle, aHead, aFoot, aFont, lSummary, cRptFile, ;<br /> cResName, lPrinter, lScreen, cFile, oDevice, ;<br /> cName, cTFmt, cHFmt, cFFmt <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">If</span> Empty<span style="color: #000000;">(</span> uReturn <span style="color: #000000;">)</span> <span style="color: #B900B9;">// Error</span><br /> <span style="color: #00C800;">Return</span> <span style="color: #00C800;">Nil</span><br /> <span style="color: #00C800;">EndIf</span><br /><br /> <span style="color: #B900B9;">//rPrevUserBtns is a new function in rPreview.prg</span><br /> RPrevUserBtns<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> |oPreview, oBar| addExportBtns<span style="color: #000000;">(</span> oPreview, oBar, <span style="color: #00C800;">Self</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> <br /> ::<span style="color: #000000;">bPreview</span> := <span style="color: #000000;">{</span> |oDevice, oRpt| rPreview<span style="color: #000000;">(</span> oDevice, oRpt <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">Self</span><br /><br /> </div>[/code:i1no5xnc]
Finally on rPreview fix buildButtonBar(). Notice it is much simpler:
[code=fw:i1no5xnc]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00C800;">METHOD</span> BuildButtonBar<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPreview<br /><br /> <span style="color: #00C800;">local</span> oThis := <span style="color: #00C800;">Self</span><br /> <span style="color: #00C800;">local</span> oBtn<br /> <span style="color: #00C800;">local</span> oReBar, oBar, oWndMain<br /> <span style="color: #00C800;">local</span> l97Look := ::<span style="color: #000000;">oWndMain</span> != <span style="color: #00C800;">nil</span> .and. ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">oBar</span> != <span style="color: #00C800;">nil</span> .and. ;<br /> Len<span style="color: #000000;">(</span> ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">oBar</span>:<span style="color: #000000;">aControls</span> <span style="color: #000000;">)</span> > <span style="color: #000000;">0</span> .and. ;<br /> ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">oBar</span>:<span style="color: #000000;">aControls</span><span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span>:<span style="color: #000000;">l97Look</span><br /> <span style="color: #00C800;">local</span> aPreviewBtns, aBtn<br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">CURSOR</span> ::<span style="color: #000000;">oHand</span> HAND<br /><br /> <span style="color: #00C800;">if</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span> != <span style="color: #00C800;">nil</span><br /> <span style="color: #00C800;">if</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">oBar</span> != <span style="color: #00C800;">nil</span><br /> oBar = WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">oBar</span><br /> <span style="color: #00C800;">if</span> oBar != <span style="color: #00C800;">nil</span> .and. Upper<span style="color: #000000;">(</span> oBar:<span style="color: #000000;">ClassName</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> == <span style="color: #ff0000;">"TBAR"</span> .and. oBar:<span style="color: #000000;">l2007</span><br /> l2007 = .T.<br /> <span style="color: #00C800;">endif</span><br /> <span style="color: #00C800;">endif</span><br /> <span style="color: #00C800;">endif</span><br /><br /> <span style="color: #00C800;">if</span> !empty<span style="color: #000000;">(</span> bUserBtns <span style="color: #000000;">)</span><br /> aPreviewBtns := Eval<span style="color: #000000;">(</span> bUserBtns, <span style="color: #00C800;">Self</span>, oBar <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">endif</span><br /><br /> oBar := TBar<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> ::<span style="color: #000000;">oWnd</span>, <span style="color: #000000;">50</span>, <span style="color: #000000;">60</span>, .F.,,, .T. <span style="color: #000000;">)</span><br /> <br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Top"</span>,,,,, <span style="color: #000000;">{</span>|| ::<span style="color: #000000;">TopPage</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,,;<br /> <span style="color: #ff0000;">"First Page"</span>, .F.,,,, <span style="color: #ff0000;">"First"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /> <br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Previous"</span>,,,,, <span style="color: #000000;">{</span> || ::<span style="color: #000000;">PrevPage</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,,;<br /> <span style="color: #ff0000;">"Prev Page"</span>, .F.,,,, <span style="color: #ff0000;">"Prev"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /><br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Next"</span>,,,,, <span style="color: #000000;">{</span>|| ::<span style="color: #000000;">NextPage</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><span style="color: #000000;">}</span>, .F., oBar, .F.,,;<br /> <span style="color: #ff0000;">"Next Page"</span>, .F.,,,, <span style="color: #ff0000;">"Next"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /> <br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Bottom"</span>,,,,, <span style="color: #000000;">{</span>|| ::<span style="color: #000000;">BottomPage</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,,;<br /> <span style="color: #ff0000;">"Last Page"</span>, .F.,,,, <span style="color: #ff0000;">"Last"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /><br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Zoom"</span>,,,,, <span style="color: #000000;">{</span>|| ::<span style="color: #000000;">zoom</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .T., oBar, .F.,, ;<br /> <span style="color: #ff0000;">"Zoom"</span>, .F.,,,, <span style="color: #ff0000;">"Zoom"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /><br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Two_Pages"</span>,,,,, <span style="color: #000000;">{</span>||::<span style="color: #000000;">TwoPages</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,,;<br /> <span style="color: #ff0000;">"View two pages side by side"</span>, .F.,,,,<span style="color: #ff0000;">"Two Pages"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /> <br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Printer"</span>,,,,, <span style="color: #000000;">{</span>|| ::<span style="color: #000000;">PrintPage</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,, ;<br /> <span style="color: #ff0000;">"Print"</span>, .F.,,,, <span style="color: #ff0000;">"Print"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> aPreviewBtns != <span style="color: #00C800;">Nil</span> .and. valtype<span style="color: #000000;">(</span> aPreviewBtns <span style="color: #000000;">)</span> = <span style="color: #ff0000;">"A"</span> .and. ;<br /> len<span style="color: #000000;">(</span> aPreviewBtns <span style="color: #000000;">)</span> > <span style="color: #000000;">0</span><br /><br /> <span style="color: #00C800;">FOR</span> EACH aBtn IN aPreviewBtns<br /> TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> aBtn<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span>,,,,, aBtn<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span>, .F., oBar, .F.,, ;<br /> aBtn<span style="color: #000000;">[</span> <span style="color: #000000;">2</span> <span style="color: #000000;">]</span>, .F.,,,, aBtn<span style="color: #000000;">[</span> <span style="color: #000000;">4</span> <span style="color: #000000;">]</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">NEXT</span><br /><br /> <span style="color: #00C800;">endif</span><br /><br /> oBtn := TBtnBmp<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">NewBar</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"Exit"</span>,,,,, <span style="color: #000000;">{</span>|| oThis:<span style="color: #000000;">oWnd</span>:<span style="color: #000000;">end</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, .F., oBar, .F.,, ;<br /> <span style="color: #ff0000;">"Exit"</span>, .F.,,,, <span style="color: #ff0000;">"Exit"</span>,,,,,,,,, .F. <span style="color: #000000;">)</span><br /><br /> @ <span style="color: #000000;">7</span>, oBtn:<span style="color: #000000;">nRight</span> + <span style="color: #000000;">5</span> <span style="color: #0000ff;">SAY</span> ::<span style="color: #000000;">oSay</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Factor:"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">45</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont</span><br /> ::<span style="color: #000000;">oSay</span>:<span style="color: #000000;">lTransparent</span> = .T.<br /><br /> @ <span style="color: #000000;">3</span>, oBtn:<span style="color: #000000;">nRight</span> + <span style="color: #000000;">50</span> <span style="color: #0000ff;">COMBOBOX</span> ::<span style="color: #000000;">oFactor</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nZFactor</span> ;<br /> <span style="color: #0000ff;">ITEMS</span> <span style="color: #000000;">{</span> <span style="color: #ff0000;">"1"</span>, <span style="color: #ff0000;">"2"</span>, <span style="color: #ff0000;">"3"</span>, <span style="color: #ff0000;">"4"</span>, <span style="color: #ff0000;">"5"</span>, <span style="color: #ff0000;">"6"</span>, <span style="color: #ff0000;">"7"</span>, <span style="color: #ff0000;">"8"</span>, <span style="color: #ff0000;">"9"</span> <span style="color: #000000;">}</span> ;<br /> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">35</span>,<span style="color: #000000;">200</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> oThis:<span style="color: #000000;">SetFactor</span><span style="color: #000000;">(</span> oThis:<span style="color: #000000;">nZFactor</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> Len<span style="color: #000000;">(</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">aMeta</span> <span style="color: #000000;">)</span> > <span style="color: #000000;">1</span><br /> @ <span style="color: #000000;">7</span>, oBtn:<span style="color: #000000;">nRight</span> + <span style="color: #000000;">95</span> ;<br /> <span style="color: #0000ff;">SAY</span> ::<span style="color: #000000;">oPage</span> <span style="color: #0000ff;">PROMPT</span> TXT_PAGENUM + LTrim<span style="color: #000000;">(</span> Str<span style="color: #000000;">(</span> ::<span style="color: #000000;">nPage</span>, <span style="color: #000000;">4</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> + <span style="color: #ff0000;">" / "</span> + ;<br /> LTrim<span style="color: #000000;">(</span> Str<span style="color: #000000;">(</span> Len<span style="color: #000000;">(</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">aMeta</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">180</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont</span><br /> <span style="color: #00C800;">else</span><br /> @ <span style="color: #000000;">7</span>, oBtn:<span style="color: #000000;">nRight</span> + <span style="color: #000000;">95</span> ;<br /> <span style="color: #0000ff;">SAY</span> ::<span style="color: #000000;">oPage</span> <span style="color: #0000ff;">PROMPT</span> TXT_PAGENUM + LTrim<span style="color: #000000;">(</span> Str<span style="color: #000000;">(</span> ::<span style="color: #000000;">nPage</span>, <span style="color: #000000;">4</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">180</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oBar <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont</span><br /> <span style="color: #00C800;">endif</span><br /> <br /> ::<span style="color: #000000;">oPage</span>:<span style="color: #000000;">lTransparent</span> = .T.<br /><br /><span style="color: #B900B9;">// AEval( oBar:aControls, { | o | o:oCursor := ::oHand } )</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:i1no5xnc]
Regards,
Reinaldo. |
rPreview does not close when app closes | ... and hi again;
I need help with one issue, though. Now I find that I can't just comment out the line with the StopUntil( { || ::lExit } ). Otherwise, my tReport object is destroyed and thus make it un-exportable to Excel.
Maybe someone has a better solution?
There is the code I refer to:
[code=fw:fga7px7m]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">METHOD</span> <span style="color: #0000ff;">Activate</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPreview<br /><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> ::<span style="color: #000000;">oWnd</span> <span style="color: #0000ff;">MAXIMIZED</span> ;<br /> <span style="color: #0000ff;">ON</span> RESIZE ::<span style="color: #000000;">PaintMeta</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_UP <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_DOWN <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGEUP ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_UP, GO_PAGE<span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGEDOWN ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_DOWN, GO_PAGE<span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">LEFT</span> ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_LEFT <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">RIGHT</span> ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_RIGHT <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGELEFT ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_LEFT, GO_PAGE <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGERIGHT ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_RIGHT, GO_PAGE <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> ::<span style="color: #000000;">oWnd</span>:<span style="color: #000000;">oIcon</span> := <span style="color: #00C800;">nil</span> ,;<br /> ::<span style="color: #000000;">oFont</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oMeta1</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oMeta2</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oHand</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oWnd</span> := <span style="color: #00C800;">nil</span> ,;<br /> ::<span style="color: #000000;">lExit</span> := .T. ,;<br /> .T. <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span><br /> StopUntil<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">//<------ Look here.</span><br /> <span style="color: #00C800;">endif</span><br /><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:fga7px7m]
Thank you,
Reinaldo. |
rPreview does not close when app closes | Reinaldo,
You could try, when defining the report, something like this:
wndMain():bValid := {|| oRpt:lEnd := .t., .t.}
This should end the preview when the main window is closed.
Regards,
James |
rPreview does not close when app closes | Reinaldo
Try this way
open /source/function/msgrun.prg
change in function StopUntil()
[code=fw:26nqgxfn]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">DO</span> <span style="color: #00C800;">WHILE</span> !Eval<span style="color: #000000;">(</span> bBlock <span style="color: #000000;">)</span> .and. WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span> != <span style="color: #00C800;">NIL</span> .and. IsWindow<span style="color: #000000;">(</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span></div>[/code:26nqgxfn] |
rPreview does not close when app closes | Reinaldo
forget my last post
is more easy change window class
try changing this "IF"
[code=fw:3gi3i8w0]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">hWnd</span> != <span style="color: #000000;">0</span> .and. GetWndApp<span style="color: #000000;">(</span><span style="color: #000000;">)</span> == ::<span style="color: #000000;">hWnd</span><br /> PostQuitMessage<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /> Sysrefresh<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> QUIT<br /> <span style="color: #00C800;">endif</span><br /> </div>[/code:3gi3i8w0] |
rPreview does not close when app closes | [quote="James Bott":2tv3x2rr]Reinaldo,
You could try, when defining the report, something like this:
wndMain():bValid := {|| oRpt:lEnd := .t., .t.}
This should end the preview when the main window is closed.
Regards,
James[/quote:2tv3x2rr]
Adopting Mr. James suggestion, the METHOD Activate() of TPreview class can be revised as:
[code=fw:2tv3x2rr]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">METHOD</span> <span style="color: #0000ff;">Activate</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> TPreview<br /><br /> <span style="color: #00C800;">local</span> bValidMain := <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> ::<span style="color: #000000;">oWndMain</span> == <span style="color: #00C800;">nil</span>, <span style="color: #00C800;">nil</span>, ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">bValid</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> ::<span style="color: #000000;">oWnd</span> <span style="color: #0000ff;">MAXIMIZED</span> ;<br /> <span style="color: #0000ff;">ON</span> RESIZE ::<span style="color: #000000;">PaintMeta</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_UP <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_DOWN <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGEUP ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_UP, GO_PAGE<span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGEDOWN ::<span style="color: #0000ff;">VScroll</span><span style="color: #000000;">(</span> GO_DOWN, GO_PAGE<span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">LEFT</span> ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_LEFT <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">RIGHT</span> ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_RIGHT <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGELEFT ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_LEFT, GO_PAGE <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">ON</span> PAGERIGHT ::<span style="color: #0000ff;">HScroll</span><span style="color: #000000;">(</span> GO_RIGHT, GO_PAGE <span style="color: #000000;">)</span> ;<br /> <span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> ::<span style="color: #000000;">oWnd</span>:<span style="color: #000000;">oIcon</span> := <span style="color: #00C800;">nil</span> ,;<br /> ::<span style="color: #000000;">oFont</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oMeta1</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oMeta2</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> ::<span style="color: #000000;">oHand</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> ,;<br /> <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> ::<span style="color: #000000;">oWndMain</span> == <span style="color: #00C800;">nil</span>,, ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">bValid</span> := bValidMain <span style="color: #000000;">)</span>,;<br /> ::<span style="color: #000000;">oWnd</span> := <span style="color: #00C800;">nil</span> ,;<br /> <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> IsAppThemed<span style="color: #000000;">(</span><span style="color: #000000;">)</span> .and. ! l2007, ::<span style="color: #000000;">oImageList</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>,<span style="color: #000000;">)</span>,;<br /> ::<span style="color: #000000;">lExit</span> := .T. ,;<br /> .T. <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">oWndMain</span> != <span style="color: #00C800;">nil</span><br /> <span style="color: #00C800;">if</span> bValidMain == <span style="color: #00C800;">nil</span><br /> ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">bValid</span> := <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> := .t. <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">else</span><br /> ::<span style="color: #000000;">oWndMain</span>:<span style="color: #000000;">bValid</span> := <span style="color: #000000;">{</span> || <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> Eval<span style="color: #000000;">(</span> bValidMain <span style="color: #000000;">)</span>, ::<span style="color: #000000;">lExit</span> := .t., .f. <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">endif</span><br /> <span style="color: #00C800;">endif</span><br /><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span><br /> StopUntil<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">endif</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /> </div>[/code:2tv3x2rr]
This seems to be working well.
Can this be tested and feedback provided? |
rPreview does not close when app closes | [quote="James Bott":2pzwjqi6]wndMain():bValid := {|| oRpt:lEnd := .t., .t.}[/quote:2pzwjqi6]
The last .t. is redundant. This is equivalent:
[code=fw:2pzwjqi6]<div class="fw" id="{CB}" style="font-family: monospace;">wndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">bValid</span> := <span style="color: #000000;">{</span>|| oRpt:<span style="color: #000000;">lEnd</span> := .t.<span style="color: #000000;">}</span></div>[/code:2pzwjqi6]
EMG |
rPreview does not close when app closes | Hi and thank you everyone. This is good brainstorming.
I think the following code incorporates from all of your ideas. It seems to do the trick. Please advise on your opinion:
Change Method Activate() on rPreview to:
[code=fw:fsuqnql3]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span><br /> StopUntil<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> .or. WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span> == <span style="color: #00C800;">Nil</span> .or. !IsWindow<span style="color: #000000;">(</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">endif</span><br /><br /> </div>[/code:fsuqnql3]
This closes all the open rpreview windows when the main app is closed. Am I missing/forgetting/ommiting something?
Reinaldo. |
rPreview does not close when app closes | José Luis;
I wish to talk more about repexcel. I`m starting a new thread on the Spanish forum. Please look for it. Thank you.
Reinaldo. |
rPreview does not close when app closes | [quote="reinaldocrespo":3b40bhrf]Hi and thank you everyone. This is good brainstorming.
I think the following code incorporates from all of your ideas. It seems to do the trick. Please advise on your opinion:
Change Method Activate() on rPreview to:
[code=fw:3b40bhrf]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> <span style="color: #00C800;">if</span> ::<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span><br /> StopUntil<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> || ::<span style="color: #000000;">lExit</span> .or. WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span> == <span style="color: #00C800;">Nil</span> .or. !IsWindow<span style="color: #000000;">(</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">endif</span><br /><br /> </div>[/code:3b40bhrf]
This closes all the open rpreview windows when the main app is closed. Am I missing/forgetting/ommiting something?
Reinaldo.[/quote:3b40bhrf]
This has the side effect of the preview window going behind the dialog where there is no wndMain() and the program is started with a dialog.
Test program:
[code=fw:3b40bhrf]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivewin.ch"</span><br />procedure main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">xbrowse</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"<span style="color: #000000;">\f</span>wh<span style="color: #000000;">\s</span>amples<span style="color: #000000;">\c</span>ustomer.dbf"</span> <span style="color: #000000;">)</span><br /><span style="color: #00C800;">return</span></div>[/code:3b40bhrf]
Before finalizing a modification to a program like RPreview, we need to test the code in all these cases:
1. MDI application
1.1 From MDICHILD (a) Modal and (b) Nonmodal
1.2 From a Dialog inside the app (a) Modal and (b) Nonmodal
2. Normal window
2.1 From Window (a) Modal and (b) Nonmodal
2.2 From a Dialog inside the app (a) Modal and (b) Nonmodal
3. App starting with a Dialog
3.1 From main dialog (a) Modal and (b) Nonmodal
3.2 From a subdialog (a) Modal and (b) Nonmodal
We also need to test any processes initiated by any button of the preview window in all the above cases. |
radio - transparent | Is it possible to paint the radio control transparent?
I use SAY with adjust. I feel that the descender are cut off.
Best regards,
Otto
[img:16klkmxa]http://www.atzwanger-software.com/fw/transp.jpg[/img:16klkmxa] |
radio - transparent | I have the same problem , I make a radio with 5 items on tpanel ... |
radio button | Hola quisiera saber si se puede deshabilitar un radio button de un grupo
[code=fw:asft5esg]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">RADIO</span> oRadioButton <span style="color: #0000ff;">VAR</span> nOrden <span style="color: #0000ff;">id</span> <span style="color: #000000;">108</span>, <span style="color: #000000;">107</span>,<span style="color: #000000;">112</span>,<span style="color: #000000;">113</span>;<br /> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> Orden<span style="color: #000000;">(</span> nOrden, oLbx, oNsto, .T., <span style="color: #ff0000;">"3"</span> <span style="color: #000000;">)</span> <br /> </div>[/code:asft5esg]
En el ejemplo por ejemplo el id 112 que no aparezca o en su defecto inutilizarlo
Muchas gracias |
radio button | Intenta asi:
[code=fw:n5t24gxz]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> oDlg:<span style="color: #000000;">aControls</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> Ó<br /><br /> oRadio:<span style="color: #000000;">aItems</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> </div>[/code:n5t24gxz]
Saludos. |
radio button | Gracias João funcionó perfecto
[code=fw:i62jhw38]<div class="fw" id="{CB}" style="font-family: monospace;"> oRadio:<span style="color: #000000;">aItems</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span>:<span style="color: #000000;">Disable</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span></div>[/code:i62jhw38]
Luis |
radio button en recursos | Hola.
Uso PelesC .
pero no puedo desagrupar varios radio button.
coloque 8 seguidos y ahora quiero que se separen en dos grupos y no se como hacerlo.
desde codigo los separo en las definiciones, pero al momento de ejecutar la aplicacion
si hago click en el primero del primer grupo y luego en el ultimo del segundo grupo el del
primer grupo se deselecciona.
[code=fw:g5bjhbbj]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #B900B9;">// grupo 1</span><br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">radio</span> ::<span style="color: #000000;">oGet</span><span style="color: #000000;">[</span> <span style="color: #000000;">20</span> <span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">vGet</span><span style="color: #000000;">[</span> <span style="color: #000000;">20</span> <span style="color: #000000;">]</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">123</span>, <span style="color: #000000;">124</span>, <span style="color: #000000;">125</span>, <span style="color: #000000;">126</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br /> <span style="color: #B900B9;">// grupo 2</span><br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">radio</span> ::<span style="color: #000000;">oGet</span><span style="color: #000000;">[</span> <span style="color: #000000;">21</span> <span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">vGet</span><span style="color: #000000;">[</span> <span style="color: #000000;">21</span> <span style="color: #000000;">]</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">127</span>, <span style="color: #000000;">128</span>, <span style="color: #000000;">129</span> <span style="color: #0000ff;">OF</span> oDlg<br /> </div>[/code:g5bjhbbj]
gracias. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.