topic stringlengths 1 63 | text stringlengths 1 577k ⌀ |
|---|---|
google and insecure applications | Dear Friends:
If I remember correctly, as of Jun/2022, google will not allow its use for
sending emails to insecure applications.
How we will solve this problem?, any sugestion ?
Regards |
google and insecure applications | Thanks Dutch,
I will try it.
Regards |
google image download | Guys, good morning
Is there a way to download an image from the Internet, like this?
<!-- m --><a class="postlink" href="https://www.google.com/search?q=7891114029734+JPG">https://www.google.com/search?q=7891114029734+JPG</a><!-- m -->
or like this
<!-- m --><a class="postlink" href="https://www.google.com/search?q=KEY+PHILLIPS+1/8X5+JPG">https://www.google.com/search?q=KEY+PHILLIPS+1/8X5+JPG</a><!-- m -->
Then do the Dowload, or something like that |
google image download | If you have a URL of an image like this:
<!-- m --><a class="postlink" href="https://www.jesmondfruitbarn.com.au/wp-content/uploads/2016/10/Jesmond-Fruit-Barn-Oranges.jpg">https://www.jesmondfruitbarn.com.au/wp- ... ranges.jpg</a><!-- m -->
( click and see )
We can download the image like this
[code=fw:27wpga8e]<div class="fw" id="{CB}" style="font-family: monospace;">cUrl := <span style="color: #ff0000;">"https://www.jesmondfruitbarn.com.au/wp-content/uploads/2016/10/Jesmond-Fruit-Barn-Oranges.jpg"</span><br />MEMOWRIT<span style="color: #000000;">(</span> <span style="color: #ff0000;">"orages.jpg"</span>, WebPageContents<span style="color: #000000;">(</span> cUrl <span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><span style="color: #B900B9;">// test </span><br />XImage<span style="color: #000000;">(</span> <span style="color: #ff0000;">"oranges.jpg"</span> <span style="color: #000000;">)</span></div>[/code:27wpga8e] |
google meet | Hola alguien ha intentado utilizar google meet. ( es bastante sencillo ) .
El problema es que cuando quiero capacitar sobre la aplicación que desarrolle con FWH 17.04, usando mysql 5.7. (Ventanas MDI ).
Las ventanas e iconos que tienen en la barra de tareas. No se alcanzan a visualizar, es como que esta en constante refresco de la ventana.
Agradezco, vuestra atención . |
google meet | Si pones alguna imagen ( gif ) o código que poder probar, podremos ayudarte mejor. |
google new language like c c++ : go | here: <!-- m --><a class="postlink" href="http://golang.org/">http://golang.org/</a><!-- m --> |
google new language like c c++ : go | [url:csluxwzk]http://mashable.com/2009/11/13/google-go/[/url:csluxwzk] |
goosfancito ? | Disculpa, a lo mejor resolviste la edición de un campo memo en twbrowse
si es asi porfa me podrías ayudar o si alguien del foro sabe se lo agradecere
Saludos
Oscar |
gpf error strange | I want create a simply dialog with gradientbrush and group control and a bitmap over it
it make a strange gpf
I use xp professional sp3
[code=fw:1uu0lq3r]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"FiveWin.ch"</span><br /><br /><span style="color: #00C800;">Function</span> test<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">Local</span> oDlg,oGroup,oBmp1<br /><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">From</span> <span style="color: #000000;">10</span>, <span style="color: #000000;">4</span> <span style="color: #0000ff;">to</span> <span style="color: #000000;">28</span>,<span style="color: #000000;">70</span> <span style="color: #0000ff;">TiTle</span> <span style="color: #ff0000;">"test"</span><br /><br /> @ <span style="color: #000000;">0</span>,<span style="color: #000000;">0.7</span> GROUP oGroup <span style="color: #0000ff;">TO</span> <span style="color: #000000;">3.8</span>,<span style="color: #000000;">30.5</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"test of the test"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">COLOR</span> CLR_YELLOW, CLR_BLUE<br /> oGroup:<span style="color: #000000;">ltransparent</span>:=.T.<br /><br /> @ <span style="color: #000000;">1</span>,<span style="color: #000000;">28</span> BITMAP oBmp1 FILENAME <span style="color: #ff0000;">"OmbrG.BMP"</span> NOBORDER <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>,<span style="color: #000000;">50</span><br /> oBmp1:<span style="color: #000000;">ltransparent</span>:=.T.<br /><br /><span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> GradientBrush<span style="color: #000000;">(</span> oDlg, <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.4</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">75</span>, <span style="color: #000000;">144</span>, <span style="color: #000000;">223</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">41</span>, <span style="color: #000000;">85</span>, <span style="color: #000000;">145</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span>,;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">0.6</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">24</span>, <span style="color: #000000;">61</span>, <span style="color: #000000;">118</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">50</span>, <span style="color: #000000;">95</span>, <span style="color: #000000;">158</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><br /><span style="color: #00C800;">function</span> GradientBrush<span style="color: #000000;">(</span> oDlg, aColors <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> hDC, hBmp, hBmpOld<br /> <br /> <span style="color: #00C800;">if</span> Empty<span style="color: #000000;">(</span> oDlg:<span style="color: #000000;">oBrush</span>:<span style="color: #000000;">hBitmap</span> <span style="color: #000000;">)</span><br /> hDC = CreateCompatibleDC<span style="color: #000000;">(</span> oDlg:<span style="color: #000000;">GetDC</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> hBmp = CreateCompatibleBitMap<span style="color: #000000;">(</span> oDlg:<span style="color: #000000;">hDC</span>, oDlg:<span style="color: #000000;">nWidth</span>, oDlg:<span style="color: #000000;">nHeight</span> <span style="color: #000000;">)</span><br /> hBmpOld = SelectObject<span style="color: #000000;">(</span> hDC, hBmp <span style="color: #000000;">)</span><br /> GradientFill<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, oDlg:<span style="color: #000000;">nHeight</span>, oDlg:<span style="color: #000000;">nWidth</span>, aColors <span style="color: #000000;">)</span><br /> oDlg:<span style="color: #000000;">oBrush</span>:<span style="color: #000000;">hBitmap</span> = hBmp<br /> oDlg:<span style="color: #000000;">oBrush</span>:<span style="color: #000000;">hBrush</span> = CreatePatternBrush<span style="color: #000000;">(</span> hBmp <span style="color: #000000;">)</span> <br /> SelectObject<span style="color: #000000;">(</span> hDC, hBmpOld <span style="color: #000000;">)</span><br /> oDlg:<span style="color: #000000;">ReleaseDC</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 /> DLL32 <span style="color: #00C800;">FUNCTION</span> CreateCompatibleBitmap<span style="color: #000000;">(</span> hDC AS LONG, nWidth AS LONG, nHeight AS LONG <span style="color: #000000;">)</span> AS LONG ;<br /> PASCAL <span style="color: #0000ff;">FROM</span> <span style="color: #ff0000;">"CreateCompatibleBitmap"</span> LIB <span style="color: #ff0000;">"gdi32.dll"</span></div>[/code:1uu0lq3r] |
gpf error strange | Hello Silvio,
what You need works fine, but my code is different.
[img:3rd4k9y4]http://www.pflegeplus.com/pictures/brush10.jpg[/img:3rd4k9y4]
[code=fw:3rd4k9y4]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">// ---------------------------</span><br /><br /><span style="color: #00C800;">FUNCTION</span> PRICE_DAYS<span style="color: #000000;">(</span>oWnd<span style="color: #000000;">)</span><br /><span style="color: #00C800;">LOCAL</span> oBtn1, oBtn2, oGET, oGET1, oGET2, oGET3, oGroup, oBmp1<br /><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">300</span>, <span style="color: #000000;">270</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Price Test"</span> TRANSPARENT<br /><br />@ <span style="color: #000000;">2.6</span>, <span style="color: #000000;">1.5</span> GROUP oGroup <span style="color: #0000ff;">TO</span> <span style="color: #000000;">6.5</span>, <span style="color: #000000;">20</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Calculation"</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">COLOR</span> CLR_YELLOW, CLR_BLUE<br />oGroup:<span style="color: #000000;">ltransparent</span>:=.T.<br /><br />@ <span style="color: #000000;">3.2</span>, <span style="color: #000000;">3</span> <span style="color: #0000ff;">SAY</span> oSay <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Price = .T. only used for Price-calculation"</span><br /><br />@ <span style="color: #000000;">4</span>, <span style="color: #000000;">5</span> <span style="color: #0000ff;">SAY</span> oSay <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Start"</span><br />@ <span style="color: #000000;">4</span>, <span style="color: #000000;">13</span> <span style="color: #0000ff;">SAY</span> oSay <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"End"</span><br />@ <span style="color: #000000;">4</span>, <span style="color: #000000;">19</span> <span style="color: #0000ff;">SAY</span> oSay <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Price ?"</span><br /><br />@ <span style="color: #000000;">5.5</span>, <span style="color: #000000;">2</span> <span style="color: #0000ff;">GET</span> oGet1 <span style="color: #0000ff;">VAR</span> dDAY1 <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">40</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"##.##.####"</span><br />@ <span style="color: #000000;">5.5</span>, <span style="color: #000000;">8</span> <span style="color: #0000ff;">GET</span> oGet2 <span style="color: #0000ff;">VAR</span> dDAY2 <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">40</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"##.##.####"</span><br />@ <span style="color: #000000;">5.5</span>, <span style="color: #000000;">16</span> <span style="color: #0000ff;">CHECKBOX</span> oGet3 <span style="color: #0000ff;">VAR</span> lPRICE <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"&Price"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">20</span> <span style="color: #0000ff;">OF</span> oDlg <br /><br />@ <span style="color: #000000;">5.5</span>, <span style="color: #000000;">1.9</span> <span style="color: #0000ff;">BUTTON</span> oBtn1 <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Date-Test"</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">50</span>, <span style="color: #000000;">25</span> <span style="color: #0000ff;">OF</span> oDlg ;<br /><span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">(</span> oGet1:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, oGet2:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, oGet3:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, ;<br /> GET_DAYS<span style="color: #000000;">(</span> dDAY1, dDAY2, aSEASON <span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br />@ <span style="color: #000000;">5.5</span>, <span style="color: #000000;">15</span> <span style="color: #0000ff;">BUTTON</span> oBtn2 <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Close"</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">50</span>, <span style="color: #000000;">25</span> <span style="color: #0000ff;">OF</span> oDlg ;<br /><span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">(</span> oDlg:<span style="color: #000000;">End</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: #0000ff;">CENTERED</span> ;<br /><span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">PAINT</span> gradpaint1<span style="color: #000000;">(</span> hDC, oDlg <span style="color: #000000;">)</span> <br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #000000;">(</span> <span style="color: #00C800;">NIL</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">// -----------------------------------------------</span><br /><br /><span style="color: #00C800;">static</span> func gradpaint1<span style="color: #000000;">(</span> hDC, oDlg <span style="color: #000000;">)</span><br /><span style="color: #00C800;">Local</span> oBmp1<br /><span style="color: #00C800;">local</span> aGrad := <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.50</span>, <span style="color: #000000;">16054371</span>, <span style="color: #000000;">11892819</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><br /><br />GradientFill<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, oDlg:<span style="color: #000000;">nHeight</span>, oDlg:<span style="color: #000000;">nWidth</span>, aGrad, .F. <span style="color: #000000;">)</span><br /><br /><span style="color: #0000ff;">DEFINE</span> BITMAP oBmp1 FILENAME <span style="color: #ff0000;">"User.bmp"</span><br />ABPaint<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">20</span>, <span style="color: #000000;">10</span>, oBmp1:<span style="color: #000000;">hBitmap</span>, <span style="color: #000000;">220</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /> </div>[/code:3rd4k9y4]
Regards
Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
gpf error strange | try to insert trasparent bimap into group |
gpf error strange | Works fine :
[img:h9zq50h8]http://www.pflegeplus.com/pictures/brush11.jpg[/img:h9zq50h8]
Regards
Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
gpf error strange | can see you code pls into a dialog NO gradient
no use gradpaint function |
gpf error strange | Hello Silvio,
I noticed, that You do the BMP-Painting together with the Gradient [color=#FF0000:1myid04g]ON INIT[/color:1myid04g].
Did You try Gradient and BMP-display with ON PAINT ?
I didn't test Your code for the moment.
Regards
Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
grabar y leer un array multi dimensional | Hola Fivewinners.
Requiero guardar y leer en un campo memo, un arreglo multi dimensional, YA intente guardarlo con aSave y leerlo con aRead, pero me envia el siguiente error:
Time from start: 0 hours 1 mins 39 secs
Error occurred at: 11/11/2013, 12:24:18
Error description: Error BASE/1131 Bound error: array dimension
Args:
[ 1] = N -4799
Stack Calls
===========
Called from: => ARRAY( 0 )
Called from: .\source\classes\WINDOW.PRG => AREAD( 1816 )
Called from: C:\Actividades\prg\actividadxml08.prg => AV_GENERA_R08( 874 )
Estoy utilizando Fw1308 y xHarbour 1.123
Alguien conoce el truco ?
Saludos |
grabar y leer un array multi dimensional | FW_ValToExp
[code=fw:h1w59vjo]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">// IF lNuevo</span><br /><span style="color: #B900B9;">// IF FLUJ->( DBAppendRec() )</span><br /><span style="color: #B900B9;">// FLUJ->PROCESADO := FALSE</span><br /><span style="color: #B900B9;">// FLUJ->NUM_CIUD := nNumCiud</span><br /><span style="color: #B900B9;">// FLUJ->NUM_RUTA := nNumRuta</span><br /><span style="color: #B900B9;">// FLUJ->FECHA := dFecha</span><br /><span style="color: #B900B9;">// FLUJ->TOTAL := aTotales[ K_TOTAL ]</span><br /><span style="color: #B900B9;">// FLUJ->EFECTIVOS := aTotales[ K_TOTAL_COLUMNA ]</span><br /><span style="color: #B900B9;">// FLUJ->DOLARES := aTotales[ K_TOTAL_DOLARES ]</span><br /><span style="color: #B900B9;">// FLUJ->DEPOSITOS := aTotales[ K_TOTAL_DEPOSITOS ]</span><br /><span style="color: #B900B9;">// FLUJ->GASTOS := aTotales[ K_TOTAL_GASTOS ]</span><br /><span style="color: #B900B9;">// FLUJ->DIFERIDOS := aTotales[ K_TOTAL_DIFERIDOS ]</span><br /><span style="color: #B900B9;">// FLUJ->NOTA := cNota</span><br /><span style="color: #B900B9;">// FLUJ->DETALLE := FW_ValToExp( { aDetalleC, aDetalleD, aDepositos, aGastos, aTotales } )</span><br /><span style="color: #B900B9;">// lGrabado := TRUE</span><br /><span style="color: #B900B9;">// ENDIF</span><br /><span style="color: #B900B9;">// ELSE</span><br /> </div>[/code:h1w59vjo]
[code=fw:h1w59vjo]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> <span style="color: #00C800;">TRY</span><br /> oQryTmp := oServer:<span style="color: #000000;">Query2</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"SELECT * FROM vCATFLUJ_E WHERE MY_RECNO=%1 LIMIT 1"</span>, <span style="color: #000000;">{</span> nMy_RecNo <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> nNumRuta := oQryTmp:<span style="color: #000000;">NUM_RUTA</span><br /> cNomRuta := oQryTmp:<span style="color: #000000;">RUTA</span><br /> nNumCobr := oQryTmp:<span style="color: #000000;">NUM_COBR</span><br /> cNomCobr := oQryTmp:<span style="color: #000000;">COBRADOR</span><br /> cNota := oQryTmp:<span style="color: #000000;">NOTA</span><br /> aDetalle := StringToArray<span style="color: #000000;">(</span> oQryTmp:<span style="color: #000000;">DETALLE</span> <span style="color: #000000;">)</span><br /> oQryTmp:<span style="color: #000000;">END</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> CATCH oError<br /> ShowError<span style="color: #000000;">(</span> oError, <span style="color: #000000;">{</span> oQryTmp <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">RETURN</span><br /> END<br /> </div>[/code:h1w59vjo]
[code=fw:h1w59vjo]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00C800;">FUNCTION</span> StringToArray<span style="color: #000000;">(</span> cString <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">LOCAL</span> aArray := <span style="color: #000000;">{</span><span style="color: #000000;">}</span><br /> <span style="color: #00C800;">LOCAL</span> oError := <span style="color: #00C800;">NIL</span><br /><br /> <span style="color: #00C800;">IF</span> !Empty<span style="color: #000000;">(</span> cString <span style="color: #000000;">)</span><br /> cString := AllTrim<span style="color: #000000;">(</span> cString <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">TRY</span><br /> <span style="color: #00C800;">IF</span> <span style="color: #0000ff;">Left</span><span style="color: #000000;">(</span> cString, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> == <span style="color: #ff0000;">"{"</span> .and. <span style="color: #0000ff;">Right</span><span style="color: #000000;">(</span> cString, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> == <span style="color: #ff0000;">"}"</span><br /> aArray := &<span style="color: #000000;">(</span> cString <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">IF</span> !HB_IsArray<span style="color: #000000;">(</span> aArray <span style="color: #000000;">)</span><br /> aArray := <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 /> CATCH oError<br /> aArray := <span style="color: #000000;">{</span><span style="color: #000000;">}</span><br /> END<br /> <span style="color: #00C800;">ENDIF</span><br /><br /><span style="color: #00C800;">RETURN</span> aArray<br /> </div>[/code:h1w59vjo] |
grabar y llamar un archivo de imagen en una tabla mySQL | Hola Amigos:
Quisiera saber si alguien me puede ayudar a realizar esta acción.
lo que quiero conseguir es que un archivo de imagen, (jpg o bmp), que fue sacada con una cámara digital, la pueda grabar en un campo de una tabla Mysql, y posteriormente mostrarla con mi aplicación en una pantalla de ingreso.
espero que me hayan entendido.
saludos desde Chile |
grabar y llamar un archivo de imagen en una tabla mySQL | Armando, yo he conseguido hacerlo así, pero solo para bitmaps tipo BMP de 24 bits (lo he probado con un bitmap pequeño de 256X256, con más grandes supong que fucionará igual):
Necesitas tres campos en tu base d datos: ANCHO, ALTO y DATOS (de la imagen). los dos primeros numéricos y el último un MEMO.
[code=fw:otsnlkfa]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">FUNCTION</span> Prueba<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">LOCAL</span> oDlg<br /> <span style="color: #00C800;">LOCAL</span> nWidth,nHeight<br /> <span style="color: #00C800;">LOCAL</span> hBmp<br /> <span style="color: #00C800;">LOCAL</span> cImg := CurDrive<span style="color: #000000;">(</span><span style="color: #000000;">)</span>+<span style="color: #ff0000;">":<span style="color: #000000;">\"</span>+CurDir()+"</span>\PAISAJE.bmp<span style="color: #ff0000;">" // imagen BMP de 24 bits<br /> *<br /> cImg := MEMOREAD( cImg )<br /> nWidth = ASC(SubStr(cimg,19,1))+(ASC(SubStr(cimg,20,1))*256)+(ASC(SubStr(cimg,21,1))*65536)<br /> nHeight = ASC(SubStr(cimg,23,1))+(ASC(SubStr(cimg,24,1))*256)+(ASC(SubStr(cimg,25,1))*65536)<br /> cImg := SubStr(cImg,55) // DATOS DE LA IMAGEN<br /> *<br /> hBmp := BuildImage( nWidth, nHeight, cImg )<br /> *<br /> DEFINE DIALOG oDlg SIZE 350,350<br /> oDlg:bPainted := { |hDc| PaintPrb(hDc,hBmp) }<br /> ACTIVATE DIALOG oDlg CENTER<br /> <br /> DeleteObject( hBmp )<br /><br />RETURN NIL<br />*<br />FUNCTION PaintPrb(hDc,hBit)<br /> PalBmpDraw( hDc,10,10,hBit)<br />RETURN NIL</span></div>[/code:otsnlkfa]
Me explico: Carga la imagen como si fuera un TXT, con MEMOREAD(), calculas nWidth, nHeight y cImage como en el ejemplo y guarda nWidth en el campo ANCHO, nHeight en el campo ALTO y cImage en el MEMO DATOS.
Para reconstruir la imagen he creado la función en C++ (borland 5.5) BUILDIMAGE, este es el código.
[code=fw:otsnlkfa]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> BUILDIMAGE <span style="color: #000000;">)</span> <span style="color: #B900B9;">// BuildImage( nWidth, nHeight, cImage )</span><br /> <span style="color: #000000;">{</span><br /> HDC hDc1 = CreateCompatibleDC<span style="color: #000000;">(</span> <span style="color: #00C800;">NULL</span> <span style="color: #000000;">)</span> ;<br /><br /> int nWidth = hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> ;<br /> int nHeight = hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span> ;<br /><br /> LPSTR cImage = hb_parc<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span> ;<br /><br /> BITMAPINFO bmi ;<br /> HBITMAP hBitmap ;<br /> VOID *pvBits ;<br /><br /> int i,j,k,v ;<br /><br /> int nQWidth = <span style="color: #000000;">(</span><span style="color: #000000;">(</span><span style="color: #000000;">(</span> nWidth * <span style="color: #000000;">24</span> + <span style="color: #000000;">31</span> <span style="color: #000000;">)</span> & ~<span style="color: #000000;">31</span> <span style="color: #000000;">)</span> >> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span> ;<br /><br /> bmi.bmiHeader.biSize = sizeof<span style="color: #000000;">(</span> BITMAPINFOHEADER <span style="color: #000000;">)</span> ;<br /> bmi.bmiHeader.biWidth = nWidth ;<br /> bmi.bmiHeader.biHeight = nHeight ;<br /> bmi.bmiHeader.biPlanes = <span style="color: #000000;">1</span> ;<br /> bmi.bmiHeader.biBitCount = <span style="color: #000000;">24</span> ;<br /> bmi.bmiHeader.biCompression = BI_RGB ;<br /> bmi.bmiHeader.biSizeImage = nQWidth * nHeight ;<br /><br /> hBitmap = CreateDIBSection<span style="color: #000000;">(</span> hDc1, &bmi, DIB_RGB_COLORS, &pvBits, <span style="color: #00C800;">NULL</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> ;<br /><br /> v = <span style="color: #000000;">0</span> ; <br /> <span style="color: #00C800;">for</span> <span style="color: #000000;">(</span> i = <span style="color: #000000;">0</span>; i < nHeight; ++i <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> k = i * nQWidth ;<br /> <span style="color: #00C800;">for</span> <span style="color: #000000;">(</span> j = <span style="color: #000000;">0</span>; j < <span style="color: #000000;">(</span>nWidth*<span style="color: #000000;">3</span><span style="color: #000000;">)</span>; j += <span style="color: #000000;">3</span> <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+0</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+0</span> <span style="color: #000000;">]</span> ;<br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+1</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+1</span> <span style="color: #000000;">]</span> ;<br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+2</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+2</span> <span style="color: #000000;">]</span> ;<br /> v += <span style="color: #000000;">3</span> ;<br /> <span style="color: #000000;">}</span><br /> <span style="color: #000000;">}</span><br /><br /> DeleteDC<span style="color: #000000;">(</span> hDc1 <span style="color: #000000;">)</span> ;<br /><br /> hb_retnl<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> hBitmap <span style="color: #000000;">)</span> ;<br /> <span style="color: #000000;">}</span><br /> </div>[/code:otsnlkfa]
A mi me funciona perfectamente.
Para compilar la función en C++ tendrás que utilizar las cabeceras pertinentes (alguien habrá que sepas cuales son). Lo que pasa es que yo lo he hecho incluyendo esa función en una librería en la que tengo varias funciones de C++ y no se que cabeceras se utilizan para FWH con PRAGMA (nunca lo he heco). |
grabar y llamar un archivo de imagen en una tabla mySQL | Armando, creo que he cometido un error, esto solo funciona cuando el numero de bits por linea de la imagen es multiplo de 4. Hoy no tengo tiempo de seguir experimentando pero lo miro y te lo posteo. |
grabar y llamar un archivo de imagen en una tabla mySQL | Este si funciona:
[code=fw:31k0rjfd]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> BUILDIMAGE <span style="color: #000000;">)</span> <span style="color: #B900B9;">// BuildImage( nWidth, nHeight, cImage )</span><br /> <span style="color: #000000;">{</span><br /> HDC hDc1 = CreateCompatibleDC<span style="color: #000000;">(</span> <span style="color: #00C800;">NULL</span> <span style="color: #000000;">)</span> ;<br /><br /> int nWidth = hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> ;<br /> int nHeight = hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span> ;<br /><br /> LPSTR cImage = hb_parc<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span> ;<br /><br /> BITMAPINFO bmi ;<br /> HBITMAP hBitmap ;<br /> VOID *pvBits ;<br /><br /> int i,j,k,v ;<br /><br /> int nQWidth = <span style="color: #000000;">(</span><span style="color: #000000;">(</span><span style="color: #000000;">(</span> nWidth * <span style="color: #000000;">24</span> + <span style="color: #000000;">31</span> <span style="color: #000000;">)</span> & ~<span style="color: #000000;">31</span> <span style="color: #000000;">)</span> >> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span> ;<br /><br /> bmi.bmiHeader.biSize = sizeof<span style="color: #000000;">(</span> BITMAPINFOHEADER <span style="color: #000000;">)</span> ;<br /> bmi.bmiHeader.biWidth = nWidth ;<br /> bmi.bmiHeader.biHeight = nHeight ;<br /> bmi.bmiHeader.biPlanes = <span style="color: #000000;">1</span> ;<br /> bmi.bmiHeader.biBitCount = <span style="color: #000000;">24</span> ;<br /> bmi.bmiHeader.biCompression = BI_RGB ;<br /> bmi.bmiHeader.biSizeImage = nQWidth * nHeight ;<br /><br /> hBitmap = CreateDIBSection<span style="color: #000000;">(</span> hDc1, &bmi, DIB_RGB_COLORS, &pvBits, <span style="color: #00C800;">NULL</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> ;<br /><br /> v = <span style="color: #000000;">0</span> ; <br /> <span style="color: #00C800;">for</span> <span style="color: #000000;">(</span> i = <span style="color: #000000;">0</span>; i < nHeight; ++i <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> k = i * nQWidth ;<br /> <span style="color: #00C800;">for</span> <span style="color: #000000;">(</span> j = <span style="color: #000000;">0</span>; j < <span style="color: #000000;">(</span>nWidth*<span style="color: #000000;">3</span><span style="color: #000000;">)</span>; j += <span style="color: #000000;">3</span> <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+0</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+0</span> <span style="color: #000000;">]</span> ;<br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+1</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+1</span> <span style="color: #000000;">]</span> ;<br /> <span style="color: #000000;">(</span> <span style="color: #000000;">(</span>BYTE *<span style="color: #000000;">)</span> pvBits <span style="color: #000000;">)</span><span style="color: #000000;">[</span>k+j<span style="color: #000000;">+2</span><span style="color: #000000;">]</span> = <span style="color: #000000;">(</span> BYTE <span style="color: #000000;">)</span> cImage<span style="color: #000000;">[</span> v<span style="color: #000000;">+2</span> <span style="color: #000000;">]</span> ;<br /> v += <span style="color: #000000;">3</span> ;<br /> <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">while</span> <span style="color: #000000;">(</span> v%<span style="color: #000000;">4</span> > <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> ++v ;<br /> <span style="color: #000000;">}</span><br /> <span style="color: #000000;">}</span><br /><br /> DeleteDC<span style="color: #000000;">(</span> hDc1 <span style="color: #000000;">)</span> ;<br /><br /> hb_retnl<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> hBitmap <span style="color: #000000;">)</span> ;<br /> <span style="color: #000000;">}</span><br /> </div>[/code:31k0rjfd] |
grabar y llamar un archivo de imagen en una tabla mySQL | Este es un tema que me resulta muy interesante, por favor, si logran que funcione plenamente y determinar cuales archivos de cabezal se deben incluir, háganlo saber <!-- s:roll: --><img src="{SMILIES_PATH}/icon_rolleyes.gif" alt=":roll:" title="Rolling Eyes" /><!-- s:roll: --> , ya que me parece una función muy útil para una aplicación que me encuentro desarrollando <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> .
Gracias desde ya a los compañeros del foro, verdaderamente es un placer contar con Uds. <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
grabar y llamar un archivo de imagen en una tabla mySQL | gracias por contestar, voy a realizar las pruebas y les cuento como me fue.
gracias. |
grabar y llamar un archivo de imagen en una tabla mySQL | Armando
Si usas ADO, lo puedes hacer mediante el objeto ADO Stream. Para ello (como yo lo hago) previamente debes crear un[b:7ibjcy2z] objeto Connection[/b:7ibjcy2z], un[b:7ibjcy2z] objeto Recordset [/b:7ibjcy2z]que venga vacío para agregarle el nuevo registro con la foto [b:7ibjcy2z]y un Objeto ADO Stream[/b:7ibjcy2z]. El objeto Stream carga el archivo que posteriormente será enviado al objeto recordset. El regreso se hace a la inversa. Se carga la foto al objeto stream desde el recordset para posteriormente grabarlo en una carpeta local, y ya copiado lo podemos usar como queramos. A continucación parte del código, Ojo que el objeto connection ya está creado con oCon:TOleAuto():New("adodb.connection")
[code=fw:7ibjcy2z]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #B900B9;">//Recordset para la foto grande</span><br /><span style="color: #00C800;">TRY</span><br /> oRsFoto := TOleAuto<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"adodb.recordset"</span><span style="color: #000000;">)</span> <br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo crear el recordset para la Foto !"</span>, CAR_VERSION<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">RETURN</span> .f.<br />END<br /><br /><span style="color: #B900B9;">//Configuramos el recordset </span><br />oRsFoto:<span style="color: #000000;">CursorLocation</span> := adUseClient<br />oRsFoto:<span style="color: #000000;">LockType</span> := adLockOptimistic<br />oRsFoto:<span style="color: #000000;">CursorType</span> := adOpenKeyset<span style="color: #B900B9;">//adOpenDynamic</span><br /><span style="color: #B900B9;">//lo siguiente recupera una tabla vacia</span><br />oRsFoto:<span style="color: #000000;">Source</span> := <span style="color: #ff0000;">"SELECT cod,cod_veh,foto_p,foto,tipo,fecha,nota FROM fotos_veh where cod = 0 "</span> <br />oRsFoto:<span style="color: #000000;">ActiveConnection</span><span style="color: #000000;">(</span>oCon<span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">TRY</span><br /> oRsFoto:<span style="color: #000000;">Open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo abrir la Tabla de la Foto!"</span>, car_version<span style="color: #000000;">)</span><br /> ShowError<span style="color: #000000;">(</span>oError,oCon<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">RETURN</span> .f.<br />END<br /><br /><span style="color: #B900B9;">//----Objeto stream para la foto grande</span><br /><span style="color: #00C800;">TRY</span><br /> ::<span style="color: #000000;">oStream</span> := TOleAuto<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"adodb.Stream"</span><span style="color: #000000;">)</span> <br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo crear el Stream para leer la Foto !"</span>, CAR_VERSION<span style="color: #000000;">)</span><br />END<br /><span style="color: #B900B9;">// Especifica el tipo de datos ( binario ) </span><br />::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Type</span> := adTypeBinary <br /><br /><span style="color: #00C800;">TRY</span><br /> ::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo establecer la conexion stream!"</span>, car_version<span style="color: #000000;">)</span><br /> ShowError<span style="color: #000000;">(</span>oError,oCon<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> .f.<br />END<br />::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">LoadFromFile</span><span style="color: #000000;">(</span>cfile<span style="color: #000000;">)</span><span style="color: #B900B9;">// cfile puede ser obtenida con cgetfile() </span><br /><br />oRsfoto:<span style="color: #000000;">Addnew</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />oRsfoto:<span style="color: #000000;">fields</span><span style="color: #000000;">(</span><span style="color: #ff0000;">'cod_veh'</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Value</span> := ::<span style="color: #000000;">oRsV</span>:<span style="color: #000000;">Fields</span><span style="color: #000000;">(</span><span style="color: #ff0000;">'cod_veh'</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Value</span><br /><span style="color: #00C800;">try</span><br /> oRsFoto:<span style="color: #000000;">Fields</span><span style="color: #000000;">(</span><span style="color: #ff0000;">'foto'</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Value</span> = ::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Read</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />catch oError<br /> MsgStop<span style="color: #000000;">(</span><span style="color: #ff0000;">"Problemas al subir la fotografía"</span><span style="color: #000000;">)</span><br /> ShowError<span style="color: #000000;">(</span>oError,oCon<span style="color: #000000;">)</span><br />end<br />oRsFoto:<span style="color: #000000;">Fields</span><span style="color: #000000;">(</span><span style="color: #ff0000;">'fecha'</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Value</span> = fecha<br />oRsFoto:<span style="color: #000000;">Fields</span><span style="color: #000000;">(</span><span style="color: #ff0000;">'nota'</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Value</span> = nota<br />oRsFoto:<span style="color: #0000ff;">Update</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Close</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span></div>[/code:7ibjcy2z]
Ahora para leerla
[code=fw:7ibjcy2z]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">//Recordset para la foto grande</span><br /><span style="color: #00C800;">TRY</span><br /> oRsFoto := TOleAuto<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"adodb.recordset"</span><span style="color: #000000;">)</span> <br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo crear el recordset para la Foto !"</span>, CAR_VERSION<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">RETURN</span> .f.<br />END<br /><br /><span style="color: #B900B9;">//Configuramos el recordset que me dovolvera una foto</span><br />oRsFoto:<span style="color: #000000;">CursorLocation</span> := adUseClient<br />oRsFoto:<span style="color: #000000;">LockType</span> := adLockOptimistic<br />oRsFoto:<span style="color: #000000;">CursorType</span> := adOpenKeyset<span style="color: #B900B9;">//adOpenDynamic</span><br />oRsFoto:<span style="color: #000000;">Source</span> := <span style="color: #ff0000;">"SELECT cod,foto,tipo FROM fotos_veh where cod ="</span>+ nCod <br />oRsFoto:<span style="color: #000000;">ActiveConnection</span><span style="color: #000000;">(</span>oCon<span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">TRY</span><br /> oRsFoto:<span style="color: #000000;">Open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo abrir la Tabla de la Foto!"</span>, car_version<span style="color: #000000;">)</span><br /> ShowError<span style="color: #000000;">(</span>oError,oCon<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">RETURN</span> .f.<br />END<br /><br /><span style="color: #00C800;">TRY</span><br /> ::<span style="color: #000000;">oStream</span> := TOleAuto<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"adodb.Stream"</span><span style="color: #000000;">)</span> <br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo crear el Stream para leer la Foto !"</span>, CAR_VERSION<span style="color: #000000;">)</span><br />END<br /><br /><span style="color: #B900B9;">// Especifica el tipo de datos ( binario ) </span><br />::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Type</span> := adTypeBinary <br /><br /><span style="color: #00C800;">TRY</span><br /> ::<span style="color: #000000;">oStream</span>:<span style="color: #000000;">Open</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br />CATCH oError<br /> MsgStop<span style="color: #000000;">(</span> <span style="color: #ff0000;">"No se pudo establecer la conexion stream!"</span>, car_version<span style="color: #000000;">)</span><br /> ShowError<span style="color: #000000;">(</span>oError,oCon<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> .f.<br />END<br /><br /><span style="color: #00C800;">if</span> !lisDir<span style="color: #000000;">(</span><span style="color: #ff0000;">"imgtmp"</span><span style="color: #000000;">)</span><br /> lMkDir<span style="color: #000000;">(</span><span style="color: #ff0000;">"imgtmp"</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">endif</span><br /><span style="color: #00C800;">if</span> !lisDir<span style="color: #000000;">(</span><span style="color: #ff0000;">"imgtmp<span style="color: #000000;">\"</span> + cFold )<br /> lMkDir("</span>imgtmp\<span style="color: #ff0000;">" + cFold )<br />endif<br /><br />if !oRsFoto:EOF .and. !oRsFoto:BOF<br /> //Graba los datos en el objeto stream <br /> IF oRsFoto:Fields('foto'):Value !=nil<br /> ::oStream:Write(oRsFoto:Fields('foto'):Value) <br /> cfoto:="</span>imgtmp\<span style="color: #ff0000;">" + cFold+"</span>fg<span style="color: #ff0000;">"+alltrim(str(oRsFoto:Fields('cod'):Value)) + "</span>.<span style="color: #ff0000;">" + alltrim(oRsFoto:Fields('tipo'):Value)<br /> if file(cfoto)<br /> ferase(cfoto)<br /> endif<br /> //Se graba un archivo temporal en disco<br /> ::oStream:SaveToFile(cfoto, adSaveCreateOverWrite) <br /> if fsize(cfoto)>0 <br /> oImg:LoadBmp(cfoto)<br /> else<br /> oImg:LoadImage( "</span>shade<span style="color: #ff0000;">" )<br /> endif<br /> oimg:Refresh()<br /> endif<br />endif<br /><br />::oStream:Close()<br />oRsfoto:Close()<br /></span></div>[/code:7ibjcy2z]
Una vez bajado lo podemos usar a nuestro gusto, yo lo he cargado a un objeto Image.
Es una opción más que lo puedes probar.
Un saludo
Marcelo Jingo |
grabar y llamar un archivo de imagen en una tabla mySQL | estimado sjingo:
lamentablemente, no utilizo ADO, realizo mi conexión por ODBC 5.1 de mysql, pero me has dado una luz con el codigo que publicaste, asi que lo voy a estudiar a fondo para ver la posibilidad de transformarlo y hacerlo funcionar con ODBC.
cuando tenga algo concreto lo voy a publicar para que quede a disposición de la comunidad Fivewinera.
bueno, si alguien más me pueda ayudar, estaré atento a sus sugerencias.
saludos desde Chile. |
grabar y llamar un archivo de imagen en una tabla mySQL | Saludos...
la clase TImagen cuenta con esa propiedad y existe la funcion FILoadFromMemory, esta ubicada en fwh\source\image.prg, usa freeimage.dll es tan simple como hacer
MiCampo = MemoRead( "mifoto.jpg" )
hBmp = FILoadFromMemory( MiCampo )
o usar la propia clase TImaga para que realice dicha labor
lamentablemente dentro de los ejemplo de fivewin no hay uno sobre dicha funcionalidad, pero no deberia ser muy complicado y aparenta ser muy facil usarlo
igualmente puden revisar este post del colega Cesar Lozada que patocino la idea inicial: [url:3df1hko5]http://forums.fivetechsupport.com/viewtopic.php?p=76883#p76883[/url:3df1hko5] |
grabar y llamar un archivo de imagen en una tabla mySQL | Saludos...
Ahora si solo usas .BMP creo que la funcion CreateMemBitmap te podria servir tambien, o usando la clase TBitmap el metodo LoadFromString revisa este otro post: [url:3l4vrz6b]http://forums.fivetechsupport.com/viewtopic.php?p=49250#p49250[/url:3l4vrz6b] |
grabar y llamar un archivo de imagen en una tabla mySQL | Armando, ayer te contesté de forma apresurada, y creé la función a partir de otras mias, pero ahora he dado con la tecla para guardar cualquier tipo de BMP.
Carga la imagen con MEMOREAD como antes, pero no hay que descomponerla, guárdala tal cual en un campo MEMO, BUILDIMAGE() te devolverá el handle de la imagen cuando lo necesites.
[code=fw:3t8a3mje]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">LOCAL</span> cImage<br />cImage := MemoRead<span style="color: #000000;">(</span> <span style="color: #ff0000;">"C:<span style="color: #000000;">\.</span>...<span style="color: #000000;">\I</span>magen.Bmp"</span><span style="color: #000000;">)</span><br />BuilImage<span style="color: #000000;">(</span> cImage <span style="color: #000000;">)</span><br /> </div>[/code:3t8a3mje]
La nueva función sería esta:
[code=fw:3t8a3mje]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> BUILDIMAGE <span style="color: #000000;">)</span> <span style="color: #B900B9;">// BuildImage( cImage )</span><br /> <span style="color: #000000;">{</span><br /> HDC hDc1 = CreateCompatibleDC<span style="color: #000000;">(</span> <span style="color: #00C800;">NULL</span> <span style="color: #000000;">)</span> ;<br /><br /> LPSTR cImage = hb_parc<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> ;<br /><br /> HBITMAP hBitmap ;<br /> BITMAPINFO bmi ;<br /> BITMAPFILEHEADER bmh ;<br /><br /> VOID * pvBits ;<br /> BYTE * pvDats ;<br /> BITMAPINFO * lpbi ;<br /><br /> pvDats = &cImage<span style="color: #000000;">[</span><span style="color: #000000;">0</span><span style="color: #000000;">]</span> ;<br /> bmh = * <span style="color: #000000;">(</span> BITMAPFILEHEADER * <span style="color: #000000;">)</span> pvDats ;<br /> pvDats += <span style="color: #000000;">14</span> ;<br /> lpbi = <span style="color: #000000;">(</span> BITMAPINFO * <span style="color: #000000;">)</span> pvDats ;<br /> pvDats += <span style="color: #000000;">(</span> bmh.bfOffBits<span style="color: #000000;">-14</span> <span style="color: #000000;">)</span> ;<br /> bmi = * lpbi ;<br /><br /> hBitmap = CreateDIBSection<span style="color: #000000;">(</span> hDc1, &bmi, DIB_RGB_COLORS, &pvBits, <span style="color: #00C800;">NULL</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> ;<br /><br /> SetDIBits<span style="color: #000000;">(</span> hDc1, hBitmap, 0L, bmi.bmiHeader.biHeight, pvDats, <span style="color: #000000;">(</span> LPBITMAPINFO <span style="color: #000000;">)</span> lpbi, <span style="color: #000000;">(</span> DWORD <span style="color: #000000;">)</span> DIB_RGB_COLORS <span style="color: #000000;">)</span> ;<br /><br /> DeleteDC<span style="color: #000000;">(</span> hDc1 <span style="color: #000000;">)</span> ;<br /><br /> hb_retnl<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> hBitmap <span style="color: #000000;">)</span> ;<br /> <span style="color: #000000;">}</span><br /><br /> </div>[/code:3t8a3mje]
Y nada más. Así de simple. Como te decía, sirve para cualquier BMP. |
grabar y llamar un archivo de imagen en una tabla mySQL | gracias por contestar, estoy probando con sus aportaciones, apenas me resulte las voy a publicar.
hay una acotación, el tipo de campo que debo ocupar es tipo BLOB en una tabla MYSQL, y lo ideal es tener por separado, una tabla con los datos de la persona y en otra, la imagen con un campo indice apuntando a la principal.
saludos desde Chile.
<!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
gracias | gracias
karinha
lo probe |
gracias | voy a internar contacatr al fabricante.
Gracias |
gradiants ? | Hi all,
could someone tell me where to find information about how to build gradiants?
Thanks,
Detlef |
gradiants ? | aGradient := { ;
{ size1, clrStart1, clrEnd1 }, ;
{ size2, clrStart2, clrEnd2 }, ;
....
{ sizeN, clrStartN, clrEndN } [, lOrient] }
All sizes are fractions less than 1 and total of all sizes should be 1.0
Optionsl lOrient: .T. for Vertical ( default )
.F. for Horizontal
"RING" for ring gradient
We can fill parts of window/dialog/control with
FillRectEx( hDC, aRect, aGrad )
We can also define gradient brush and assign to a window
DEFINE BRUSH oBrush GRADIENT aGrad
Brushes get automatically resized when window gets resized |
gradiants ? | Sample:
[code=fw:21guzqd8]<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: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> oWnd<br /> <span style="color: #00C800;">local</span> aGradV := ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_BLUE, CLR_HBLUE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_HBLUE, CLR_WHITE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_WHITE, CLR_HGREEN <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_HGREEN, CLR_GREEN <span style="color: #000000;">}</span> ;<br /> , .T. ; <span style="color: #B900B9;">// .t. for vertical and .f. for horizontal (defaul .t.)</span><br /> <span style="color: #000000;">}</span><br /><br /> <span style="color: #00C800;">local</span> aGradH := ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_BLUE, CLR_HBLUE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_HBLUE, CLR_WHITE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_WHITE, CLR_HGREEN <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_HGREEN, CLR_GREEN <span style="color: #000000;">}</span> ;<br /> , .F. ; <span style="color: #B900B9;">// .t. for vertical and .f. for horizontal (defaul .t.)</span><br /> <span style="color: #000000;">}</span><br /><br /> <span style="color: #00C800;">local</span> aGradR := ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_BLUE, CLR_HBLUE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_HBLUE, CLR_WHITE <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.30</span>, CLR_WHITE, CLR_HGREEN <span style="color: #000000;">}</span> ;<br /> , <span style="color: #000000;">{</span> <span style="color: #000000;">0.20</span>, CLR_HGREEN, CLR_GREEN <span style="color: #000000;">}</span> ;<br /> , <span style="color: #ff0000;">"RING"</span> ;<br /> <span style="color: #000000;">}</span><br /><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">FROM</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">0</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">800</span>,<span style="color: #000000;">800</span> <span style="color: #0000ff;">PIXEL</span><br /><br /> oWnd:<span style="color: #000000;">bPainted</span> := < |hDC|<br /> FillRectEx<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">{</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">100</span>, <span style="color: #000000;">200</span>, <span style="color: #000000;">300</span> <span style="color: #000000;">}</span>, aGradV <span style="color: #000000;">)</span><br /> FillRectEx<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">{</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">400</span>, <span style="color: #000000;">200</span>, <span style="color: #000000;">600</span> <span style="color: #000000;">}</span>, aGradH <span style="color: #000000;">)</span><br /> FillRectEx<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">{</span> <span style="color: #000000;">300</span>, <span style="color: #000000;">100</span>, <span style="color: #000000;">500</span>, <span style="color: #000000;">300</span> <span style="color: #000000;">}</span>, aGradR <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> ><br /><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">CENTERED</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:21guzqd8]
[url=https://imageshack.com/i/plp9aByZp:21guzqd8][img:21guzqd8]https://imagizer.imageshack.com/v2/xq90/921/p9aByZ.png[/img:21guzqd8][/url:21guzqd8] |
gradiants ? | Many thanks, Mr. Rao for this excellent information. |
gradiants ? | Here are a few functions I have created and use ...
[code=fw:2stvkvem]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">//-------------------</span><br />Func GreyButtonGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">// 2010 grey button skin</span><br /><br /><span style="color: #00C800;">Local</span> bGrad<br /><br />bGrad := <span style="color: #000000;">{</span> | lInvert | <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> ! lInvert, ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">1</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">207</span>, <span style="color: #000000;">207</span>, <span style="color: #000000;">207</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span>, ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">1</span>/<span style="color: #000000;">3</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">253</span>, <span style="color: #000000;">222</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">231</span>, <span style="color: #000000;">151</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span>, ;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">2</span>/<span style="color: #000000;">3</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">215</span>, <span style="color: #000000;">84</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">233</span>, <span style="color: #000000;">162</span> <span style="color: #000000;">)</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: #00C800;">Return</span><span style="color: #000000;">(</span> bGrad <span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//---------------------------</span><br />Func BlueGreenGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Local</span> xGrad4 := <span style="color: #000000;">{</span><span style="color: #000000;">{</span> <span style="color: #000000;">1.00</span>,<span style="color: #000000;">14671839</span>, <span style="color: #000000;">7419904</span> <span style="color: #000000;">}</span>, <span style="color: #000000;">{</span> <span style="color: #000000;">1.00</span>,<span style="color: #000000;">7419904</span>, <span style="color: #000000;">14671839</span> <span style="color: #000000;">}</span><span style="color: #000000;">}</span> <span style="color: #B900B9;">// med blue</span><br />SetDlgGradient<span style="color: #000000;">(</span> xGrad4 <span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//---------------------</span><br />Func SolidGreenBlue<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span><span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">9994298</span>,<span style="color: #000000;">9994298</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">9994298</span>,<span style="color: #000000;">9994298</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><br /><span style="color: #B900B9;">//-------------</span><br />Func SolidDarkBlue<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.50</span>,<span style="color: #000000;">4720905</span>,<span style="color: #000000;">4720905</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.50</span>,<span style="color: #000000;">4720905</span>,<span style="color: #000000;">4720905</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//-------------------</span><br />Func SolidBlue<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">16711680</span>,<span style="color: #000000;">16711680</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">16711680</span>,<span style="color: #000000;">16711680</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//------------------</span><br />Func DarkBlueGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span><span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.0</span>,<span style="color: #000000;">8388608</span>,<span style="color: #000000;">13619151</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.0</span>,<span style="color: #000000;">13619151</span>,<span style="color: #000000;">8388608</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><br /><span style="color: #B900B9;">//--------------</span><br />Func LightGreenGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span><span style="color: #000000;">210</span>,<span style="color: #000000;">235</span>,<span style="color: #000000;">216</span><span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//------------------</span><br />Func LightBlueGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">201</span>, <span style="color: #000000;">217</span>, <span style="color: #000000;">237</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">231</span>, <span style="color: #000000;">242</span>, <span style="color: #000000;">255</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//------------------</span><br />Func LightGreyGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">216</span>, <span style="color: #000000;">216</span>, <span style="color: #000000;">216</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//-----------------</span><br />Func StandardGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">236</span>, <span style="color: #000000;">233</span>, <span style="color: #000000;">216</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">255</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">255</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//--------------------</span><br />Func DarkGreyGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span><span style="color: #000000;">{</span><span style="color: #000000;">{</span> <span style="color: #000000;">005.9000</span>, <span style="color: #000000;">14671839</span>, <span style="color: #000000;">4144959</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.1</span>, <span style="color: #000000;">4144959</span>, <span style="color: #000000;">14671839</span> <span style="color: #000000;">}</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span> <span style="color: #B900B9;">// .80</span><br /><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//------------------------------------</span><br />Func SolidWhite<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">16777215</span>,<span style="color: #000000;">16777215</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">16777215</span>,<span style="color: #000000;">16777215</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//--------------------</span><br />Func SolidGrey<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">233</span>, <span style="color: #000000;">233</span>, <span style="color: #000000;">233</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">233</span>, <span style="color: #000000;">233</span>, <span style="color: #000000;">233</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//--------------------</span><br />Func SolidChoral<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span>aGrad := <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">8388736</span>,<span style="color: #000000;">8388736</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">8388736</span>,<span style="color: #000000;">8388736</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//-----------------</span><br />Func LightYellow<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">0.01</span>,<span style="color: #000000;">8440801</span>,<span style="color: #000000;">16777215</span> <span style="color: #000000;">}</span>,<span style="color: #000000;">{</span> <span style="color: #000000;">0.75</span>,<span style="color: #000000;">16777215</span>,<span style="color: #000000;">8440801</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /><span style="color: #B900B9;">//-------------------</span><br />Func GreenBlueGrad<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br />SetDlgGradient<span style="color: #000000;">(</span> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> .<span style="color: #000000;">50</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">192</span>, <span style="color: #000000;">192</span>, <span style="color: #000000;">192</span> <span style="color: #000000;">)</span>, nRGB<span style="color: #000000;">(</span> <span style="color: #000000;">45</span>, <span style="color: #000000;">121</span>, <span style="color: #000000;">147</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: #00C800;">Return</span><span style="color: #000000;">(</span><span style="color: #00C800;">nil</span><span style="color: #000000;">)</span><br /><br /> </div>[/code:2stvkvem]
Rick Lipkin |
gradiants ? | Thank you, Rick.
There are some nice and useful gradiants in your post.
Your gradients and the profound explanations of Mr. Rao helped me a lot to understand and use gradients.
But I just can't understand that when Mr. Rao stated[quote:158tao1g] All sizes are fractions less than 1 and total of all sizes should be 1.0[/quote:158tao1g]
But your gradients don't care about. Do you have a certain reason for that?
Regards, Detlef |
gradiants ? | Detlef
I use the built in FiveWin SetDlgGradient() function .. not much info on the function itself but it works quite nicely ... once you issue SetDlgGradient() it becomes the default windows and dialog background.. I have given you several different gradients .. I use different gradient backgrounds throughout my programs ..
Very easy to create your own functions .. sometime back Uwe created Gradient painter .. I have the program but not the source ... you might search for "Gradient Painter" in the FW Forums and find his contribution ..
Rick Lipkin
[url=http://img4.imagetitan.com/img.php?image=25_gradient.jpg:25kuf38g][img:25kuf38g]http://img4.imagetitan.com/img4/small/25/25_gradient.jpg[/img:25kuf38g][/url:25kuf38g] |
gradiants ? | The extended version :
Adjusted links for images and downloads from the changed website.
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=29016">viewtopic.php?f=3&t=29016</a><!-- l -->
create any gradient You need from selected colours :
[img:2ie9yyxe]http://www.service-fivewin.de/images/Gradient_1.png[/img:2ie9yyxe]
best regards
Uwe <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
gradient effect | Hello,
You have to define the Gradient-Style :
----------------------------------------------
local aGrad := { { 0.50, COLOR1, COLOR2 }, ;
{ 0.50, COLOR2, COLOR1 } }
The Direction ( Horizontal or Vertical .T., .F.
-----------------------------------------------------
GradientFill( hDC, 0, 0, oWnd:nHeight, oWnd:nWidth, aGrad, .T. )
Different ways, how to do it in relation to FWH-Versions
[code:2bhbvgdu]
....
....
DEFINE WINDOW oWnd TITLE "Background for Windows and Dialog"
DEFINE BUTTONBAR oBar OF oWnd SIZE 80, 75 2007 RIGHT
// Gradient-Bar
// ---------------
oBar:bClrGrad := { | lInvert | If( ! lInvert, ;
{ { 0.90,11892819,16777215 },{ 0.90,16777215,11892819 } },;
{ { 0.50,128,16777215 }, { 0.50,16777215,128 } } ) }
oBar:nClrText := 0
DEFINE BUTTON oBtn1 OF oBar ACTION ( ..... ) ;
RESOURCE "magic" PROMPT "Project" + CRLF + "Selection" TOOLTIP "Bar-Select"
SET MESSAGE OF oWnd TO "Windows- and Dialog-Background-Settings" ;
CENTERED CLOCK KEYBOARD 2007
// Gradient with Alpha-Blended BMP
// ---------------------------------------
ACTIVATE WINDOW oWnd MAXIMIZED ;
ON PAINT ( W_GRAD( hDC, oWnd ), ALPHA_BMP(hDC) ) ;
VALID MsgYesNo( "Do you want to end?" )
RETURN NIL
// --------- GRADIENT-Functions for different FWH-Versions ---------
STATIC FUNCTION W_GRAD( hDC, oWnd )
local aGrad := { { 0.50, COLOR1, COLOR2 }, ;
{ 0.50, COLOR2, COLOR1 } }
IF W_DIRECT = 1 // Horizontal
IF FWHVERS < 7.09
// Gradient-Array is not supported !!!!
DegradeW ( hDC, oWnd )
ENDIF
IF FWHVERS >= 7.09 .and. FWHVERS < 8.07
// Gradient-Array is not supported !!!!
Gradient( hDC, { 0, 0, oWnd:nHeight, oWnd:nWidth }, COLOR1, COLOR2, .T. )
ENDIF
IF FWHVERS >= 8.07
GradientFill( hDC, 0, 0, oWnd:nHeight, oWnd:nWidth, aGrad, .T. )
ENDIF
ELSE
IF FWHVERS < 7.09
DegradeW ( hDC, oWnd )
ENDIF
IF FWHVERS >= 7.09 .and. FWHVERS < 8.07
Gradient( hDC, { 0, 0, oWnd:nHeight, oWnd:nWidth }, COLOR1, COLOR2, .F. )
ENDIF
IF FWHVERS >= 8.07
GradientFill( hDC, 0, 0, oWnd:nHeight, oWnd:nWidth, aGrad, .F. )
ENDIF
ENDIF
RETURN NIL
// ------ FOR FWH-Versions < 7.09 without GRADIENT - Functions -------
STATIC FUNCTION DegradeW ( hDC, oWnd )
LOCAL nStep , nStepY
LOCAL oBrush
LOCAL i, r,g,b
LOCAL r0,g0,b0
LOCAL r1, g1, b1
LOCAL rD, gD, bD
LOCAL aRect := GETCLIENTRECT( oWnd:hWnd )
nStep := ( aRect[ 3 ] - aRect[ 1 ] )
nStepY := ( aRect[ 3 ] - aRect[ 1 ] ) / nStep
aRect[ 3 ] = aRect[ 1 ] + nStepY
r0 := nRGBRed (W_COLOR1)
g0 := nRGBGreen (W_COLOR1)
b0 := nRGBBlue (W_COLOR1)
r1 := nRGBRed (W_COLOR2)
g1 := nRGBGreen (W_COLOR2)
b1 := nRGBBlue (W_COLOR2)
rD := r1-r0
gD := g1-g0
bD := b1-b0
r := 256*rD/Max(nStep,1)
g := 256*gD/Max(nStep,1)
b := 256*bD/Max(nStep,1)
r0*=256
g0*=256
b0*=256
FOR i = 0 TO nStep-1 STEP nStepY
r0 += r
g0 += g
b0 += b
DEFINE BRUSH oBrush COLOR nRGB( r0/256, g0/256, b0/256 )
FILLRECT( hDC, aRect, oBrush:hBrush )
RELEASE BRUSH oBrush
aRect[ 1 ] += nStepY
aRect[ 3 ] += nStepY
NEXT
RETURN (nil)
// ----------------------------
STATIC FUNCTION ALPHA_BMP(hDC)
LOCAL oBmp1
DEFINE BITMAP oBmp1 FILENAME "A_LOGO.bmp"
ABPaint( hDC, 50, 50, oBmp1:hBitmap, 220 )
RETURN( NIL )
[/code:2bhbvgdu]
I hope, I can finish the new tools in a short time.
There are 40 different tests added : Windows, Dialogs, Folders and xBrowse with all possible combinations.
The needed source is generated from the preview.
I think it covers all settings and can easy included in Your own source-code.
Regards
Uwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
gradient effect | Hi, all !
This programm with DIALOG is fine, but with WINDOW I not got of gradient effect. Why ?
DEFINE WINDOW oDlg
@ 0.5, 1 FOLDER oFld PAGES "One", "Two" SIZE 190, 140
ACTIVATE WINDOW oDlg ;
ON PAINT GradientFill( hDC, 0, 0, oDlg:nHeight, oDlg:nWidth, { { 0.50, 16054371, 8388608 } } ) ;
ON INIT SetDialogsGradient( oFld ) |
gradient effect | Thank, Uwe !! <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
gradient oBar | Attempting to try out gradient oBar and get the following message.Currently using FWH 807Using code below:Am i missing something?Error occurred at: 08/11/08, 22:22:51 Error description: Error BASE/1005 Message not found: TBAR:_BCLRGRAD Args: [ 1] = O ObjectStack Calls=========== Called from: => __ERRRT_SBASE(0) Called from: => TBAR:ERROR(170) Called from: source\rtl\tobject.prg => (b)HBOBJECT(105) Called from: => TBAR:MSGNOTFOUND(0) Called from: => TBAR:_BCLRGRAD(164) Called from: .\CASHVER3.PRG => SETWINDOWS(2969) Called from: .\CASHVER3.PRG => MSCREEN2(698)[code:t9syeg6p]
DEFINE BUTTONBAR oBar SIZE 69.75,38 _3DLOOK OF oWnd1 COLOR CLR CYAN
oBar:bClrGrad = { | lInvert | If( ! lInvert,;
{ { 0.50,16054371, 8388608 },;
{ 0.50, 8388608, 16054371 } },;
{ { 0.50, 8388608, 16054371 },;
{ 0.50, 16054371, 8388608 } } ) }
oBar:nClrText = nRGB( 255, 255, 255 )
[/code:t9syeg6p] |
gradient oBar | Harvey,Are you using FWH standard Class TBar ?Before assigning bClrGrad, please do:MsgInfo( oBar:ClassName() )and tell us what name you get, thanks |
gradient oBar | Hello,maybe i can help youhere is a complete working sample just for a quick answer.It is the basic-structure of the bar-tools.[img:1s5zwiys]http://www.pflegeplus.com/pictures/gradient60.jpg[/img:1s5zwiys][code:1s5zwiys]
#include "FiveWin.ch"
#include "xBrowse.ch"
#include "Slider.ch"
static oWnd
FUNCTION Main()
local oBar, oBtn1
SetBalloon( .T. ) // Balloon shape required for tooltips
oProgFont := TFont():New("Arial", ,-14,.F.,.F. , , , ,.F. )
DEFINE WINDOW oWnd TITLE "Gradient-Selection for" MDI MENU TMenu():New()
DEFINE BUTTONBAR oBar OF oWnd SIZE 80, 80 2007 RIGHT
// Copy and Past from the tools
// --------------------------------------
oBar:bClrGrad := { | lInvert | If( ! lInvert, ;
{ { 0.50,8388608,16777215 },;
{ 0.50,16777215,8388608 } },;
{ { 0.50,128,16777215 },;
{ 0.50,16777215,128 } } ) }
oBar:nClrText := 16777215
DEFINE BUTTON oBtn1 OF oBar ACTION ( Tools(oWnd,oBar,oBtn1) ) ;
RESOURCE "magic" PROMPT "Bar-Selection" TOOLTIP "Bar-Select"
SET MESSAGE OF oWnd TO "Testing the ButtonBar 2007 Office look" ;
CENTERED CLOCK KEYBOARD 2007
ACTIVATE WINDOW oWnd MAXIMIZED ;
ON PAINT gradpaint1( hDC, oWnd ) ;
VALID MsgYesNo( "Do you want to end?" )
RETURN NIL
//----------------- DIALOG ( MDI ) ------------------------------------//
FUNCTION Tools(oWnd,oBar)
LOCAL oDlg, oBar1, oBtn10
DEFINE DIALOG oDlg RESOURCE "Tools" OF oWnd TITLE "Gradient-Color-Selection" FONT oProgFont
// ----------- Your fields
// You have to call the BUTTONBAR at INIT
REDEFINE BUTTONBMP oBtn10 ID 10 OF oDlg ;
ACTION ( oDlg:End() ) ;
BITMAP "Quit" PROMPT " Exit" TEXTRIGHT
oBtn10:cToolTip = { "Close" + CRLF + ;
"the Dialog","Gradient-Test", 1, CLR_BLACK, 14089979 }
ACTIVATE DIALOG oDlg CENTERED NOWAIT ;
ON PAINT gradpaint2( hDC, oDlg ) ;
ON INIT NEW_DLGBAR(oDlg)
RETURN NIL
// -----------------------------------------------
static func gradpaint1( hDC, oWnd )
local aGrad := { { 0.50, 8388608, 16054371 } }
GradientFill( hDC, 0, 0, oWnd:nHeight, oWnd:nWidth, aGrad, .F. )
RETURN NIL
// -----------------------------------------------
static func gradpaint2( hDC, oDlg )
local aGrad1 := { { 0.50, 16054371, 8388608 } }
GradientFill( hDC, 0, 0, oDlg:nHeight, oDlg:nWidth, aGrad1, .F. )
RETURN NIL
// ------- TEST - BAR --------------------------
FUNCTION NEW_DLGBAR(oDlg)
LOCAL oBar1
DEFINE BUTTONBAR oBar1 OF oDlg SIZE 80, 80 2007 RIGHT
// Copy and Past from the tools
// --------------------------------------
oBar1:bClrGrad := { | lInvert | If( ! lInvert, ;
{ { 0.50,128,16777215 },;
{ 0.50,16777215,128 } },;
{ { 0.50,128,16777215 },;
{ 0.50,16777215,128 } } ) }
oBar1:nClrText := 16777215
DEFINE BUTTON OF oBar1 ACTION MsgInfo( "Attach" ) ;
RESOURCE "attach" PROMPT "Attach" TOOLTIP "Attach"
DEFINE BUTTON OF oBar1 ACTION MsgInfo( "calendar" ) ;
RESOURCE "calendar" PROMPT "Calendar" TOOLTIP "Calendar"
DEFINE BUTTON OF oBar1 ACTION MsgInfo( "Clients" ) ;
RESOURCE "people" PROMPT "Clients" TOOLTIP "Clients"
DEFINE BUTTON OF oBar1 ACTION oDlg:End() ;
RESOURCE "quit" PROMPT "Exit" TOOLTIP "Exit"
RETURN( NIL )
// ------------- The RC-File ------------
#ifdef __FLAT__
1 24 "WindowsXP.Manifest"
#endif
#define DIALOG_2 2
#define DIALOG_1 1
attach BITMAP "attach.bmp"
calendar BITMAP "calendar.bmp"
people BITMAP "people.bmp"
print BITMAP "print.bmp"
magic BITMAP "magic.bmp"
exit BITMAP "exit.bmp"
floppy BITMAP "floppy.bmp"
open BITMAP "open.bmp"
quit BITMAP "quit.bmp"
help BITMAP "help.bmp"
info BITMAP "info.bmp"
colors BITMAP "colors.bmp"
fonts BITMAP "fonts.bmp"
info1 BITMAP "info1.bmp"
Tools DIALOG 4, 53, 409, 303
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "DBF-Structure"
FONT 10, "MS Sans Serif"
{
DEFPUSHBUTTON "Exit", 10, 282, 271, 68, 27
}
[/code:1s5zwiys]If you need the complete working-directory with EXE-file :<!-- m --><a class="postlink" href="http://www.pflegeplus.com/fw_downloads/TestBar.zip">http://www.pflegeplus.com/fw_downloads/TestBar.zip</a><!-- m -->Bar-Tools Download :<!-- m --><a class="postlink" href="http://www.pflegeplus.com/fw_downloads/Bargradient3.zip">http://www.pflegeplus.com/fw_downloads/Bargradient3.zip</a><!-- m -->Best RegardsUwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
gradient oBar | Antonio:[quote:3s8gil0s]
Before assigning bClrGrad, please do:
MsgInfo( oBar:ClassName() )
and tell us what name you get, thanks
[/quote:3s8gil0s]Answer >> tbarUwe: Thanks for the info. I'll be trying it before end of day. I'll let you know what happens. |
gradient oBar | Harvey,Could you check that you are using FWH 8.07 libraries and not a previous version ? thanks |
gradient oBar | Antonio:You asked for dates Dates of Libraries:fiveh, 7/4/08fivehc, 6/23/08fivehcm, 6/23/08fivehm, 7/04/08fivehmx, 7/04/08fivehx, 7/04/08Downloaded in 7/12/08 |
gradient oBar | Antonio:Uwe:I thought I was using FWH 807...No using 806Installed 807 and working fine.Thank you both for your help. |
gradient oBar | Harvey,ok, glad to know it is ok now <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
gradient on btnbmp | Can I create a gradient color on btnbmp button ?
Where I can download a gradient function for ppc ? |
gradient with bitmap transparent or text (urgent) | HI, i need an sample to put an gradient (degrade) gray in main window (mdi) and an transparente bitmap or with an text raised, someone has an sample??
very thanks |
gradient with bitmap transparent or text (urgent) | i need only an degrade in main windows... |
gradient with bitmap transparent or text (urgent) | [code:3s3vvxo6]#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd
DEFINE WINDOW oWnd MDI
ACTIVATE WINDOW oWnd;
ON PAINT GRADIENT( oWnd, hDC )
RETURN NIL
STATIC FUNCTION GRADIENT( oWnd, hDC )
LOCAL aRect := GETCLIENTRECT( oWnd:hWnd )
LOCAL nStep := ( aRect[ 3 ] - aRect[ 1 ] ) / 256
LOCAL oBrush
LOCAL i
aRect[ 3 ] = nStep
FOR i = 255 TO 0 STEP -1
DEFINE BRUSH oBrush;
COLOR RGB( i, i, i )
FILLRECT( hDC, aRect, oBrush:hBrush )
RELEASE BRUSH oBrush
aRect[ 1 ] += nStep
aRect[ 3 ] += nStep
NEXT
RETURN NIL[/code:3s3vvxo6]
EMG |
gradient with bitmap transparent or text (urgent) | [code:2dh7wqov]#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, hBmp, oFnt
DEFINE WINDOW oWnd MDI
hBmp = READBITMAP( 0, "\FWH\BITMAPS\INSTALL.BMP" )
DEFINE FONT oFnt NAME "Arial" SIZE 0, -20
ACTIVATE WINDOW oWnd;
ON PAINT ( GRADIENT( oWnd, hDC ),;
IF( hBmp != 0, DRAWMASKED( hDC, hBmp, 200, 200 ), ),;
oWnd:oWndClient:Say( 20, 10, "This is a test", CLR_HRED, , oFnt, , .T. ) )
IF hBmp != 0; DELETEOBJECT( hBmp ); ENDIF
RELEASE FONT oFnt
RETURN NIL
STATIC FUNCTION GRADIENT( oWnd, hDC )
LOCAL aRect := GETCLIENTRECT( oWnd:hWnd )
LOCAL nStep := ( aRect[ 3 ] - aRect[ 1 ] ) / 256
LOCAL oBrush
LOCAL i
aRect[ 3 ] = nStep
FOR i = 255 TO 0 STEP -1
DEFINE BRUSH oBrush;
COLOR RGB( i, i, i )
FILLRECT( hDC, aRect, oBrush:hBrush )
RELEASE BRUSH oBrush
aRect[ 1 ] += nStep
aRect[ 3 ] += nStep
NEXT
RETURN NIL[/code:2dh7wqov]
EMG |
gradient with bitmap transparent or text (urgent) | works fine, very thanks Enrico. |
gradient with bitmap transparent or text (urgent) | Hi Enrico
Some more stress on you <!-- s:( --><img src="{SMILIES_PATH}/icon_sad.gif" alt=":(" title="Sad" /><!-- s:( -->
It was an long pending un-resolved problem <!-- s:? --><img src="{SMILIES_PATH}/icon_confused.gif" alt=":?" title="Confused" /><!-- s:? -->
On the Gradient Dialogs, the Checkboxes or Radiobuttons are not painted
transparent in both themed and non-themed.
Can you please find out a solution for this.
I am enclosing the modified program here for your solution.
[code:p98e6f72]
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oDlg, hBmp, oFnt, oRadio, oCheck, nValue := 1, lCheck := .F., oCheck1, lCheck1 := .F., oGet, cGet := SPACE(50)
DEFINE DIALOG oDlg SIZE 250, 250 TRANSPARENT
hBmp = READBITMAP( 0, "\FWH\BITMAPS\INSTALL.BMP" )
DEFINE FONT oFnt NAME "Arial" SIZE 0, -20
@ 1.75,0 RADIO oRadio VAR nValue ITEMS "Radio&1 not OK", "&Rado&2 not OK" OF oDlg SIZE 60, 12
@ 1.65,09 CHECKBOX oCheck VAR lCheck PROMPT "CheckBox&1 not OK" OF oDlg SIZE 80,12
@ 2.50,09 CHECKBOX oCheck1 VAR lCheck1 PROMPT "CheckBox&2 not OK" OF oDlg SIZE 80,12
ACTIVATE DIALOG oDlg CENTERED ;
ON PAINT ( GRADIENT( oDlg, hDC ),;
IF( hBmp != 0, DRAWMASKED( hDC, hBmp, 65, 65 ), ),; //,;
oDlg:Say( 1, 1, "This Say is OK", CLR_HRED, , oFnt, , .T. ), SysRefresh() )
IF hBmp != 0; DELETEOBJECT( hBmp ); ENDIF
RELEASE FONT oFnt
RETURN NIL
STATIC FUNCTION GRADIENT( oDlg, hDC )
LOCAL aRect := GETCLIENTRECT( oDlg:hWnd )
LOCAL nStep := ( aRect[ 3 ] - aRect[ 1 ] ) / 256
LOCAL oBrush
LOCAL i
aRect[ 3 ] = nStep
FOR i = 255 TO 0 STEP -1
DEFINE BRUSH oBrush;
COLOR RGB( i, i, i )
FILLRECT( hDC, aRect, oBrush:hBrush )
RELEASE BRUSH oBrush
aRect[ 1 ] += nStep
aRect[ 3 ] += nStep
NEXT
RETURN NIL
[/code:p98e6f72]
Regards to you
- Ramesh Babu P |
gradient with bitmap transparent or text (urgent) | Sorry, you have to ask Antonio for this.
EMG |
gradient with bitmap transparent or text (urgent) | Ramesh,
Its not easy to implement it. The controls paint themselves, but when using themes we use a themes API function to copy the parent background image, so they look fine.
The problem is that such API function does not work with the gradient, as it is not a themed gradient.
Probably there may be a solution, but we have not found it yet. |
gradient with bitmap transparent or text (urgent) | Fernando Mancera,
viaopen button support paint disabled button as the dialog background color?
for example:
redefine viaopenbutton obtton id 101 of dialog when .f.
this hide the obutton .
Regards
Shuming Wang |
gradient with bitmap transparent or text (urgent) | adlgclr:={255,255,255}
bTColor := { |oBtn| If( ! oBtn:lActive, CLR_HGRAY, ;
If( oBtn:lMouseOver, CLR_HBLUE, ;
If( oBtn:lPressed, CLR_HGREEN, CLR_BLACK ) ) ) }
bBColor := { |oBtn| If( oBtn:lActive, rgb(adlgclr[1],adlgclr[2],adlgclr[3]), CLR_WHITE) }
REDEFINE SBUTTON ;
ID 101 ;
PROMPT "basic set" ;
OF oxerpdlg1 ;
RESOURCE "plan08" ;
COLORS bTColor,bBColor ;
TEXT ON_BOTTOM ;
NOBOX ;
ACTION plan11();
WHEN ASCAN(afunctions,"plan11")>0
now tsbutton when .f., it paint color gray ,not as the dialog background color, I want the dialog background color to 'hide' the defined tsbutton include text and bitmap.
Shuming Wang |
gradiente en fila seleccionada en xbrowse | Hola,
¿ Es posible poner algo que no sea un color sólido para marcar la fila seleccionada en un xbrowse ? ¿ Se puede hacer un gradiente como el que hace Windows 7 en el explorador de archivos ?
Saludos, |
gradiente en fila seleccionada en xbrowse | It is possible to have different kinds of backgrounds in XBrowse cells other than solid colors.
1. use oCol:oBrush. oBrush can be a brush object or a codeblock.
2. Can assign bitmaps to columns and use oCol:lBmpStretch := .t. to stretch the bitmap to fill the cell area.
Example of Gradient cells can be seen at
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=17545">viewtopic.php?f=3&t=17545</a><!-- l --> |
gradiente en fila seleccionada en xbrowse | Thanks for yor kind answerd. It's just what I was looking for.
Regards, |
gradiente en fila seleccionada en xbrowse | José Luis,
Next FWH 9.12 will provide it as a standard xbrowse feature <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
If the second color in the color pair returned by bClrStd, bClrSel, bClrSelFocus of the browse object of column object is an array of gradient colors, the row or cell will be painted with that gradient colors
El próximo FWH 9.12 lo ofrecerá como una capacidad estandard propia del xbrowse <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Si el segundo color en el par de colores devuelto por los datos bClrStd, bClrSel, bClrSelFocus es un array de degradados de colores, la fila o la celda se pintará con esos colores degradados |
gradiente en fila seleccionada en xbrowse | Antonio,
Yo uso una versión de xbrowse modificada que permite ajustar automáticamente el ancho de las columnas, es una versión vieja pero que funciona perfectamente. Modificando un poco la clase puedo conseguir ese aspecto que me interesa, y no se si el xbrowse que viene con FWH hace este ajuste automático.
Saludos,
José Luis |
gradiente en fila seleccionada en xbrowse | José Luis,
Si nos proporcionas un ejemplo de ajuste automatico para probarlo aqui, podemos comentarte que tal funciona.
O si deseas compartir tus modificaciones con otros usuarios aqui en el foro, te estaremos muy agradecidos todos y asi podremos ir mejorando xbrowse de acuerdo a las necesidades de todos <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
gradiente en fila seleccionada en xbrowse | José Luis,
El código fuente de la función XBrowse() de FWH, usada tambien desde el comando XBROWSER, es un muy buen ejemplo de como ajustar las dimensiones del dialogo y del xbrowse contenido. |
gradiente en fila seleccionada en xbrowse | Antonio,
ya que estás puesto lo suyo sería que se pudiera simular el efecto nativo de Windows7 tal como aparece en la imagen. Es hacerle un recuadro a la fila activa y el degradado al pintarla.
Saludos,
[img:36vjeptk]http://www.avemundi.com/wordpress/wp-content/2009-12-04_085356.png[/img:36vjeptk] |
gradiente en fila seleccionada en xbrowse | Jose Luis,
Aqui tienes un ejemplo basado en el de Rao <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
[img:4x0kquwm]http://img200.imageshack.us/img200/4688/66973403.jpg[/img:4x0kquwm]
[code=fw:4x0kquwm]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'fivewin.ch'</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'xbrowse.ch'</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> oDlg, oBrw, oFont<br /> <span style="color: #00C800;">local</span> nRecSel<br /><br /> USE CUSTOMER <span style="color: #0000ff;">ALIAS</span> CUST<br /> nRecSel := CUST-><span style="color: #000000;">(</span> RecNo<span style="color: #000000;">(</span><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;">'Tahoma'</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-14</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">640</span>,<span style="color: #000000;">440</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">'XBrowse Gradient Rows'</span><br /><br /> @ <span style="color: #000000;">10</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">XBROWSE</span> oBrw <span style="color: #0000ff;">OF</span> oDlg ;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">300</span>,<span style="color: #000000;">200</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">AUTOCOLS</span> <span style="color: #0000ff;">ALIAS</span> <span style="color: #ff0000;">'CUST'</span> BACKGROUND <span style="color: #ff0000;">""</span><br /> <br /> WITH OBJECT oBrw<br /> :<span style="color: #000000;">bChange</span> := <span style="color: #000000;">{</span> || nRecSel := oBrw:<span style="color: #000000;">BookMark</span> <span style="color: #000000;">}</span><br /> :<span style="color: #000000;">nRowDividerStyle</span> := LINESTYLE_NOLINES<br /> :<span style="color: #000000;">nColDividerStyle</span> := LINESTYLE_NOLINES<br /> :<span style="color: #000000;">nMarqueeStyle</span> := MARQSTYLE_HIGHLROW<br /> END<br /><br /> AEval<span style="color: #000000;">(</span> oBrw:<span style="color: #000000;">aCols</span>, <span style="color: #000000;">{</span> |oCol| ;<br /> oCol:<span style="color: #000000;">bPaintText</span> := <span style="color: #000000;">{</span> |oCol, hDC, cData, aRect | ;<br /> PaintCol<span style="color: #000000;">(</span> oCol, hDC, cData, aRect, nRecSel <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> ;<br /> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /><br /> oBrw:<span style="color: #000000;">CreateFromCode</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;">CENTERED</span><br /><br /> CLOSE CUST<br /> <span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">static</span> <span style="color: #00C800;">function</span> PaintCol<span style="color: #000000;">(</span> oCol, hDC, cData, aRect, nRecSel <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> nRecSel == CUST-><span style="color: #000000;">(</span> RecNo<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> GradientFill<span style="color: #000000;">(</span> hDC, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">2</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">2</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">3</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">1</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">4</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">5</span>,;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">1</span>, RGB<span style="color: #000000;">(</span> <span style="color: #000000;">220</span>, <span style="color: #000000;">235</span>, <span style="color: #000000;">252</span> <span style="color: #000000;">)</span>, RGB<span style="color: #000000;">(</span> <span style="color: #000000;">193</span>, <span style="color: #000000;">219</span>, <span style="color: #000000;">252</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span>, .T. <span style="color: #000000;">)</span><br /> SetBkMode<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><br /> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">2</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">1</span>, WndWidth<span style="color: #000000;">(</span> oCol:<span style="color: #000000;">oBrw</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> - <span style="color: #000000;">22</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">1</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">235</span>, <span style="color: #000000;">244</span>, <span style="color: #000000;">253</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> <br /> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">2</span>, WndWidth<span style="color: #000000;">(</span> oCol:<span style="color: #000000;">oBrw</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> - <span style="color: #000000;">21</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">125</span>, <span style="color: #000000;">162</span>, <span style="color: #000000;">206</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">endif</span><br /><br /> SetTextColor<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /> DrawTextEx<span style="color: #000000;">(</span> hDC, cData, aRect, oCol:<span style="color: #000000;">nDataStyle</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:4x0kquwm] |
gradiente en fila seleccionada en xbrowse | Queda realmente bonito !!!
Saludos, |
gradiente en fila seleccionada en xbrowse | FiveWin nos permite hacer lo que queramos <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Su grado de libertad y de posibilidades es muy grande <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
gradiente en fila seleccionada en xbrowse | Antonio
He compilado el ejemplo y me da error que no encuentra la funcion [color=#4000FF:33s27acq]RoundBox[/color:33s27acq], en que libreria esta.
Gracias por la ayuda
Saludos
adhemar |
gradiente en fila seleccionada en xbrowse | Adhemar:
Omitiendo esas llamadas a RoundBox() tambien funciona el degradado. Pruébalo.
Lo único es que no llena la col de la flechita.
Saludos. |
gradiente en fila seleccionada en xbrowse | Adhemar,
Aqui está el código de la función RoundBox():
[code=fw:19rm489m]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#pragma</span> BEGINDUMP<br /><br /><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <hbapi.h><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> ROUNDBOX <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br /> HDC hDC = <span style="color: #000000;">(</span> HDC <span style="color: #000000;">)</span> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> HBRUSH hBrush = <span style="color: #000000;">(</span> HBRUSH <span style="color: #000000;">)</span> GetStockObject<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>;<br /> HBRUSH hOldBrush = <span style="color: #000000;">(</span> HBRUSH <span style="color: #000000;">)</span> SelectObject<span style="color: #000000;">(</span> hDC, hBrush <span style="color: #000000;">)</span>;<br /> HPEN hPen, hOldPen ; <br /><br /> <span style="color: #00C800;">if</span><span style="color: #000000;">(</span> hb_pcount<span style="color: #000000;">(</span><span style="color: #000000;">)</span> > <span style="color: #000000;">8</span> <span style="color: #000000;">)</span><br /> hPen = CreatePen<span style="color: #000000;">(</span> PS_SOLID, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">9</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">(</span> COLORREF <span style="color: #000000;">)</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> <span style="color: #00C800;">else</span><br /> hPen = CreatePen<span style="color: #000000;">(</span> PS_SOLID, <span style="color: #000000;">1</span>, <span style="color: #000000;">(</span> COLORREF <span style="color: #000000;">)</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> <br /> hOldPen = <span style="color: #000000;">(</span> HPEN <span style="color: #000000;">)</span> SelectObject<span style="color: #000000;">(</span> hDC, hPen <span style="color: #000000;">)</span>;<br /> hb_retl<span style="color: #000000;">(</span> RoundRect<span style="color: #000000;">(</span> hDC ,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span>,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">6</span> <span style="color: #000000;">)</span>,<br /> hb_parni<span style="color: #000000;">(</span> <span style="color: #000000;">7</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /><br /> SelectObject<span style="color: #000000;">(</span> hDC, hOldBrush <span style="color: #000000;">)</span>;<br /> DeleteObject<span style="color: #000000;">(</span> hBrush <span style="color: #000000;">)</span>;<br /> SelectObject<span style="color: #000000;">(</span> hDC, hOldPen <span style="color: #000000;">)</span>;<br /> DeleteObject<span style="color: #000000;">(</span> hPen <span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span><br /><br /><span style="color: #00D7D7;">#pragma</span> ENDDUMP<br /> </div>[/code:19rm489m] |
gradiente en fila seleccionada en xbrowse | Gracias Antonio
Ahora me da un error en [color=#4000FF:1xen9trs]oBrw:Bookmark[/color:1xen9trs]
Tengo FWH 9.04 y no se porque, he visto en el foro que lo usan con versiones anteriores.
Gracias una vez mas por la ayuda
Saludos
Adhemar |
gradiente en fila seleccionada en xbrowse | Adhemar,
Esta versión es mas simple y no necesita los bookmarks:
[code=fw:3lnpnwft]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'fivewin.ch'</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'xbrowse.ch'</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> oDlg, oBrw, oFont<br /><br /> USE CUSTOMER <span style="color: #0000ff;">ALIAS</span> CUST<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;">'Tahoma'</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-14</span><br /> <br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">640</span>,<span style="color: #000000;">440</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">'XBrowse Gradient Rows'</span><br /><br /> @ <span style="color: #000000;">10</span>, <span style="color: #000000;">10</span> <span style="color: #0000ff;">XBROWSE</span> oBrw <span style="color: #0000ff;">OF</span> oDlg ;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">300</span>, <span style="color: #000000;">200</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">AUTOCOLS</span> <span style="color: #0000ff;">ALIAS</span> <span style="color: #ff0000;">'CUST'</span> BACKGROUND <span style="color: #ff0000;">""</span><br /> <br /> oBrw:<span style="color: #000000;">nRowDividerStyle</span> = LINESTYLE_NOLINES<br /> oBrw:<span style="color: #000000;">nColDividerStyle</span> = LINESTYLE_NOLINES<br /> oBrw:<span style="color: #000000;">nMarqueeStyle</span> = MARQSTYLE_HIGHLROW<br /><br /> AEval<span style="color: #000000;">(</span> oBrw:<span style="color: #000000;">aCols</span>, <span style="color: #000000;">{</span> | oCol | oCol:<span style="color: #000000;">bPaintText</span> := <span style="color: #000000;">{</span> | oCol, hDC, cData, aRect | ;<br /> PaintCol<span style="color: #000000;">(</span> oCol, hDC, cData, aRect <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span> <span style="color: #000000;">)</span><br /><br /> oBrw:<span style="color: #000000;">CreateFromCode</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;">CENTERED</span><br /><br /> oFont:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">static</span> <span style="color: #00C800;">function</span> PaintCol<span style="color: #000000;">(</span> oCol, hDC, cData, aRect <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">if</span> oCol:<span style="color: #000000;">oBrw</span>:<span style="color: #000000;">VGetPos</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> == Cust-><span style="color: #000000;">(</span> OrdKeyNo<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> GradientFill<span style="color: #000000;">(</span> hDC, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">2</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">2</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">3</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">1</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">4</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">5</span>,;<br /> <span style="color: #000000;">{</span> <span style="color: #000000;">{</span> <span style="color: #000000;">1</span>, RGB<span style="color: #000000;">(</span> <span style="color: #000000;">220</span>, <span style="color: #000000;">235</span>, <span style="color: #000000;">252</span> <span style="color: #000000;">)</span>, RGB<span style="color: #000000;">(</span> <span style="color: #000000;">193</span>, <span style="color: #000000;">219</span>, <span style="color: #000000;">252</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <span style="color: #000000;">}</span>, .T. <span style="color: #000000;">)</span><br /> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">2</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">1</span>, WndWidth<span style="color: #000000;">(</span> oCol:<span style="color: #000000;">oBrw</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> - <span style="color: #000000;">22</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">1</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">235</span>, <span style="color: #000000;">244</span>, <span style="color: #000000;">253</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> <br /> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">1</span> <span style="color: #000000;">]</span> - <span style="color: #000000;">2</span>, WndWidth<span style="color: #000000;">(</span> oCol:<span style="color: #000000;">oBrw</span>:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">)</span> - <span style="color: #000000;">21</span>, aRect<span style="color: #000000;">[</span> <span style="color: #000000;">3</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">125</span>, <span style="color: #000000;">162</span>, <span style="color: #000000;">206</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">endif</span><br /><br /> SetTextColor<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /> DrawTextEx<span style="color: #000000;">(</span> hDC, cData, aRect, oCol:<span style="color: #000000;">nDataStyle</span> <span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:3lnpnwft] |
gradiente en fila seleccionada en xbrowse | Gracias Antonio
Ahora da un error en [color=#0000FF:31ddbm0l]BACKGROUND ""[/color:31ddbm0l], lo elimino y funciona, pero cuando avanza no pone en blanco el anterior
no se si sera por esto.
Gracias de nuevo
Saludos
Adhemar |
gradiente en fila seleccionada en xbrowse | Adhemar,
Pruebalo asi:
[code=fw:3pjd5tv9]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> @ <span style="color: #000000;">10</span>, <span style="color: #000000;">10</span> <span style="color: #0000ff;">XBROWSE</span> oBrw <span style="color: #0000ff;">OF</span> oDlg ;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">300</span>, <span style="color: #000000;">200</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">AUTOCOLS</span> <span style="color: #0000ff;">ALIAS</span> <span style="color: #ff0000;">'CUST'</span> <br /> <br /> oBrw:<span style="color: #000000;">SetColor</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"N/W"</span> <span style="color: #000000;">)</span> <br /> oBrw:<span style="color: #000000;">lTransparent</span> = .T.<br /><br /> ...<br /> </div>[/code:3pjd5tv9] |
gradiente en fila seleccionada en xbrowse | Gracias Antonio
solo con oBrw:lTransparent = .T. Funcionó perfecto
Lo aplique a un xBrowse que muestra un array colocando
if oCol:oBrw:VGetPos() == oBrw:nArrayAt
Funciona, pero cuando pasa por una linea vacia no muestra en gradient
Gracias una vez mas por la ayuda, se ve muy bonito
Saludos
Adhemar |
gradiente en fila seleccionada en xbrowse | Adhemar,
Bien, me alegro de que esté funcionando <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Cuando dices una línea vacia, te refieres a un elemento del array que está vacio "" ? |
gradiente en fila seleccionada en xbrowse | Asi es, un elemento vacio ""
Lo he solucionado aumentandole el caracter 255 al final en el momento de cargar la tabla.
Gracias distinguido por su ayuda valiosa
Saludos
Adhemar |
gradiente en fila seleccionada en xbrowse | Bien! <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
gradiente en fila seleccionada en xbrowse | Me pregunto que pasa cuando en la fila hay un bitmap. No se si con esta manera de pintar el degradado cuando haya un bitmap en la fila el fondo del bitmap aparecerá degradado. Si alguien lo puede probar y confirmar que funciona bien lo agradecería.
Saludos, |
gradiente en fila seleccionada en xbrowse | José Luis,
Si, para mostrar los bitmaps habría que hacerlo desde la función PaintCol() |
gradiente en fila seleccionada en xbrowse | Antonio, una consulta
en le código de roundbox, hDC no seria una variable tipo long en lugar de una integer?, es que casi siempre que creo funciones wrapper, y estas necesitan
hDC lo pongo a long?
[code=fw:vg6av6n3]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> ROUNDBOX <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br /> HDC hDC = <span style="color: #000000;">(</span> HDC <span style="color: #000000;">)</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>; <span style="color: #B900B9;">//<-----------------hbparnl en lugar de hbparni</span><br /> HBRUSH hBrush = <span style="color: #000000;">(</span> HBRUSH <span style="color: #000000;">)</span> GetStockObject<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>;<br /> HBRUSH hOldBrush = <span style="color: #000000;">(</span> HBRUSH <span style="color: #000000;">)</span> SelectObject<span style="color: #000000;">(</span> hDC, hBrush <span style="color: #000000;">)</span>;<br /> </div>[/code:vg6av6n3] |
gradiente en fila seleccionada en xbrowse | Carlos,
Si, es preferible usar un long en vez de int <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Lo que ocurre es que en 32 bits ese valor también puede ser admisible pues admite un rango de valores muy grande. |
gradiente en fila seleccionada en xbrowse | [quote="José Luis Sánchez":181lyf4t]Me pregunto que pasa cuando en la fila hay un bitmap. No se si con esta manera de pintar el degradado cuando haya un bitmap en la fila el fondo del bitmap aparecerá degradado. Si alguien lo puede probar y confirmar que funciona bien lo agradecería.
Saludos,[/quote:181lyf4t]
Hola José Luis. ¿Lograste resolverlo? Estoy en eso pero no lo consigo. Una ayudita no me vendría mal.
Saludos |
gradiente en fila seleccionada en xbrowse | Hola,
Retomo el tema del gradiente para los que tenemos versiones antiguas de FWH. Si en vez de el gradiente nos contentamos con pintar los rebordes de la fila seleccionada con las dos lineas, la de fuera azul y la de dentro blanca, creo que se solucionarían los problemas de pintado cuando la última fila no tiene datos ( cData está vacio ). Creo que esto se podría hacer en el método Paint(), igual que se pinta el selector de fila ( el triangulito ), cuando se ha terminado de pintar todas las columnas hacer los dos rebordes. Estoy mirando cómo hacer esto pero no doy con ello, si alguien me pudiera ayudar lo agradecería.
Saludos,
José Luis |
gradiente en fila seleccionada en xbrowse | Hola,
Ya he encontrado la manera de hacerlo. En el métido DrawLine() de XBrowse buscar las líneas:
[code=fw:nvzn7arp]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">if</span> ::<span style="color: #000000;">lRecordSelector</span><br /> <span style="color: #00C800;">if</span> lSelected<br /> PalBmpDraw<span style="color: #000000;">(</span> hDC, nRow + <span style="color: #000000;">(</span> nHeight / <span style="color: #000000;">2</span> <span style="color: #000000;">)</span> - <span style="color: #000000;">8</span>, RECORDSELECTOR_WIDTH - <span style="color: #000000;">15</span>,;<br /> ::<span style="color: #000000;">hBmpRecSel</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">9</span>, <span style="color: #000000;">14</span>,, .t., ::<span style="color: #000000;">nRecSelColor</span> <span style="color: #000000;">)</span></div>[/code:nvzn7arp]
y añadir el pintado de los bordes de esta manera, y luego seguir con el else de no lSelected
[code=fw:nvzn7arp]<div class="fw" id="{CB}" style="font-family: monospace;"> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">2</span>, nRow , ::<span style="color: #000000;">BrwWidth</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>- <span style="color: #000000;">6</span>, nRow+::<span style="color: #000000;">nRowHeight</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">235</span>, <span style="color: #000000;">244</span>, <span style="color: #000000;">253</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><br /> RoundBox<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, nRow <span style="color: #000000;">-1</span>, ::<span style="color: #000000;">BrwWidth</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>- <span style="color: #000000;">5</span>, nRow+::<span style="color: #000000;">nRowHeight</span><span style="color: #000000;">+1</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">2</span>,;<br /> RGB<span style="color: #000000;">(</span> <span style="color: #000000;">125</span>, <span style="color: #000000;">162</span>, <span style="color: #000000;">206</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">else</span><br /> FillRect<span style="color: #000000;">(</span> hDC,;</div>[/code:nvzn7arp]
No es el gradiente, pero el efecto es bastante parecido y sin problemas de columnas vacias. Igual hay otra manera de hacerlo, o en versiones actuales de FWH ya funciona esto, pero yo salgo del paso con esto.
Cualquier aportación será bienvenida.
Saludos,
José Luis |
gradiente en fila seleccionada en xbrowse | Jose luis
Verifica este hilo [url:1zsfsgt6]http://forums.fivetechsupport.com/viewtopic.php?p=95709#p95709[/url:1zsfsgt6] |
gradiente en fila seleccionada en xbrowse | Hola,
Pues con la modificación que me has dicho se ve realmente bien. Y mira que le dí vueltas a como hacerlo pero ni pensé en poner un else ahí. Muchas gracias.
Saludos,
José Luis |
grafico bajo tdosprn... | alguien sabra como imprimir un grafico con la clase tdosprn?
es para una miniprinter epson de matriz de puntos y otra termica y pues estas si aceptan graficos, no quiero usar tprinter por cuestion de papel en forma continua, que no lo he podido configurar bajo tprinter
gracias,
Paco |
graficos estilos tortas. | hola.
necesito generar e imprimir (sin excel) graficos tipo torta.
Que puedo usar?
gracias. |
graficos estilos tortas. | Puedes usar la clase TGraph
Ejemplo:
[code=fw:y25dtim6]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"FiveWin.Ch"</span><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"TGraph.Ch"</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"GRAFICA"</span> <span style="color: #0000ff;">OF</span> oWnd<br /> oDlg:<span style="color: #000000;">lHelpIcon</span> := .f.<br /> <span style="color: #0000ff;">REDEFINE</span> GRAPH oGraf <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ID</span> <span style="color: #000000;">111</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Ventas por rubros"</span> 3D XGRID;<br /> YGRID XVALUES YVALUES LEGENDS TYPE <span style="color: #000000;">4</span><br /> oGraf:<span style="color: #000000;">cTitle</span> := <span style="color: #ff0000;">"Ventas x rubros"</span> <br /> oGraf:<span style="color: #000000;">cSubTit</span>:= <span style="color: #ff0000;">"En pesos"</span><br /> oGraf:<span style="color: #000000;">cTitX</span> := <span style="color: #ff0000;">"Valores"</span><br /> oGraf:<span style="color: #000000;">cTitY</span> := <span style="color: #ff0000;">"Rubro"</span><br /> oGraf:<span style="color: #000000;">lPopUp</span> := .T.<br /> <span style="color: #00C800;">FOR</span> j := <span style="color: #000000;">1</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">10</span><br /> aRubro := <span style="color: #000000;">{</span>j<span style="color: #000000;">}</span><br /> oGraf:<span style="color: #000000;">AddSerie</span><span style="color: #000000;">(</span>aRubro,<span style="color: #ff0000;">"Rubro "</span>+STR<span style="color: #000000;">(</span>j,<span style="color: #000000;">2</span><span style="color: #000000;">)</span>, RGB<span style="color: #000000;">(</span>nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span>,nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span>,nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">NEXT</span> j<br /> oGraf:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBot2 <span style="color: #0000ff;">ID</span> <span style="color: #000000;">104</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ACTION</span> oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTER</span></div>[/code:y25dtim6]
En el recurso debes poner el Style en "TGRAPH" |
graficos estilos tortas. | Este control estoy viendo segun la clase que hay problemas al imprimir en los xp, y por las pruebas que hice los graficos no se ven bien (no en el aspecto) sino que en el tipo "pie" para mi "torta" no terminan de cerrar completamente el circulo.
Gracias.
[quote="cmsoft":2gbr3m39]Puedes usar la clase TGraph
Ejemplo:
[code=fw:2gbr3m39]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"FiveWin.Ch"</span><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"TGraph.Ch"</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"GRAFICA"</span> <span style="color: #0000ff;">OF</span> oWnd<br /> oDlg:<span style="color: #000000;">lHelpIcon</span> := .f.<br /> <span style="color: #0000ff;">REDEFINE</span> GRAPH oGraf <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ID</span> <span style="color: #000000;">111</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Ventas por rubros"</span> 3D XGRID;<br /> YGRID XVALUES YVALUES LEGENDS TYPE <span style="color: #000000;">4</span><br /> oGraf:<span style="color: #000000;">cTitle</span> := <span style="color: #ff0000;">"Ventas x rubros"</span> <br /> oGraf:<span style="color: #000000;">cSubTit</span>:= <span style="color: #ff0000;">"En pesos"</span><br /> oGraf:<span style="color: #000000;">cTitX</span> := <span style="color: #ff0000;">"Valores"</span><br /> oGraf:<span style="color: #000000;">cTitY</span> := <span style="color: #ff0000;">"Rubro"</span><br /> oGraf:<span style="color: #000000;">lPopUp</span> := .T.<br /> <span style="color: #00C800;">FOR</span> j := <span style="color: #000000;">1</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">10</span><br /> aRubro := <span style="color: #000000;">{</span>j<span style="color: #000000;">}</span><br /> oGraf:<span style="color: #000000;">AddSerie</span><span style="color: #000000;">(</span>aRubro,<span style="color: #ff0000;">"Rubro "</span>+STR<span style="color: #000000;">(</span>j,<span style="color: #000000;">2</span><span style="color: #000000;">)</span>, RGB<span style="color: #000000;">(</span>nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span>,nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span>,nRandom<span style="color: #000000;">(</span><span style="color: #000000;">255</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">NEXT</span> j<br /> oGraf:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> oBot2 <span style="color: #0000ff;">ID</span> <span style="color: #000000;">104</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ACTION</span> oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTER</span></div>[/code:2gbr3m39]
En el recurso debes poner el Style en "TGRAPH"[/quote:2gbr3m39] |
graficos estilos tortas. | RMCHART sin lugar a dudas la mejor opción
Yo tengo un ejecutable que te saca la grafica en varios estilos a partir de un archivo de
texto si te interesa dejame tu correo y te lo envio.
Saludos |
graficos estilos tortas. | Vladimir, por favor poderia enviar-me também?
<!-- e --><a href="mailto:ubiratan@sgsistemas.com.br">ubiratan@sgsistemas.com.br</a><!-- e --> |
graficos estilos tortas. | Enviado
[quote="Vladimir Zorrilla":ldjcv4bd]RMCHART sin lugar a dudas la mejor opción
Yo tengo un ejecutable que te saca la grafica en varios estilos a partir de un archivo de
texto si te interesa dejame tu correo y te lo envio.
Saludos[/quote:ldjcv4bd] |
graficos estilos tortas. | Vladimir, eu não recebi...
Pode enviar-me?
<!-- e --><a href="mailto:ubiratan@sgsistemas.com.br">ubiratan@sgsistemas.com.br</a><!-- e --> |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.