topic
stringlengths
1
63
text
stringlengths
1
577k
Como convertir de CSV a DBF?
George,append from miarchivo.cvs delimited ","o el delimitador que elijas.
Como convertir de CSV a DBF?
Gracias William por tu sugerencia.Yo tenia pensado en crear la estructura del DBF a partir de la lectura del archivo y luego añadir la data como se hace el siguiente codigo. Sin embargo creo es mejor usar el APPEND ya que es super-rapido.George[quote:2cg71b19] include 'fivewin.ch' #include 'xbrowse.ch' function Main() local cBuf local aData, aHeaders cBuf := MemoRead( 'input.txt' ) // parse and make a multi dimentional array if cBuf[ -1 ] == 26 // check and remove Ctrl-Z cBuf := Left( cBuf, Len( cBuf ) - 1 ) endif if Right( cBuf, 2 ) != CRLF // pad with CRLF if needed, not to miss the last line cBuf += CRLF endif cBuf := StrTran( cBuf, CRLF, Chr( 10 ) ) aData := hb_aTokens( cBuf, Chr(10) ) AEval( aData, { |c,i| aData[ i ] := hb_aTokens( c, ';' ) } ) aHeaders := aData[ 1 ] aData := ADel( aData, 1 ) aSize( aData, Len( aData ) - 1 ) // Parsing is done // now view the data quickly in xbrowse before writing in DBF xBrowse( aData, ; // data to browse "Parsed Data as Array", ; // title .f., ; // no autosort { |oBrw| AEval( oBrw:aCols, { |o,i| o:cHeader := aHeaders[ i ] } ) } ; ) // codeblock above assigns header names // Extending the program to Write DBF WriteToDBF( 'INPUT.DBF', aData, aHeaders ) // Check the DBF USE INPUT XBrowse() return nil static function WriteToDBF( cDbf, aData, aHeaders ) local aStruct := {} local n, nLen := Len( aData ) AEval( aHeaders, ; { |c| AAdd( aStruct, ; { Upper( Left( Trim( c ), 10 ) ), 'C', 2, 0 } ); } ) // desirable to remove embedded chars not acceptable in fieldnames // and to check for duplicates // that logic is not included here for n := 1 to nLen AEval( aData[ n ], ; { |c,i| c := Trim( c ), ; aStruct[ i ][ 3 ] := Max( Len( c ), aStruct[ i ][ 3 ] ), ; aData[ n ][ i ] := c ; } ) next n dbCreate( cDbf, aStruct ) USE ( cDbf ) NEW ALIAS OUT EXCLUSIVE for n := 1 to nLen OUT->( dbAppend() ) AEval( aData[ n ], { |c,i| OUT->( FieldPut( i, c ) ) } ) next OUT->( dbCloseArea() ) return nil [/quote:2cg71b19]
Como convertir un Json a Hash? (SOLUCIONADO)
Hola a todos. Tengo este Json que recibo de un Api Rest [code=fw:ftn4p350]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span>: <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span></div>[/code:ftn4p350] Y estoy intentando encontrar sus valores, por lo que he probado convertirlo a Hash, pero no logro obtener ningun valor. He probado de esta forma: [code=fw:ftn4p350]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #0000ff;">TEXT</span> INTO cJs<br /><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span>: <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span><br />ENDTEXT<br /><br />cHs:=<span style="color: #000000;">&#123;</span>=><span style="color: #000000;">&#125;</span><br />hb_jsonDecode<span style="color: #000000;">&#40;</span>cJs,@cHs<span style="color: #000000;">&#41;</span><br />?  cHs<span style="color: #000000;">&#91;</span><span style="color: #ff0000;">'order'</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span><span style="color: #ff0000;">'id'</span><span style="color: #000000;">&#93;</span> <br /> </div>[/code:ftn4p350] Y me da: Error BASE/1132 Error de rango: acceso al array O bien: [code=fw:ftn4p350]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #0000ff;">TEXT</span> INTO cJs<br /><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span>: <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span><br />ENDTEXT<br /><br />cHs:=<span style="color: #000000;">&#123;</span>=><span style="color: #000000;">&#125;</span><br />hb_jsonDecode<span style="color: #000000;">&#40;</span>cJs,@cHs<span style="color: #000000;">&#41;</span><br /><span style="color: #0000ff;">xbrowse</span><span style="color: #000000;">&#40;</span> cHs <span style="color: #000000;">&#41;</span><br /> </div>[/code:ftn4p350] No obtengo nigun valor con xBrowse() Alguien me puede indicar como puedo tratar este JSon por favor? Saludos cordiales. Carlos
Como convertir un Json a Hash? (SOLUCIONADO)
Carlos: Prueba con hb_jsonDecode <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=34345#p203772">viewtopic.php?f=3&t=34345#p203772</a><!-- l -->
Como convertir un Json a Hash? (SOLUCIONADO)
Cesar, gracias por contestar, pero, tambien ya he usado hb_jsonDecode, pero acá me convierte el Json en una cadena con slashes \\ nada mas. Saludos
Como convertir un Json a Hash? (SOLUCIONADO)
Tal ves mi pregunta esta mal hecha. [code=fw:gq68gscj]<div class="fw" id="{CB}" style="font-family: monospace;"><br />cHs:=<span style="color: #000000;">&#123;</span>=><span style="color: #000000;">&#125;</span><br />hb_jsonDecode<span style="color: #000000;">&#40;</span>cJs,@cHs<span style="color: #000000;">&#41;</span><br />? ValType<span style="color: #000000;">&#40;</span> cHs <span style="color: #000000;">&#41;</span><br /> </div>[/code:gq68gscj] La función hb_jsonDecode() si me convierte el Json a Hash, ya que ValType(cHs) me devuelve "H", por lo que la pregunta sería, como hago ahora para obtener los datos del Hash generado? ya que cHs['order']['id'], me da Error de rango: acceso al array Saludos Carlos
Como convertir un Json a Hash? (SOLUCIONADO)
Carlos, mira a ver si asi lo ves más claro [code=fw:2lqr5orw]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><br /><span style="color: #00C800;">Function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> hJs<br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> cJs<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">TEXT</span> INTO cJs<br />&nbsp; &nbsp;<span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span> &nbsp; &nbsp;: <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp;ENDTEXT<br /><br />&nbsp; &nbsp;cJs := StrTran<span style="color: #000000;">&#40;</span> cJs, <span style="color: #ff0000;">'{"order": '</span>, <span style="color: #ff0000;">""</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;cJs := <span style="color: #0000ff;">Left</span><span style="color: #000000;">&#40;</span> cJs, Len<span style="color: #000000;">&#40;</span> cJs <span style="color: #000000;">&#41;</span> - <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;? cJs<br />&nbsp; &nbsp;hb_JsonDecode<span style="color: #000000;">&#40;</span> cJs, @hJs <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">XBrowse</span><span style="color: #000000;">&#40;</span> hJs <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br />&nbsp;</div>[/code:2lqr5orw]
Como convertir un Json a Hash? (SOLUCIONADO)
[quote="csincuir":ad2wzopb]Tal ves mi pregunta esta mal hecha. [code=fw:ad2wzopb]<div class="fw" id="{CB}" style="font-family: monospace;"><br />cHs:=<span style="color: #000000;">&#123;</span>=><span style="color: #000000;">&#125;</span><br />hb_jsonDecode<span style="color: #000000;">&#40;</span>cJs,@cHs<span style="color: #000000;">&#41;</span><br />? ValType<span style="color: #000000;">&#40;</span> cHs <span style="color: #000000;">&#41;</span><br /> </div>[/code:ad2wzopb] La función hb_jsonDecode() si me convierte el Json a Hash, ya que ValType(cHs) me devuelve "H", por lo que la pregunta sería, como hago ahora para obtener los datos del Hash generado? ya que cHs['order']['id'], me da Error de rango: acceso al array Saludos Carlos[/quote:ad2wzopb] Asi: [quote:ad2wzopb] ? hJs[ "razon_social" ] [/quote:ad2wzopb]
Como convertir un Json a Hash? (SOLUCIONADO)
Cristobal, eres un genio. Estas lineas: [code=fw:2jgytlip]<div class="fw" id="{CB}" style="font-family: monospace;"> <br />cJs := StrTran<span style="color: #000000;">&#40;</span> cJs, <span style="color: #ff0000;">'{"order": '</span>, <span style="color: #ff0000;">""</span> <span style="color: #000000;">&#41;</span><br />cJs := <span style="color: #0000ff;">Left</span><span style="color: #000000;">&#40;</span> cJs, Len<span style="color: #000000;">&#40;</span> cJs <span style="color: #000000;">&#41;</span> - <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br /> </div>[/code:2jgytlip] hicieron la magia: [code=fw:2jgytlip]<div class="fw" id="{CB}" style="font-family: monospace;"><br />   cJs := StrTran<span style="color: #000000;">&#40;</span> cJs, <span style="color: #ff0000;">'{"order": '</span>, <span style="color: #ff0000;">""</span> <span style="color: #000000;">&#41;</span><br />   cJs := <span style="color: #0000ff;">Left</span><span style="color: #000000;">&#40;</span> cJs, Len<span style="color: #000000;">&#40;</span> cJs <span style="color: #000000;">&#41;</span> - <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br />   <span style="color: #B900B9;">//? cJs</span><br />   hb_JsonDecode<span style="color: #000000;">&#40;</span> cJs, @hJs <span style="color: #000000;">&#41;</span><br /><br />  <span style="color: #B900B9;">//Aca obtengo ya los datos del Json</span><br />   ? hJs<span style="color: #000000;">&#91;</span><span style="color: #ff0000;">"id"</span><span style="color: #000000;">&#93;</span><br />   ? hJs<span style="color: #000000;">&#91;</span><span style="color: #ff0000;">"items"</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span><span style="color: #ff0000;">"sku"</span><span style="color: #000000;">&#93;</span><br /> </div>[/code:2jgytlip] Muchas gracias por tu ayuda. Saludos cordiales. Carlos.
Como convertir un Json a Hash? (SOLUCIONADO)
Carlos, también podría hacerse asi [code=fw:3obesbaf]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><br /><span style="color: #00C800;">Function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> hJs<br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> cJs<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">TEXT</span> INTO cJs<br />&nbsp; &nbsp;<span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span> &nbsp; &nbsp;: <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp;ENDTEXT<br /><span style="color: #B900B9;">/*<br />&nbsp; &nbsp;cJs := StrTran( cJs, '{"order": ', "" )<br />&nbsp; &nbsp;cJs := Left( cJs, Len( cJs ) - 2 )<br />&nbsp; &nbsp;? cJs<br />*/</span><br />&nbsp; &nbsp;hb_JsonDecode<span style="color: #000000;">&#40;</span> cJs, @hJs <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;? hJs<span style="color: #000000;">&#91;</span> <span style="color: #ff0000;">"order"</span> <span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span> <span style="color: #ff0000;">"razon_social"</span> <span style="color: #000000;">&#93;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">XBrowse</span><span style="color: #000000;">&#40;</span> hJs <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br />&nbsp;</div>[/code:3obesbaf]
Como convertir un Json a Hash? (SOLUCIONADO)
[quote="cnavarro":u903kgjv]Carlos, también podría hacerse asi [code=fw:u903kgjv]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><br /><span style="color: #00C800;">Function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #00C800;">local</span> hJs<br />   <span style="color: #00C800;">local</span> cJs<br /><br />   <span style="color: #0000ff;">TEXT</span> INTO cJs<br />   <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"order"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"id"</span>: <span style="color: #ff0000;">"196"</span>, <span style="color: #ff0000;">"nit"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan Valero"</span>, <span style="color: #ff0000;">"email"</span>: <span style="color: #ff0000;">"jhonatan.valero@omni.pro"</span>, <span style="color: #ff0000;">"items"</span>: <span style="color: #000000;">&#91;</span><span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">14</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">43.26</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"301"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Entrega por un tercero"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Aceros de Guatemala"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">13</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">40.17</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"302"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"sku"</span>: <span style="color: #ff0000;">"MUR0491"</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Block Tapado Liviano de 14 de 14x19x39cm (UN) 25kg/cmu00b2"</span>, <span style="color: #ff0000;">"price"</span>: <span style="color: #000000;">3.09</span>, <span style="color: #ff0000;">"seller"</span>: <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"source"</span>: <span style="color: #ff0000;">"Tiendas Super"</span>, <span style="color: #ff0000;">"quantity"</span>: <span style="color: #000000;">5</span>, <span style="color: #ff0000;">"entity_id"</span>: <span style="color: #ff0000;">"235"</span>, <span style="color: #ff0000;">"total_price"</span>: <span style="color: #000000;">15.45</span>, <span style="color: #ff0000;">"order_item_id"</span>: <span style="color: #ff0000;">"303"</span>, <span style="color: #ff0000;">"shipping_method"</span>: <span style="color: #ff0000;">"Retiro en tienda"</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#93;</span>, <span style="color: #ff0000;">"created_at"</span>: <span style="color: #ff0000;">"2022-10-20 22:09:00"</span>, <span style="color: #ff0000;">"customer_id"</span>: <span style="color: #ff0000;">"112"</span>, <span style="color: #ff0000;">"person_type"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"increment_id"</span>    : <span style="color: #ff0000;">"4000000196"</span>, <span style="color: #ff0000;">"legalAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Alta Verapaz"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 100"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chisec"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"razon_social"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"taxes_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"total_amount"</span>: <span style="color: #000000;">98.88</span>, <span style="color: #ff0000;">"payment_method"</span>: <span style="color: #ff0000;">"banktransfer"</span>, <span style="color: #ff0000;">"discount_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"shippingAddress"</span>: <span style="color: #000000;">&#123;</span><span style="color: #ff0000;">"city"</span>: <span style="color: #00C800;">null</span>, <span style="color: #ff0000;">"name"</span>: <span style="color: #ff0000;">"Jhonatan 2"</span>, <span style="color: #ff0000;">"region"</span>: <span style="color: #ff0000;">"Chimaltenango"</span>, <span style="color: #ff0000;">"street"</span>: <span style="color: #ff0000;">"Cll 102"</span>, <span style="color: #ff0000;">"country"</span>: <span style="color: #ff0000;">"GT"</span>, <span style="color: #ff0000;">"zip_code"</span>: <span style="color: #ff0000;">"16013"</span>, <span style="color: #ff0000;">"telephone"</span>: <span style="color: #ff0000;">"31264587"</span>, <span style="color: #ff0000;">"municipality"</span>: <span style="color: #ff0000;">"Chimaltenango"</span><span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"shipping_amount"</span>: <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"nombre_comercial"</span>: <span style="color: #ff0000;">"Mi empresa"</span>, <span style="color: #ff0000;">"nombre_propietario"</span>: <span style="color: #ff0000;">" "</span>, <span style="color: #ff0000;">"representante_legal"</span>: <span style="color: #ff0000;">" "</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#125;</span><br />   ENDTEXT<br /><span style="color: #B900B9;">/*<br />   cJs := StrTran( cJs, '{"order": ', "" )<br />   cJs := Left( cJs, Len( cJs ) - 2 )<br />   ? cJs<br />*/</span><br />   hb_JsonDecode<span style="color: #000000;">&#40;</span> cJs, @hJs <span style="color: #000000;">&#41;</span><br />   ? hJs<span style="color: #000000;">&#91;</span> <span style="color: #ff0000;">"order"</span> <span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span> <span style="color: #ff0000;">"razon_social"</span> <span style="color: #000000;">&#93;</span><br /><br />   <span style="color: #0000ff;">XBrowse</span><span style="color: #000000;">&#40;</span> hJs <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br /> </div>[/code:u903kgjv][/quote:u903kgjv] Cristobal, de esa forma lo estaba haciendo al inicio, pero como comentaba da Error BASE/1132 Error de rango: acceso al array, al intentar  hacer esto: ? hJs[ "order" ][ "razon_social" ] Y el XBrowse( hJs ) sale en blanco Pero usando estas dos lineas que me enviaste, todo funciona correctamente. [code=fw:u903kgjv]<div class="fw" id="{CB}" style="font-family: monospace;"><br />cJs := StrTran<span style="color: #000000;">&#40;</span> cJs, <span style="color: #ff0000;">'{"order": '</span>, <span style="color: #ff0000;">""</span> <span style="color: #000000;">&#41;</span><br />cJs := <span style="color: #0000ff;">Left</span><span style="color: #000000;">&#40;</span> cJs, Len<span style="color: #000000;">&#40;</span> cJs <span style="color: #000000;">&#41;</span> - <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:u903kgjv] Saludos cordiales. Carlos
Como crear Librerias
Estimados: quiero crear una libreria en xHarbour, supongamos para que me devuelva la suma de dos numeros. Como se hace para crearla? gracias.
Como crear Librerias
Gustavo, Creas la función, construyes el OBJ y luego usas TLib.exe (Borland) ó Lib.exe (Microsoft) para generar el fichero .LIB. Escribe TLib.exe y verás la descripción de cómo usarlo.
Como crear botones invisibles?
Hola FiveWinners. Alguien conoce el truco para generar botones invisibles? Es decir que exista en un dialogo, el area de un boton que sea sensible al mouse, pero que no se muestre la imagen del boton, claro debe tener forma de ajecutar una accion. Alguien conoce el truco? Saludos
Como crear botones invisibles?
Hola... Prueba lo siguiente: [code=fw:2gy3kqn9]<div class="fw" id="{CB}" style="font-family: monospace;"><br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BTNBMP</span> Btn2 <span style="color: #0000ff;">ID</span> <span style="color: #000000;">201</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">""</span> <span style="color: #0000ff;">LEFT</span> TRANSPARENT;<br />      <span style="color: #0000ff;">ACTION</span> TuAcction<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>;<br />      TOOLTIP <span style="color: #ff0000;">"Tu mensaje"</span><span style="color: #0000ff;">FONT</span> oFont1<br /> </div>[/code:2gy3kqn9] Saludos, Esteban.
Como crear botones invisibles?
Yo lo hago asi, saludos... <!-- s:shock: --><img src="{SMILIES_PATH}/icon_eek.gif" alt=":shock:" title="Shocked" /><!-- s:shock: --> REDEFINE BTNBMP aBtn[1] ID 200 OF oDlg ; action accion() aBtn[1]:lBorder := .f. aBtn[1]:lTransparent := .t.
Como crear de nuevo el menu principal
Hola a todos Hace tiempo pregunté como se podría quitar el menú de la ventana principal que se creaba con "MENU MenuPrin()" y me indicasteis que era: oVentPrinc:oMenu:End() Lo que funciona perfectamente ahora quisiera pintar de nuevo el menú y no se como hacerlo me podríais indicarme como se hace. Un saludo Carlos
Como crear de nuevo el menu principal
Ya lo he conseguido por si a alguien le sirve se hace: Si se genera con WINDOW oWnd MENU MenuPrin() Y se quita se puede volver a poner con: oWnd:SetMenu(MenuPrinc()) Un saludo Carlos
Como crear de nuevo el menu principal
Carlos, Asi es, gracias por compartirlo <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Como crear graficos usando ole en excel
Hola a todos y gracias anticipadas. He conseguido con OLE ,abrir un libro Excel, enviar datos, formatear celdas , etc… lo básico, pero ahora mi problema es que no soy capaz de codificar en mi programa los objetos y metodos de MS Excel, para que desde el mismo, se creen dos gráficos incrustados en otra hoja del libro referenciando, es decir, definir el tipo de gráfico, los rangos necesarios con las series de datos, etc... Me podríais ayudar si son tan amables con algún ejemplo. Si el gráfico fuese del tipo "radar" mucho mejor. Muchas gracias por todo. Ricardo Blanco. <!-- s:oops: --><img src="{SMILIES_PATH}/icon_redface.gif" alt=":oops:" title="Embarassed" /><!-- s:oops: -->
Como crear graficos usando ole en excel
Ricardo Blanco: Hola y bienvenido al foro Me pregunto si sería posible que nos podrías aportarar a la comunidad las funciones basicas para el manejo de Excel desde OLE <!-- s:oops: --><img src="{SMILIES_PATH}/icon_redface.gif" alt=":oops:" title="Embarassed" /><!-- s:oops: --> , ya que muchos como yo estamos probando las diferentes formas de exportar nuestros reportes o listados a Excel y si tienes experiencia en eso pues que mejor que aplicar tus conocimientos en esta area.. <!-- s8) --><img src="{SMILIES_PATH}/icon_cool.gif" alt="8)" title="Cool" /><!-- s8) --> <!-- s8) --><img src="{SMILIES_PATH}/icon_cool.gif" alt="8)" title="Cool" /><!-- s8) --> Saludos desde México-.. <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
Como crear graficos usando ole en excel
Hola Victor Manuel Creo que en este tema no puedo aportar más de lo que se ve por el foro. Todos mis conocimientos para programar OLE como interface con EXCEL los he adquirido mirando aquí. Mi mayor problema es interpretar los ejemplos en visual basic u otros lenguajes que veo en la ayuda de excel e internet y transcribirlos a la sintaxis de Harbour/fivewin, es por ello que no soy capaz de conseguir construir desde cero, es decir dandole todas sus propiedades, rangos, etc..., un gráfico incrustado en una hoja excel dando instrucciones a través de Ole desde mis aplicaciones. Por si te puede aportar algo,esto es un pequeño fragmento de código a modo de ejemplo de como accedo yo Excel con OLE : oExcel:=TOleAuto():New( "Excel.Application" ) oExcel:WorkBooks:Add() oSheet:= oExcel:Get( "ActiveSheet" ) oSheet:= oExcel:sheets:item(1) oSheet:name:='Radar' oSheet:= oExcel:sheets:item(2) oSheet:name:='Datos' oSheet:activate() oExcel:visible := .t. oExcel:Sheets( "Datos" ):Cells( 1, 1 ):Value := "AREA" oExcel:Sheets( "Datos" ):Cells( 3, 1 ):Value := "NOMBRE PILAR" oExcel:Sheets( "Datos" ):Cells( 2, 4 ):Value := "NOMBRE PERSONA" oExcel:Sheets( "Datos" ):Cells( 2, 6 ):Value := "ROL PERSONA" oExcel:Sheets( "Datos" ):Cells( 2, 7 ):Value := "COMPETENCIAS" oExcel:Sheets( "Datos" ):Cells( 2, 8 ):Value := "VAL. REQUER." oExcel:Sheets( "Datos" ):Cells( 2, 9 ):Value := "VAL. ACTUAL" *oSheet:Range("A:A"):Set("ColumnWidth",32) // AJUSTA TAMAÑO UN RANGO A UN VALOR oExcel:Sheets( "Datos" ):Cells( 2, 1 ):Value := XFAM_PRO oExcel:Sheets( "Datos" ):Cells( 4, 1 ):Value := VDEN_PILAR fila := 3 SELECT 15 REGIS:=RECNO() DBGOTOP() CANT:=0 DO WHILE !EOF() CANT+=1 VNOMBRE :=15->MATRIC+' - '+ALLTRIM(APELL1)+' '+SUBSTR(NOMBRE,1,2)+'.' VROL :=15->ROL oExcel:Sheets( "Datos" ):Cells( fila, 4):Value := VNOMBRE oExcel:Sheets( "Datos" ):Cells( fila, 6 ):Value := VROL XFILTR:=XFAM_PRO + VC_PILAR + 15->MATRIC SELECT 16 // WCM_MACO.DBF DBGOTOP() 16->(ORDSCOPE( TOPSCOPE,NIL ) ) 16->(ORDSCOPE( BOTTOMSCOPE,NIL ) ) DBGOTOP() 16->(ORDSCOPE( TOPSCOPE ,XFILTR ) ) 16->(ORDSCOPE( BOTTOMSCOPE,XFILTR ) ) DBGOTOP() SELECT 16 DO WHILE !EOF() IF 16->REQUERIDO =' ' * ELSE oExcel:Sheets( "Datos" ):Cells( fila,7 ):Value := 16->COMPET oExcel:Sheets( "Datos" ):Cells( fila,8 ):Value := 16->REQUERIDO oExcel:Sheets( "Datos" ):Cells( fila,9 ):Value := 16->NEW_EVALU ENDIF SKIP fila+=1 ENDDO SELECT 15 fila+=2 SKIP ENDDO oExcel:Sheets( "Datos" ):Range("A1:I30000"):Columns:AutoFit() // FIJA AJUSTE TAMAÑO DE RANGO IF CANT > 0 // DIBUJO LOS RADARES oExcel:Sheets(1):Select() // me posiciono en la hoja 1 de gráficos. oGraficos:=oExcel:Sheets("Radar"):ChartObjects() // oGraficos:Add(izquierda,arriba,ancho,largo); oChart:=oGraficos:Add(10,70,350,260) oChart:activate() ** apartir de aquí mis problemas oChart:Chart:ChartWizard(source:=oExcel:Sheets("Datos"):Range("H3:H6")) oChart:Chart:ChartWizard(gallery:= 4) oChart:Chart:ChartWizard(title:="New Chart") oChart:ChartType("xlRadarMarkers") ENDIF **-- más cosas.......... oExcel:quit() oExcel:=nil SELECT 15 DBGOTO(REGIS) MUESTRA(oLbx) RETURN NIL ********************************************* Saludos.
Como crear graficos usando ole en excel
rlblanco yo hago asi: [code:30srqwvs] // INCASSI // oExcel &#58;= TOleAuto&#40;&#41;&#58;New&#40; "Excel&#46;Application" &#41; // Excel not available IF Ole2TxtError&#40;&#41; != "S_OK" MsgStop&#40;"Excel non disponibile!", APP_NAME &#41; oExcel &#58;= NIL ENDIF InfStat&#40;"Invio dati a Excel &#40;incassi&#41;&#46;&#46;&#46;"&#41; // foglio 1 IF lMensile cTitolo &#58;= "VENDITA MENSILE - Dal&#58; " + DTOC&#40; dDataDa &#41; + " al&#58; " + DTOC&#40; dDataA &#41; + " - " + ALLTRIM&#40; oV&#58;cNameDitta &#41; ELSE // giornaliero cTitolo &#58;= "VENDITA GIORNALIERA - Dal&#58; " + DTOC&#40; dDataDa &#41; + " al&#58; " + DTOC&#40; dDataA &#41; + " - " + ALLTRIM&#40; oV&#58;cNameDitta &#41; ENDIF oExcel&#58;WorkBooks&#58;Add&#40;&#41; oExcel&#58;Visible &#58;= &#46;F&#46; oHoja &#58;= oExcel&#58;Get&#40; "ActiveSheet" &#41; oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Value &#58;= cTitolo oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Value &#58;= "DATA" oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Value &#58;= "IMPORTO" oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; FOR i &#58;= 1 TO LEN&#40; aIncassi &#41; oHoja&#58;Cells&#40; i+4, 01 &#41;&#58;Value &#58;= aIncassi&#91;i,1&#93; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Value &#58;= aIncassi&#91;i,2&#93; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Set&#40;"NumberFormat"," #&#46;##0,00;- #&#46;##0,00"&#41; NEXT oHoja&#58;Columns&#40;"A&#58;A"&#41;&#58;Set&#40;"ColumnWidth", 9&#46;43 &#41; // grafico oHoja&#58;Range&#40;"A4&#58;B" + NTRIM&#40; LEN&#40; aIncassi &#41; + 4 &#41; &#41;&#58;Select&#40;&#41; oChart &#58;= oExcel&#58;Charts&#58;Add&#40;&#41; oChart&#58;ChartType &#58;= 54 // xl3DColumnClustered //xl3DPie -4102 //xlColumnClustered 51 //xlBarClustered 57 // xl3DColumnClustered 54 oSourceData &#58;= oHoja&#58;Range&#40;"A4&#58;B" + NTRIM&#40; LEN&#40; aIncassi &#41; + 4 &#41;&#41; oChart&#58;SetSourceData&#40;oSourceData&#41; //, PlotBy &#58;= 2 // xlColumns oChart&#58;HasLegend &#58;= &#46;T&#46; oChart&#58;Legend&#58;Position &#58;= -4107 // xlBottom oChart&#58;HasTitle &#58;= &#46;T&#46; oChart&#58;ChartTitle&#58;Characters&#58;Text &#58;= cTitolo //oChartActive &#58;= oChart&#58;ChartArea&#58;Select&#40;&#41; TRY // non funziona tutto, e se tolgo el try, end, da errori in tutti, però, in questo modo, mette gli importi oCh1 &#58;= oChart&#58;PlotArea&#58;Select&#40;&#41; oCh1&#58;RightAngleAxes &#58;= &#46;T&#46; oCh1&#58;Elevation &#58;= 15 oCh1&#58;Perspective &#58;= 30 oCh1&#58;Rotation &#58;= 20 oCh1&#58;HeightPercent &#58;= 100 oCh1&#58;AutoScaling &#58;= &#46;T&#46; oChart&#58;ApplyDataLabels&#58;Set&#40;"LegendKey", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"HasLeaderLines", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowValue", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"AutoText", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowBubbleSize", &#46;F&#46; &#41; CATCH END // foglio 2 InfStat&#40;"Invio dati a Excel &#40;Articoli più venduti&#41;&#46;&#46;&#46;"&#41; aArtAnnoLavoro &#58;= ASORT&#40; aArtAnnoLavoro,,, &#123; |x, y| x&#91;2&#93; > y&#91;2&#93; &#125; &#41; cTitolo &#58;= "Articoli più venduti - " + ALLTRIM&#40; oV&#58;cNameDitta &#41; + " - dal&#58; " + DTOC&#40; dDataDa &#41; + " al&#58; " + DTOC&#40; dDataA &#41; oExcel&#58;Sheets&#40;3&#41;&#58;Select&#40;&#41; // sara il foglio 2, perche il primo è il grafico ;-&#41; oHoja &#58;= oExcel&#58;Get&#40; "ActiveSheet" &#41; oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Value &#58;= cTitolo oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Value &#58;= "ARTICOLO" oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Value &#58;= "IMPORTO" oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; FOR i &#58;= 1 TO 10 // LEN&#40; aArtAnnoLavoro &#41; oHoja&#58;Cells&#40; i+4, 01 &#41;&#58;Value &#58;= ALLTRIM&#40; aArtAnnoLavoro&#91;i,1&#93; &#41; + " - " + ALLTRIM&#40; NameArt&#40; aArtAnnoLavoro&#91;i,1&#93; &#41; &#41; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Value &#58;= aArtAnnoLavoro&#91;i,2&#93; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Set&#40;"NumberFormat"," #&#46;##0,00;- #&#46;##0,00"&#41; NEXT //oHoja&#58;Columns&#40;"A&#58;A"&#41;&#58;Set&#40;"ColumnWidth", 9&#46;43 &#41; // grafico oHoja&#58;Range&#40;"A5&#58;B14"&#41;&#58;Select&#40;&#41; oChart &#58;= oExcel&#58;Charts&#58;Add&#40;&#41; oChart&#58;ChartType &#58;= -4102 // xl3DPie oSourceData &#58;= oHoja&#58;Range&#40;"A5&#58;B14"&#41; oChart&#58;SetSourceData&#40;oSourceData&#41; oChart&#58;HasLegend &#58;= &#46;T&#46; oChart&#58;Legend&#58;Position &#58;= -4107 // xlBottom oChart&#58;HasTitle &#58;= &#46;T&#46; oChart&#58;ChartTitle&#58;Characters&#58;Text &#58;= cTitolo TRY // non funziona tutto, e se tolgo el try, end, da errori in tutti, però, in questo modo, mette gli importi in ogni fetta della torta&#46;&#46;&#46; oChart&#58;ApplyDataLabels&#58;Set&#40;"LegendKey", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"HasLeaderLines", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowValue", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"AutoText", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowBubbleSize", &#46;F&#46; &#41; CATCH END // foglio 3 InfStat&#40;"Invio dati a Excel &#40;Articoli più venduti in pezzi&#41;&#46;&#46;&#46;"&#41; aArtAnnoLavoro &#58;= ASORT&#40; aArtAnnoLavoro,,, &#123; |x, y| x&#91;3&#93; > y&#91;3&#93; &#125; &#41; cTitolo &#58;= "Articoli più venduti &#40;in pezzi&#41; - " + ALLTRIM&#40; oV&#58;cNameDitta &#41; + " - dal&#58; " + DTOC&#40; dDataDa &#41; + " al&#58; " + DTOC&#40; dDataA &#41; oExcel&#58;Sheets&#40;5&#41;&#58;Select&#40;&#41; // sara il foglio 3, perche il primo è il grafico, secondo il foglio 1, terzo il secondo grafico, quarto il foglio 2 ;-&#41; oHoja &#58;= oExcel&#58;Get&#40; "ActiveSheet" &#41; oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Value &#58;= cTitolo oHoja&#58;Cells&#40; 1, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Value &#58;= "ARTICOLO" oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Value &#58;= "PEZZI" oHoja&#58;Cells&#40; 4, 01 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; oHoja&#58;Cells&#40; 4, 02 &#41;&#58;Font&#58;Bold &#58;= &#46;T&#46; FOR i &#58;= 1 TO 10 // LEN&#40; aArtAnnoLavoro &#41; oHoja&#58;Cells&#40; i+4, 01 &#41;&#58;Value &#58;= ALLTRIM&#40; aArtAnnoLavoro&#91;i,1&#93; &#41; + " - " + ALLTRIM&#40; NameArt&#40; aArtAnnoLavoro&#91;i,1&#93; &#41; &#41; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Value &#58;= aArtAnnoLavoro&#91;i,3&#93; oHoja&#58;Cells&#40; i+4, 02 &#41;&#58;Set&#40;"NumberFormat"," #&#46;##0,00;- #&#46;##0,00"&#41; NEXT //oHoja&#58;Columns&#40;"A&#58;A"&#41;&#58;Set&#40;"ColumnWidth", 9&#46;43 &#41; // grafico oHoja&#58;Range&#40;"A5&#58;B14"&#41;&#58;Select&#40;&#41; oChart &#58;= oExcel&#58;Charts&#58;Add&#40;&#41; oChart&#58;ChartType &#58;= -4102 // xl3DPie oSourceData &#58;= oHoja&#58;Range&#40;"A5&#58;B14"&#41; oChart&#58;SetSourceData&#40;oSourceData&#41; oChart&#58;HasLegend &#58;= &#46;T&#46; oChart&#58;Legend&#58;Position &#58;= -4107 // xlBottom oChart&#58;HasTitle &#58;= &#46;T&#46; oChart&#58;ChartTitle&#58;Characters&#58;Text &#58;= cTitolo TRY // non funziona tutto, e se tolgo el try, end, da errori in tutti, però, in questo modo, mette gli importi in ogni fetta della torta&#46;&#46;&#46; oChart&#58;ApplyDataLabels&#58;Set&#40;"LegendKey", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"HasLeaderLines", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowValue", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"AutoText", &#46;T&#46; &#41; oChart&#58;ApplyDataLabels&#58;Set&#40;"ShowBubbleSize", &#46;F&#46; &#41; CATCH END // FINE più venduti in pezzi oExcel&#58;Visible &#58;= &#46;T&#46; lUscitaOk &#58;= &#46;T&#46; RECOVER USING lUscitaOk lUscitaOk &#58;= &#46;F&#46; END SEQUENCE RETURN lUscitaOk [/code:30srqwvs] En algunos casos da error, por ese motivo puse el TRY CATCH De repente te sirve para hacerte una idea, no si es lo que tu necesitas. Saludos.
Como crear graficos usando ole en excel
Hola pymsoft. Muchísimas gracias por el ejemplo, algo así, es lo que echaba en falta para comprender el funcionamiento. Gracias a ello ya he conseguido hacer un gráfico incrustado tipo radar relleno en una hoja. He andado loco con los valores de las constantes de excel, así que aquí dejo una muestra para quien las necesite. ' ======================================= ' MS Excel constants ' --------------------------------------- Const xlAll = -4104 Const xlAutomatic = -4105 Const xlBoth = 1 Const xlCenter = -4108 Const xlChecker = 9 Const xlCircle = 8 Const xlCorner = 2 Const xlCrissCross = 16 Const xlCross = 4 Const xlDiamond = 2 Const xlDistributed = -4117 Const xlDoubleAccounting = 5 Const xlFixedValue = 1 Const xlFormats = -4122 Const xlGray16 = 17 Const xlGray8 = 18 Const xlGrid = 15 Const xlHigh = -4127 Const xlInside = 2 Const xlJustify = -4130 Const xlLightDown = 13 Const xlLightHorizontal = 11 Const xlLightUp = 14 Const xlLightVertical = 12 Const xlLow = -4134 Const xlManual = -4135 Const xlMinusValues = 3 Const xlModule = -4141 Const xlNextToAxis = 4 Const xlNone = -4142 Const xlNotes = -4144 Const xlOff = -4146 Const xlOn = 1 Const xlPercent = 2 Const xlPlus = 9 Const xlPlusValues = 2 Const xlSemiGray75 = 10 Const xlShowLabel = 4 Const xlShowLabelAndPercent = 5 Const xlShowPercent = 3 Const xlShowValue = 2 Const xlSimple = -4154 Const xlSingle = 2 Const xlSingleAccounting = 4 Const xlSolid = 1 Const xlSquare = 1 Const xlStar = 5 Const xlStError = 4 Const xlToolbarButton = 2 Const xlTriangle = 3 Const xlGray25 = -4124 Const xlGray50 = -4125 Const xlGray75 = -4126 Const xlBottom = -4107 Const xlLeft = -4131 Const xlRight = -4152 Const xlTop = -4160 Const xl3DBar = -4099 Const xl3DSurface = -4103 Const xlBar = 2 Const xlColumn = 3 Const xlCombination = -4111 Const xlCustom = -4114 Const xlDefaultAutoFormat = -1 Const xlMaximum = 2 Const xlMinimum = 4 Const xlOpaque = 3 Const xlTransparent = 2 Const xlBidi = -5000 Const xlLatin = -5001 Const xlContext = -5002 Const xlLTR = -5003 Const xlRTL = -5004 Const xlFullScript = 1 Const xlPartialScript = 2 Const xlMixedScript = 3 Const xlMixedAuthorizedScript = 4 Const xlVisualCursor = 2 Const xlLogicalCursor = 1 Const xlSystem = 1 Const xlPartial = 3 Const xlHindiNumerals = 3 Const xlBidiCalendar = 3 Const xlGregorian = 2 Const xlComplete = 4 Const xlScale = 3 Const xlClosed = 3 Const xlColor1 = 7 Const xlColor2 = 8 Const xlColor3 = 9 Const xlConstants = 2 Const xlContents = 2 Const xlBelow = 1 Const xlCascade = 7 Const xlCenterAcrossSelection = 7 Const xlChart4 = 2 Const xlChartSeries = 17 Const xlChartShort = 6 Const xlChartTitles = 18 Const xlClassic1 = 1 Const xlClassic2 = 2 Const xlClassic3 = 3 Const xl3DEffects1 = 13 Const xl3DEffects2 = 14 Const xlAbove = 0 Const xlAccounting1 = 4 Const xlAccounting2 = 5 Const xlAccounting3 = 6 Const xlAccounting4 = 17 Const xlAdd = 2 Const xlDebugCodePane = 13 Const xlDesktop = 9 Const xlDirect = 1 Const xlDivide = 5 Const xlDoubleClosed = 5 Const xlDoubleOpen = 4 Const xlDoubleQuote = 1 Const xlEntireChart = 20 Const xlExcelMenus = 1 Const xlExtended = 3 Const xlFill = 5 Const xlFirst = 0 Const xlFloating = 5 Const xlFormula = 5 Const xlGeneral = 1 Const xlGridline = 22 Const xlIcons = 1 Const xlImmediatePane = 12 Const xlInteger = 2 Const xlLast = 1 Const xlLastCell = 11 Const xlList1 = 10 Const xlList2 = 11 Const xlList3 = 12 Const xlLocalFormat1 = 15 Const xlLocalFormat2 = 16 Const xlLong = 3 Const xlLotusHelp = 2 Const xlMacrosheetCell = 7 Const xlMixed = 2 Const xlMultiply = 4 Const xlNarrow = 1 Const xlNoDocuments = 3 Const xlOpen = 2 Const xlOutside = 3 Const xlReference = 4 Const xlSemiautomatic = 2 Const xlShort = 1 Const xlSingleQuote = 2 Const xlStrict = 2 Const xlSubtract = 3 Const xlTextBox = 16 Const xlTiled = 1 Const xlTitleBar = 8 Const xlToolbar = 1 Const xlVisible = 12 Const xlWatchPane = 11 Const xlWide = 3 Const xlWorkbookTab = 6 Const xlWorksheet4 = 1 Const xlWorksheetCell = 3 Const xlWorksheetShort = 5 Const xlAllExceptBorders = 7 Const xlLeftToRight = 2 Const xlTopToBottom = 1 Const xlVeryHidden = 2 Const xlDrawingObject = 14 Const xlCreatorCode = 1480803660 Const xlBuiltIn = 21 Const xlUserDefined = 22 Const xlAnyGallery = 23 Const xlColorIndexAutomatic = -4105 Const xlColorIndexNone = -4142 Const xlCap = 1 Const xlNoCap = 2 Const xlColumns = 2 Const xlRows = 1 Const xlScaleLinear = -4132 Const xlScaleLogarithmic = -4133 Const xlAutoFill = 4 Const xlChronological = 3 Const xlGrowth = 2 Const xlDataSeriesLinear = -4132 Const xlAxisCrossesAutomatic = -4105 Const xlAxisCrossesCustom = -4114 Const xlAxisCrossesMaximum = 2 Const xlAxisCrossesMinimum = 4 Const xlPrimary = 1 Const xlSecondary = 2 Const xlBackgroundAutomatic = -4105 Const xlBackgroundOpaque = 3 Const xlBackgroundTransparent = 2 Const xlMaximized = -4137 Const xlMinimized = -4140 Const xlNormal = -4143 Const xlCategory = 1 Const xlSeriesAxis = 3 Const xlValue = 2 Const xlArrowHeadLengthLong = 3 Const xlArrowHeadLengthMedium = -4138 Const xlArrowHeadLengthShort = 1 Const xlVAlignBottom = -4107 Const xlVAlignCenter = -4108 Const xlVAlignDistributed = -4117 Const xlVAlignJustify = -4130 Const xlVAlignTop = -4160 Const xlTickMarkCross = 4 Const xlTickMarkInside = 2 Const xlTickMarkNone = -4142 Const xlTickMarkOutside = 3 Const xlX = -4168 Const xlY = 1 Const xlErrorBarIncludeBoth = 1 Const xlErrorBarIncludeMinusValues = 3 Const xlErrorBarIncludeNone = -4142 Const xlErrorBarIncludePlusValues = 2 Const xlInterpolated = 3 Const xlNotPlotted = 1 Const xlZero = 2 Const xlArrowHeadStyleClosed = 3 Const xlArrowHeadStyleDoubleClosed = 5 Const xlArrowHeadStyleDoubleOpen = 4 Const xlArrowHeadStyleNone = -4142 Const xlArrowHeadStyleOpen = 2 Const xlArrowHeadWidthMedium = -4138 Const xlArrowHeadWidthNarrow = 1 Const xlArrowHeadWidthWide = 3 Const xlHAlignCenter = -4108 Const xlHAlignCenterAcrossSelection = 7 Const xlHAlignDistributed = -4117 Const xlHAlignFill = 5 Const xlHAlignGeneral = 1 Const xlHAlignJustify = -4130 Const xlHAlignLeft = -4131 Const xlHAlignRight = -4152 Const xlTickLabelPositionHigh = -4127 Const xlTickLabelPositionLow = -4134 Const xlTickLabelPositionNextToAxis = 4 Const xlTickLabelPositionNone = -4142 Const xlLegendPositionBottom = -4107 Const xlLegendPositionCorner = 2 Const xlLegendPositionLeft = -4131 Const xlLegendPositionRight = -4152 Const xlLegendPositionTop = -4160 Const xlStackScale = 3 Const xlStack = 2 Const xlStretch = 1 Const xlSides = 1 Const xlEnd = 2 Const xlEndSides = 3 Const xlFront = 4 Const xlFrontSides = 5 Const xlFrontEnd = 6 Const xlAllFaces = 7 Const xlDownward = -4170 Const xlHorizontal = -4128 Const xlUpward = -4171 Const xlVertical = -4166 Const xlTickLabelOrientationAutomatic = -4105 Const xlTickLabelOrientationDownward = -4170 Const xlTickLabelOrientationHorizontal = -4128 Const xlTickLabelOrientationUpward = -4171 Const xlTickLabelOrientationVertical = -4166 Const xlHairline = 1 Const xlMedium = -4138 Const xlThick = 4 Const xlThin = 2 Const xlDay = 1 Const xlMonth = 3 Const xlWeekday = 2 Const xlYear = 4 Const xlUnderlineStyleDouble = -4119 Const xlUnderlineStyleDoubleAccounting = 5 Const xlUnderlineStyleNone = -4142 Const xlUnderlineStyleSingle = 2 Const xlUnderlineStyleSingleAccounting = 4 Const xlErrorBarTypeCustom = -4114 Const xlErrorBarTypeFixedValue = 1 Const xlErrorBarTypePercent = 2 Const xlErrorBarTypeStDev = -4155 Const xlErrorBarTypeStError = 4 Const xlExponential = 5 Const xlLinear = -4132 Const xlLogarithmic = -4133 Const xlMovingAvg = 6 Const xlPolynomial = 3 Const xlPower = 4 Const xlContinuous = 1 Const xlDash = -4115 Const xlDashDot = 4 Const xlDashDotDot = 5 Const xlDot = -4118 Const xlDouble = -4119 Const xlSlantDashDot = 13 Const xlLineStyleNone = -4142 Const xlDataLabelsShowNone = -4142 Const xlDataLabelsShowValue = 2 Const xlDataLabelsShowPercent = 3 Const xlDataLabelsShowLabel = 4 Const xlDataLabelsShowLabelAndPercent = 5 Const xlDataLabelsShowBubbleSizes = 6 Const xlMarkerStyleAutomatic = -4105 Const xlMarkerStyleCircle = 8 Const xlMarkerStyleDash = -4115 Const xlMarkerStyleDiamond = 2 Const xlMarkerStyleDot = -4118 Const xlMarkerStyleNone = -4142 Const xlMarkerStylePicture = -4147 Const xlMarkerStylePlus = 9 Const xlMarkerStyleSquare = 1 Const xlMarkerStyleStar = 5 Const xlMarkerStyleTriangle = 3 Const xlMarkerStyleX = -4168 Const xlBMP = 1 Const xlCGM = 7 Const xlDRW = 4 Const xlDXF = 5 Const xlEPS = 8 Const xlHGL = 6 Const xlPCT = 13 Const xlPCX = 10 Const xlPIC = 11 Const xlPLT = 12 Const xlTIF = 9 Const xlWMF = 2 Const xlWPG = 3 Const xlPatternAutomatic = -4105 Const xlPatternChecker = 9 Const xlPatternCrissCross = 16 Const xlPatternDown = -4121 Const xlPatternGray16 = 17 Const xlPatternGray25 = -4124 Const xlPatternGray50 = -4125 Const xlPatternGray75 = -4126 Const xlPatternGray8 = 18 Const xlPatternGrid = 15 Const xlPatternHorizontal = -4128 Const xlPatternLightDown = 13 Const xlPatternLightHorizontal = 11 Const xlPatternLightUp = 14 Const xlPatternLightVertical = 12 Const xlPatternNone = -4142 Const xlPatternSemiGray75 = 10 Const xlPatternSolid = 1 Const xlPatternUp = -4162 Const xlPatternVertical = -4166 Const xlSplitByPosition = 1 Const xlSplitByPercentValue = 3 Const xlSplitByCustomSplit = 4 Const xlSplitByValue = 2 Const xlHundreds = -2 Const xlThousands = -3 Const xlTenThousands = -4 Const xlHundredThousands = -5 Const xlMillions = -6 Const xlTenMillions = -7 Const xlHundredMillions = -8 Const xlThousandMillions = -9 Const xlMillionMillions = -10 Const xlLabelPositionCenter = -4108 Const xlLabelPositionAbove = 0 Const xlLabelPositionBelow = 1 Const xlLabelPositionLeft = -4131 Const xlLabelPositionRight = -4152 Const xlLabelPositionOutsideEnd = 2 Const xlLabelPositionInsideEnd = 3 Const xlLabelPositionInsideBase = 4 Const xlLabelPositionBestFit = 5 Const xlLabelPositionMixed = 6 Const xlLabelPositionCustom = 7 Const xlDays = 0 Const xlMonths = 1 Const xlYears = 2 Const xlCategoryScale = 2 Const xlTimeScale = 3 Const xlAutomaticScale = -4105 Const xlBox = 0 Const xlPyramidToPoint = 1 Const xlPyramidToMax = 2 Const xlCylinder = 3 Const xlConeToPoint = 4 Const xlConeToMax = 5 Const xlColumnClustered = 51 Const xlColumnStacked = 52 Const xlColumnStacked100 = 53 Const xl3DColumnClustered = 54 Const xl3DColumnStacked = 55 Const xl3DColumnStacked100 = 56 Const xlBarClustered = 57 Const xlBarStacked = 58 Const xlBarStacked100 = 59 Const xl3DBarClustered = 60 Const xl3DBarStacked = 61 Const xl3DBarStacked100 = 62 Const xlLineStacked = 63 Const xlLineStacked100 = 64 Const xlLineMarkers = 65 Const xlLineMarkersStacked = 66 Const xlLineMarkersStacked100 = 67 Const xlPieOfPie = 68 Const xlPieExploded = 69 Const xl3DPieExploded = 70 Const xlBarOfPie = 71 Const xlXYScatterSmooth = 72 Const xlXYScatterSmoothNoMarkers = 73 Const xlXYScatterLines = 74 Const xlXYScatterLinesNoMarkers = 75 Const xlAreaStacked = 76 Const xlAreaStacked100 = 77 Const xl3DAreaStacked = 78 Const xl3DAreaStacked100 = 79 Const xlDoughnutExploded = 80 Const xlRadarMarkers = 81 Const xlRadarFilled = 82 Const xlSurface = 83 Const xlSurfaceWireframe = 84 Const xlSurfaceTopView = 85 Const xlSurfaceTopViewWireframe = 86 Const xlBubble = 15 Const xlBubble3DEffect = 87 Const xlStockHLC = 88 Const xlStockOHLC = 89 Const xlStockVHLC = 90 Const xlStockVOHLC = 91 Const xlCylinderColClustered = 92 Const xlCylinderColStacked = 93 Const xlCylinderColStacked100 = 94 Const xlCylinderBarClustered = 95 Const xlCylinderBarStacked = 96 Const xlCylinderBarStacked100 = 97 Const xlCylinderCol = 98 Const xlConeColClustered = 99 Const xlConeColStacked = 100 Const xlConeColStacked100 = 101 Const xlConeBarClustered = 102 Const xlConeBarStacked = 103 Const xlConeBarStacked100 = 104 Const xlConeCol = 105 Const xlPyramidColClustered = 106 Const xlPyramidColStacked = 107 Const xlPyramidColStacked100 = 108 Const xlPyramidBarClustered = 109 Const xlPyramidBarStacked = 110 Const xlPyramidBarStacked100 = 111 Const xlPyramidCol = 112 Const xl3DColumn = -4100 Const xlLine = 4 Const xl3DLine = -4101 Const xl3DPie = -4102 Const xlPie = 5 Const xlXYScatter = -4169 Const xl3DArea = -4098 Const xlArea = 1 Const xlDoughnut = -4120 Const xlRadar = -4151 Const xlDataLabel = 0 Const xlChartArea = 2 Const xlSeries = 3 Const xlChartTitle = 4 Const xlWalls = 5 Const xlCorners = 6 Const xlDataTable = 7 Const xlTrendline = 8 Const xlErrorBars = 9 Const xlXErrorBars = 10 Const xlYErrorBars = 11 Const xlLegendEntry = 12 Const xlLegendKey = 13 Const xlShape = 14 Const xlMajorGridlines = 15 Const xlMinorGridlines = 16 Const xlAxisTitle = 17 Const xlUpBars = 18 Const xlPlotArea = 19 Const xlDownBars = 20 Const xlAxis = 21 Const xlSeriesLines = 22 Const xlFloor = 23 Const xlLegend = 24 Const xlHiLoLines = 25 Const xlDropLines = 26 Const xlRadarAxisLabels = 27 Const xlNothing = 28 Const xlLeaderLines = 29 Const xlDisplayUnitLabel = 30 Const xlPivotChartFieldButton = 31 Const xlPivotChartDropZone = 32 Const xlSizeIsWidth = 2 Const xlSizeIsArea = 1 Const xlShiftDown = -4121 Const xlShiftToRight = -4161 Const xlShiftToLeft = -4159 Const xlShiftUp = -4162 Const xlDown = -4121 Const xlToLeft = -4159 Const xlToRight = -4161 Const xlUp = -4162 Const xlAverage = -4106 Const xlCount = -4112 Const xlCountNums = -4113 Const xlMax = -4136 Const xlMin = -4139 Const xlProduct = -4149 Const xlStDev = -4155 Const xlStDevP = -4156 Const xlSum = -4157 Const xlVar = -4164 Const xlVarP = -4165 Const xlUnknown = 1000 Const xlChart = -4109 Const xlDialogSheet = -4116 Const xlExcel4IntlMacroSheet = 4 Const xlExcel4MacroSheet = 3 Const xlWorksheet = -4167 Const xlColumnHeader = -4110 Const xlColumnItem = 5 Const xlDataHeader = 3 Const xlDataItem = 7 Const xlPageHeader = 2 Const xlPageItem = 6 Const xlRowHeader = -4153 Const xlRowItem = 4 Const xlTableBody = 8 Const xlFormulas = -4123 Const xlComments = -4144 Const xlValues = -4163 Const xlChartAsWindow = 5 Const xlChartInPlace = 4 Const xlClipboard = 3 Const xlInfo = -4129 Const xlWorkbook = 1 Const xlDate = 2 Const xlNumber = -4145 Const xlText = -4158 Const xlBitmap = 2 Const xlPicture = -4147 Const xlScenario = 4 Const xlConsolidation = 3 Const xlDatabase = 1 Const xlExternal = 2 Const xlPivotTable = -4148 Const xlA1 = 1 Const xlR1C1 = -4150 Const xlMicrosoftAccess = 4 Const xlMicrosoftFoxPro = 5 Const xlMicrosoftMail = 3 Const xlMicrosoftPowerPoint = 2 Const xlMicrosoftProject = 6 Const xlMicrosoftSchedulePlus = 7 Const xlMicrosoftWord = 1 Const xlNoButton = 0 Const xlPrimaryButton = 1 Const xlSecondaryButton = 2 Const xlCopy = 1 Const xlCut = 2 Const xlFillWithAll = -4104 Const xlFillWithContents = 2 Const xlFillWithFormats = -4122 Const xlFilterCopy = 2 Const xlFilterInPlace = 1 Const xlDownThenOver = 1 Const xlOverThenDown = 2 Const xlLinkTypeExcelLinks = 1 Const xlLinkTypeOLELinks = 2 Const xlColumnThenRow = 2 Const xlRowThenColumn = 1 Const xlDisabled = 0 Const xlErrorHandler = 2 Const xlInterrupt = 1 Const xlPageBreakAutomatic = -4105 Const xlPageBreakManual = -4135 Const xlPageBreakNone = -4142 Const xlOLEControl = 2 Const xlOLEEmbed = 1 Const xlOLELink = 0 Const xlLandscape = 2 Const xlPortrait = 1 Const xlEditionDate = 2 Const xlUpdateState = 1 Const xlLinkInfoStatus = 3 Const xlCommandUnderlinesAutomatic = -4105 Const xlCommandUnderlinesOff = -4146 Const xlCommandUnderlinesOn = 1 Const xlVerbOpen = 2 Const xlVerbPrimary = 1 Const xlCalculationAutomatic = -4105 Const xlCalculationManual = -4135 Const xlCalculationSemiautomatic = 2 Const xlReadOnly = 3 Const xlReadWrite = 2 Const xlPublisher = 1 Const xlSubscriber = 2 Const xlFitToPage = 2 Const xlFullPage = 3 Const xlScreenSize = 1 Const xlPart = 2 Const xlWhole = 1 Const xlMAPI = 1 Const xlNoMailSystem = 0 Const xlPowerTalk = 2 Const xlLinkInfoOLELinks = 2 Const xlLinkInfoPublishers = 5 Const xlLinkInfoSubscribers = 6 Const xlErrDiv0 = 2007 Const xlErrNA = 2042 Const xlErrName = 2029 Const xlErrNull = 2000 Const xlErrNum = 2036 Const xlErrRef = 2023 Const xlErrValue = 2015 Const xlBIFF = 2 Const xlPICT = 1 Const xlRTF = 4 Const xlVALU = 8 Const xlExcelLinks = 1 Const xlOLELinks = 2 Const xlPublishers = 5 Const xlSubscribers = 6 Const xlCellTypeBlanks = 4 Const xlCellTypeConstants = 2 Const xlCellTypeFormulas = -4123 Const xlCellTypeLastCell = 11 Const xlCellTypeComments = -4144 Const xlCellTypeVisible = 12 Const xlCellTypeAllFormatConditions = -4172 Const xlCellTypeSameFormatConditions = -4173 Const xlCellTypeAllValidation = -4174 Const xlCellTypeSameValidation = -4175 Const xlArrangeStyleCascade = 7 Const xlArrangeStyleHorizontal = -4128 Const xlArrangeStyleTiled = 1 Const xlArrangeStyleVertical = -4166 Const xlIBeam = 3 Const xlDefault = -4143 Const xlNorthwestArrow = 1 Const xlWait = 2 Const xlAutomaticUpdate = 4 Const xlCancel = 1 Const xlChangeAttributes = 6 Const xlManualUpdate = 5 Const xlOpenSource = 3 Const xlSelect = 3 Const xlSendPublisher = 2 Const xlUpdateSubscriber = 2 Const xlFillCopy = 1 Const xlFillDays = 5 Const xlFillDefault = 0 Const xlFillFormats = 3 Const xlFillMonths = 7 Const xlFillSeries = 2 Const xlFillValues = 4 Const xlFillWeekdays = 6 Const xlFillYears = 8 Const xlGrowthTrend = 10 Const xlLinearTrend = 9 Const xlAnd = 1 Const xlBottom10Items = 4 Const xlBottom10Percent = 6 Const xlOr = 2 Const xlTop10Items = 3 Const xlTop10Percent = 5 Const xlClipboardFormatBIFF = 8 Const xlClipboardFormatBIFF2 = 18 Const xlClipboardFormatBIFF3 = 20 Const xlClipboardFormatBIFF4 = 30 Const xlClipboardFormatBinary = 15 Const xlClipboardFormatBitmap = 9 Const xlClipboardFormatCGM = 13 Const xlClipboardFormatCSV = 5 Const xlClipboardFormatDIF = 4 Const xlClipboardFormatDspText = 12 Const xlClipboardFormatEmbeddedObject = 21 Const xlClipboardFormatEmbedSource = 22 Const xlClipboardFormatLink = 11 Const xlClipboardFormatLinkSource = 23 Const xlClipboardFormatLinkSourceDesc = 32 Const xlClipboardFormatMovie = 24 Const xlClipboardFormatNative = 14 Const xlClipboardFormatObjectDesc = 31 Const xlClipboardFormatObjectLink = 19 Const xlClipboardFormatOwnerLink = 17 Const xlClipboardFormatPICT = 2 Const xlClipboardFormatPrintPICT = 3 Const xlClipboardFormatRTF = 7 Const xlClipboardFormatScreenPICT = 29 Const xlClipboardFormatStandardFont = 28 Const xlClipboardFormatStandardScale = 27 Const xlClipboardFormatSYLK = 6 Const xlClipboardFormatTable = 16 Const xlClipboardFormatText = 0 Const xlClipboardFormatToolFace = 25 Const xlClipboardFormatToolFacePICT = 26 Const xlClipboardFormatVALU = 1 Const xlClipboardFormatWK1 = 10 Const xlAddIn = 18 Const xlCSV = 6 Const xlCSVMac = 22 Const xlCSVMSDOS = 24 Const xlCSVWindows = 23 Const xlDBF2 = 7 Const xlDBF3 = 8 Const xlDBF4 = 11 Const xlDIF = 9 Const xlExcel2 = 16 Const xlExcel2FarEast = 27 Const xlExcel3 = 29 Const xlExcel4 = 33 Const xlExcel5 = 39 Const xlExcel7 = 39 Const xlExcel9795 = 43 Const xlExcel4Workbook = 35 Const xlIntlAddIn = 26 Const xlIntlMacro = 25 Const xlWorkbookNormal = -4143 Const xlSYLK = 2 Const xlTemplate = 17 Const xlCurrentPlatformText = -4158 Const xlTextMac = 19 Const xlTextMSDOS = 21 Const xlTextPrinter = 36 Const xlTextWindows = 20 Const xlWJ2WD1 = 14 Const xlWK1 = 5 Const xlWK1ALL = 31 Const xlWK1FMT = 30 Const xlWK3 = 15 Const xlWK4 = 38 Const xlWK3FM3 = 32 Const xlWKS = 4 Const xlWorks2FarEast = 28 Const xlWQ1 = 34 Const xlWJ3 = 40 Const xlWJ3FJ3 = 41 Const xlUnicodeText = 42 Const xlHtml = 44 Const xlWebArchive = 45 Const xlXMLSpreadsheet = 46 Const xl24HourClock = 33 Const xl4DigitYears = 43 Const xlAlternateArraySeparator = 16 Const xlColumnSeparator = 14 Const xlCountryCode = 1 Const xlCountrySetting = 2 Const xlCurrencyBefore = 37 Const xlCurrencyCode = 25 Const xlCurrencyDigits = 27 Const xlCurrencyLeadingZeros = 40 Const xlCurrencyMinusSign = 38 Const xlCurrencyNegative = 28 Const xlCurrencySpaceBefore = 36 Const xlCurrencyTrailingZeros = 39 Const xlDateOrder = 32 Const xlDateSeparator = 17 Const xlDayCode = 21 Const xlDayLeadingZero = 42 Const xlDecimalSeparator = 3 Const xlGeneralFormatName = 26 Const xlHourCode = 22 Const xlLeftBrace = 12 Const xlLeftBracket = 10 Const xlListSeparator = 5 Const xlLowerCaseColumnLetter = 9 Const xlLowerCaseRowLetter = 8 Const xlMDY = 44 Const xlMetric = 35 Const xlMinuteCode = 23 Const xlMonthCode = 20 Const xlMonthLeadingZero = 41 Const xlMonthNameChars = 30 Const xlNoncurrencyDigits = 29 Const xlNonEnglishFunctions = 34 Const xlRightBrace = 13 Const xlRightBracket = 11 Const xlRowSeparator = 15 Const xlSecondCode = 24 Const xlThousandsSeparator = 4 Const xlTimeLeadingZero = 45 Const xlTimeSeparator = 18 Const xlUpperCaseColumnLetter = 7 Const xlUpperCaseRowLetter = 6 Const xlWeekdayNameChars = 31 Const xlYearCode = 19 Const xlPageBreakFull = 1 Const xlPageBreakPartial = 2 Const xlOverwriteCells = 0 Const xlInsertDeleteCells = 1 Const xlInsertEntireRows = 2 Const xlNoLabels = -4142 Const xlRowLabels = 1 Const xlColumnLabels = 2 Const xlMixedLabels = 3 Const xlSinceMyLastSave = 1 Const xlAllChanges = 2 Const xlNotYetReviewed = 3 Const xlNoIndicator = 0 Const xlCommentIndicatorOnly = -1 Const xlCommentAndIndicator = 1 Const xlCellValue = 1 Const xlExpression = 2 Const xlBetween = 1 Const xlNotBetween = 2 Const xlEqual = 3 Const xlNotEqual = 4 Const xlGreater = 5 Const xlLess = 6 Const xlGreaterEqual = 7 Const xlLessEqual = 8 Const xlNoRestrictions = 0 Const xlUnlockedCells = 1 Const xlNoSelection = -4142 Const xlValidateInputOnly = 0 Const xlValidateWholeNumber = 1 Const xlValidateDecimal = 2 Const xlValidateList = 3 Const xlValidateDate = 4 Const xlValidateTime = 5 Const xlValidateTextLength = 6 Const xlValidateCustom = 7 Const xlIMEModeNoControl = 0 Const xlIMEModeOn = 1 Const xlIMEModeOff = 2 Const xlIMEModeDisable = 3 Const xlIMEModeHiragana = 4 Const xlIMEModeKatakana = 5 Const xlIMEModeKatakanaHalf = 6 Const xlIMEModeAlphaFull = 7 Const xlIMEModeAlpha = 8 Const xlIMEModeHangulFull = 9 Const xlIMEModeHangul = 10 Const xlValidAlertStop = 1 Const xlValidAlertWarning = 2 Const xlValidAlertInformation = 3 Const xlLocationAsNewSheet = 1 Const xlLocationAsObject = 2 Const xlLocationAutomatic = 3 Const xlPaper10x14 = 16 Const xlPaper11x17 = 17 Const xlPaperA3 = 8 Const xlPaperA4 = 9 Const xlPaperA4Small = 10 Const xlPaperA5 = 11 Const xlPaperB4 = 12 Const xlPaperB5 = 13 Const xlPaperCsheet = 24 Const xlPaperDsheet = 25 Const xlPaperEnvelope10 = 20 Const xlPaperEnvelope11 = 21 Const xlPaperEnvelope12 = 22 Const xlPaperEnvelope14 = 23 Const xlPaperEnvelope9 = 19 Const xlPaperEnvelopeB4 = 33 Const xlPaperEnvelopeB5 = 34 Const xlPaperEnvelopeB6 = 35 Const xlPaperEnvelopeC3 = 29 Const xlPaperEnvelopeC4 = 30 Const xlPaperEnvelopeC5 = 28 Const xlPaperEnvelopeC6 = 31 Const xlPaperEnvelopeC65 = 32 Const xlPaperEnvelopeDL = 27 Const xlPaperEnvelopeItaly = 36 Const xlPaperEnvelopeMonarch = 37 Const xlPaperEnvelopePersonal = 38 Const xlPaperEsheet = 26 Const xlPaperExecutive = 7 Const xlPaperFanfoldLegalGerman = 41 Const xlPaperFanfoldStdGerman = 40 Const xlPaperFanfoldUS = 39 Const xlPaperFolio = 14 Const xlPaperLedger = 4 Const xlPaperLegal = 5 Const xlPaperLetter = 1 Const xlPaperLetterSmall = 2 Const xlPaperNote = 18 Const xlPaperQuarto = 15 Const xlPaperStatement = 6 Const xlPaperTabloid = 3 Const xlPaperUser = 256 Const xlPasteSpecialOperationAdd = 2 Const xlPasteSpecialOperationDivide = 5 Const xlPasteSpecialOperationMultiply = 4 Const xlPasteSpecialOperationNone = -4142 Const xlPasteSpecialOperationSubtract = 3 Const xlPasteAll = -4104 Const xlPasteAllExceptBorders = 7 Const xlPasteFormats = -4122 Const xlPasteFormulas = -4123 Const xlPasteComments = -4144 Const xlPasteValues = -4163 Const xlPasteColumnWidths = 8 Const xlPasteValidation = 6 Const xlPasteFormulasAndNumberFormats = 11 Const xlPasteValuesAndNumberFormats = 12 Const xlKatakanaHalf = 0 Const xlKatakana = 1 Const xlHiragana = 2 Const xlNoConversion = 3 Const xlPhoneticAlignNoControl = 0 Const xlPhoneticAlignLeft = 1 Const xlPhoneticAlignCenter = 2 Const xlPhoneticAlignDistributed = 3 Const xlPrinter = 2 Const xlScreen = 1 Const xlColumnField = 2 Const xlDataField = 4 Const xlHidden = 0 Const xlPageField = 3 Const xlRowField = 1 Const xlDifferenceFrom = 2 Const xlIndex = 9 Const xlNoAdditionalCalculation = -4143 Const xlPercentDifferenceFrom = 4 Const xlPercentOf = 3 Const xlPercentOfColumn = 7 Const xlPercentOfRow = 6 Const xlPercentOfTotal = 8 Const xlRunningTotal = 5 Const xlFreeFloating = 3 Const xlMove = 2 Const xlMoveAndSize = 1 Const xlMacintosh = 1 Const xlMSDOS = 3 Const xlWindows = 2 Const xlPrintSheetEnd = 1 Const xlPrintInPlace = 16 Const xlPrintNoComments = -4142 Const xlPriorityHigh = -4127 Const xlPriorityLow = -4134 Const xlPriorityNormal = -4143 Const xlLabelOnly = 1 Const xlDataAndLabel = 0 Const xlDataOnly = 2 Const xlOrigin = 3 Const xlButton = 15 Const xlBlanks = 4 Const xlFirstRow = 256 Const xlRangeAutoFormat3DEffects1 = 13 Const xlRangeAutoFormat3DEffects2 = 14 Const xlRangeAutoFormatAccounting1 = 4 Const xlRangeAutoFormatAccounting2 = 5 Const xlRangeAutoFormatAccounting3 = 6 Const xlRangeAutoFormatAccounting4 = 17 Const xlRangeAutoFormatClassic1 = 1 Const xlRangeAutoFormatClassic2 = 2 Const xlRangeAutoFormatClassic3 = 3 Const xlRangeAutoFormatColor1 = 7 Const xlRangeAutoFormatColor2 = 8 Const xlRangeAutoFormatColor3 = 9 Const xlRangeAutoFormatList1 = 10 Const xlRangeAutoFormatList2 = 11 Const xlRangeAutoFormatList3 = 12 Const xlRangeAutoFormatLocalFormat1 = 15 Const xlRangeAutoFormatLocalFormat2 = 16 Const xlRangeAutoFormatLocalFormat3 = 19 Const xlRangeAutoFormatLocalFormat4 = 20 Const xlRangeAutoFormatReport1 = 21 Const xlRangeAutoFormatReport2 = 22 Const xlRangeAutoFormatReport3 = 23 Const xlRangeAutoFormatReport4 = 24 Const xlRangeAutoFormatReport5 = 25 Const xlRangeAutoFormatReport6 = 26 Const xlRangeAutoFormatReport7 = 27 Const xlRangeAutoFormatReport8 = 28 Const xlRangeAutoFormatReport9 = 29 Const xlRangeAutoFormatReport10 = 30 Const xlRangeAutoFormatClassicPivotTable = 31 Const xlRangeAutoFormatTable1 = 32 Const xlRangeAutoFormatTable2 = 33 Const xlRangeAutoFormatTable3 = 34 Const xlRangeAutoFormatTable4 = 35 Const xlRangeAutoFormatTable5 = 36 Const xlRangeAutoFormatTable6 = 37 Const xlRangeAutoFormatTable7 = 38 Const xlRangeAutoFormatTable8 = 39 Const xlRangeAutoFormatTable9 = 40 Const xlRangeAutoFormatTable10 = 41 Const xlRangeAutoFormatPTNone = 42 Const xlRangeAutoFormatNone = -4142 Const xlRangeAutoFormatSimple = -4154 Const xlAbsolute = 1 Const xlAbsRowRelColumn = 2 Const xlRelative = 4 Const xlRelRowAbsColumn = 3 Const xlTabular = 0 Const xlOutline = 1 Const xlAllAtOnce = 2 Const xlOneAfterAnother = 1 Const xlNotYetRouted = 0 Const xlRoutingComplete = 2 Const xlRoutingInProgress = 1 Const xlAutoActivate = 3 Const xlAutoClose = 2 Const xlAutoDeactivate = 4 Const xlAutoOpen = 1 Const xlDoNotSaveChanges = 2 Const xlSaveChanges = 1 Const xlExclusive = 3 Const xlNoChange = 1 Const xlShared = 2 Const xlLocalSessionChanges = 2 Const xlOtherSessionChanges = 3 Const xlUserResolution = 1 Const xlNext = 1 Const xlPrevious = 2 Const xlByColumns = 2 Const xlByRows = 1 Const xlSheetVisible = -1 Const xlSheetHidden = 0 Const xlSheetVeryHidden = 2 Const xlPinYin = 1 Const xlStroke = 2 Const xlCodePage = 2 Const xlSyllabary = 1 Const xlAscending = 1 Const xlDescending = 2 Const xlSortRows = 2 Const xlSortColumns = 1 Const xlSortLabels = 2 Const xlSortValues = 1 Const xlErrors = 16 Const xlLogical = 4 Const xlNumbers = 1 Const xlTextValues = 2 Const xlSubscribeToPicture = -4147 Const xlSubscribeToText = -4158 Const xlSummaryAbove = 0 Const xlSummaryBelow = 1 Const xlSummaryOnLeft = -4131 Const xlSummaryOnRight = -4152 Const xlSummaryPivotTable = -4148 Const xlStandardSummary = 1 Const xlTabPositionFirst = 0 Const xlTabPositionLast = 1 Const xlDelimited = 1 Const xlFixedWidth = 2 Const xlTextQualifierDoubleQuote = 1 Const xlTextQualifierNone = -4142 Const xlTextQualifierSingleQuote = 2 Const xlWBATChart = -4109 Const xlWBATExcel4IntlMacroSheet = 4 Const xlWBATExcel4MacroSheet = 3 Const xlWBATWorksheet = -4167 Const xlNormalView = 1 Const xlPageBreakPreview = 2 Const xlCommand = 2 Const xlFunction = 1 Const xlNotXLM = 3 Const xlGuess = 0 Const xlNo = 2 Const xlYes = 1 Const xlInsideHorizontal = 12 Const xlInsideVertical = 11 Const xlDiagonalDown = 5 Const xlDiagonalUp = 6 Const xlEdgeBottom = 9 Const xlEdgeLeft = 7 Const xlEdgeRight = 10 Const xlEdgeTop = 8 Const xlNoButtonChanges = 1 Const xlNoChanges = 4 Const xlNoDockingChanges = 3 Const xlToolbarProtectionNone = -4143 Const xlNoShapeChanges = 2 Const xlDialogOpen = 1 Const xlDialogOpenLinks = 2 Const xlDialogSaveAs = 5 Const xlDialogFileDelete = 6 Const xlDialogPageSetup = 7 Const xlDialogPrint = 8 Const xlDialogPrinterSetup = 9 Const xlDialogArrangeAll = 12 Const xlDialogWindowSize = 13 Const xlDialogWindowMove = 14 Const xlDialogRun = 17 Const xlDialogSetPrintTitles = 23 Const xlDialogFont = 26 Const xlDialogDisplay = 27 Const xlDialogProtectDocument = 28 Const xlDialogCalculation = 32 Const xlDialogExtract = 35 Const xlDialogDataDelete = 36 Const xlDialogSort = 39 Const xlDialogDataSeries = 40 Const xlDialogTable = 41 Const xlDialogFormatNumber = 42 Const xlDialogAlignment = 43 Const xlDialogStyle = 44 Const xlDialogBorder = 45 Const xlDialogCellProtection = 46 Const xlDialogColumnWidth = 47 Const xlDialogClear = 52 Const xlDialogPasteSpecial = 53 Const xlDialogEditDelete = 54 Const xlDialogInsert = 55 Const xlDialogPasteNames = 58 Const xlDialogDefineName = 61 Const xlDialogCreateNames = 62 Const xlDialogFormulaGoto = 63 Const xlDialogFormulaFind = 64 Const xlDialogGalleryArea = 67 Const xlDialogGalleryBar = 68 Const xlDialogGalleryColumn = 69 Const xlDialogGalleryLine = 70 Const xlDialogGalleryPie = 71 Const xlDialogGalleryScatter = 72 Const xlDialogCombination = 73 Const xlDialogGridlines = 76 Const xlDialogAxes = 78 Const xlDialogAttachText = 80 Const xlDialogPatterns = 84 Const xlDialogMainChart = 85 Const xlDialogOverlay = 86 Const xlDialogScale = 87 Const xlDialogFormatLegend = 88 Const xlDialogFormatText = 89 Const xlDialogParse = 91 Const xlDialogUnhide = 94 Const xlDialogWorkspace = 95 Const xlDialogActivate = 103 Const xlDialogCopyPicture = 108 Const xlDialogDeleteName = 110 Const xlDialogDeleteFormat = 111 Const xlDialogNew = 119 Const xlDialogRowHeight = 127 Const xlDialogFormatMove = 128 Const xlDialogFormatSize = 129 Const xlDialogFormulaReplace = 130 Const xlDialogSelectSpecial = 132 Const xlDialogApplyNames = 133 Const xlDialogReplaceFont = 134 Const xlDialogSplit = 137 Const xlDialogOutline = 142 Const xlDialogSaveWorkbook = 145 Const xlDialogCopyChart = 147 Const xlDialogFormatFont = 150 Const xlDialogNote = 154 Const xlDialogSetUpdateStatus = 159 Const xlDialogColorPalette = 161 Const xlDialogChangeLink = 166 Const xlDialogAppMove = 170 Const xlDialogAppSize = 171 Const xlDialogMainChartType = 185 Const xlDialogOverlayChartType = 186 Const xlDialogOpenMail = 188 Const xlDialogSendMail = 189 Const xlDialogStandardFont = 190 Const xlDialogConsolidate = 191 Const xlDialogSortSpecial = 192 Const xlDialogGallery3dArea = 193 Const xlDialogGallery3dColumn = 194 Const xlDialogGallery3dLine = 195 Const xlDialogGallery3dPie = 196 Const xlDialogView3d = 197 Const xlDialogGoalSeek = 198 Const xlDialogWorkgroup = 199 Const xlDialogFillGroup = 200 Const xlDialogUpdateLink = 201 Const xlDialogPromote = 202 Const xlDialogDemote = 203 Const xlDialogShowDetail = 204 Const xlDialogObjectProperties = 207 Const xlDialogSaveNewObject = 208 Const xlDialogApplyStyle = 212 Const xlDialogAssignToObject = 213 Const xlDialogObjectProtection = 214 Const xlDialogCreatePublisher = 217 Const xlDialogSubscribeTo = 218 Const xlDialogShowToolbar = 220 Const xlDialogPrintPreview = 222 Const xlDialogEditColor = 223 Const xlDialogFormatMain = 225 Const xlDialogFormatOverlay = 226 Const xlDialogEditSeries = 228 Const xlDialogDefineStyle = 229 Const xlDialogGalleryRadar = 249 Const xlDialogEditionOptions = 251 Const xlDialogZoom = 256 Const xlDialogInsertObject = 259 Const xlDialogSize = 261 Const xlDialogMove = 262 Const xlDialogFormatAuto = 269 Const xlDialogGallery3dBar = 272 Const xlDialogGallery3dSurface = 273 Const xlDialogCustomizeToolbar = 276 Const xlDialogWorkbookAdd = 281 Const xlDialogWorkbookMove = 282 Const xlDialogWorkbookCopy = 283 Const xlDialogWorkbookOptions = 284 Const xlDialogSaveWorkspace = 285 Const xlDialogChartWizard = 288 Const xlDialogAssignToTool = 293 Const xlDialogPlacement = 300 Const xlDialogFillWorkgroup = 301 Const xlDialogWorkbookNew = 302 Const xlDialogScenarioCells = 305 Const xlDialogScenarioAdd = 307 Const xlDialogScenarioEdit = 308 Const xlDialogScenarioSummary = 311 Const xlDialogPivotTableWizard = 312 Const xlDialogPivotFieldProperties = 313 Const xlDialogOptionsCalculation = 318 Const xlDialogOptionsEdit = 319 Const xlDialogOptionsView = 320 Const xlDialogAddinManager = 321 Const xlDialogMenuEditor = 322 Const xlDialogAttachToolbars = 323 Const xlDialogOptionsChart = 325 Const xlDialogVbaInsertFile = 328 Const xlDialogVbaProcedureDefinition = 330 Const xlDialogRoutingSlip = 336 Const xlDialogMailLogon = 339 Const xlDialogInsertPicture = 342 Const xlDialogGalleryDoughnut = 344 Const xlDialogChartTrend = 350 Const xlDialogWorkbookInsert = 354 Const xlDialogOptionsTransition = 355 Const xlDialogOptionsGeneral = 356 Const xlDialogFilterAdvanced = 370 Const xlDialogMailNextLetter = 378 Const xlDialogDataLabel = 379 Const xlDialogInsertTitle = 380 Const xlDialogFontProperties = 381 Const xlDialogMacroOptions = 382 Const xlDialogWorkbookUnhide = 384 Const xlDialogWorkbookName = 386 Const xlDialogGalleryCustom = 388 Const xlDialogAddChartAutoformat = 390 Const xlDialogChartAddData = 392 Const xlDialogTabOrder = 394 Const xlDialogSubtotalCreate = 398 Const xlDialogWorkbookTabSplit = 415 Const xlDialogWorkbookProtect = 417 Const xlDialogScrollbarProperties = 420 Const xlDialogPivotShowPages = 421 Const xlDialogTextToColumns = 422 Const xlDialogFormatCharttype = 423 Const xlDialogPivotFieldGroup = 433 Const xlDialogPivotFieldUngroup = 434 Const xlDialogCheckboxProperties = 435 Const xlDialogLabelProperties = 436 Const xlDialogListboxProperties = 437 Const xlDialogEditboxProperties = 438 Const xlDialogOpenText = 441 Const xlDialogPushbuttonProperties = 445 Const xlDialogFilter = 447 Const xlDialogFunctionWizard = 450 Const xlDialogSaveCopyAs = 456 Const xlDialogOptionsListsAdd = 458 Const xlDialogSeriesAxes = 460 Const xlDialogSeriesX = 461 Const xlDialogSeriesY = 462 Const xlDialogErrorbarX = 463 Const xlDialogErrorbarY = 464 Const xlDialogFormatChart = 465 Const xlDialogSeriesOrder = 466 Const xlDialogMailEditMailer = 470 Const xlDialogStandardWidth = 472 Const xlDialogScenarioMerge = 473 Const xlDialogProperties = 474 Const xlDialogSummaryInfo = 474 Const xlDialogFindFile = 475 Const xlDialogActiveCellFont = 476 Const xlDialogVbaMakeAddin = 478 Const xlDialogFileSharing = 481 Const xlDialogAutoCorrect = 485 Const xlDialogCustomViews = 493 Const xlDialogInsertNameLabel = 496 Const xlDialogSeriesShape = 504 Const xlDialogChartOptionsDataLabels = 505 Const xlDialogChartOptionsDataTable = 506 Const xlDialogSetBackgroundPicture = 509 Const xlDialogDataValidation = 525 Const xlDialogChartType = 526 Const xlDialogChartLocation = 527 Const xlDialogPhonetic = 538 Const xlDialogChartSourceData = 540 Const xlDialogSeriesOptions = 557 Const xlDialogPivotTableOptions = 567 Const xlDialogPivotSolveOrder = 568 Const xlDialogPivotCalculatedField = 570 Const xlDialogPivotCalculatedItem = 572 Const xlDialogConditionalFormatting = 583 Const xlDialogInsertHyperlink = 596 Const xlDialogProtectSharing = 620 Const xlDialogOptionsME = 647 Const xlDialogPublishAsWebPage = 653 Const xlDialogNewWebQuery = 667 Const xlDialogImportTextFile = 666 Const xlDialogExternalDataProperties = 530 Const xlDialogWebOptionsGeneral = 683 Const xlDialogWebOptionsFiles = 684 Const xlDialogWebOptionsPictures = 685 Const xlDialogWebOptionsEncoding = 686 Const xlDialogWebOptionsFonts = 687 Const xlDialogPivotClientServerSet = 689 Const xlDialogPropertyFields = 754 Const xlDialogSearch = 731 Const xlDialogEvaluateFormula = 709 Const xlDialogDataLabelMultiple = 723 Const xlDialogChartOptionsDataLabelMultiple = 724 Const xlDialogErrorChecking = 732 Const xlDialogWebOptionsBrowsers = 773 Const xlDialogCreateList = 796 Const xlDialogPermission = 832 Const xlDialogMyPermission = 834 Const xlPrompt = 0 Const xlConstant = 1 Const xlRange = 2 Const xlParamTypeUnknown = 0 Const xlParamTypeChar = 1 Const xlParamTypeNumeric = 2 Const xlParamTypeDecimal = 3 Const xlParamTypeInteger = 4 Const xlParamTypeSmallInt = 5 Const xlParamTypeFloat = 6 Const xlParamTypeReal = 7 Const xlParamTypeDouble = 8 Const xlParamTypeVarChar = 12 Const xlParamTypeDate = 9 Const xlParamTypeTime = 10 Const xlParamTypeTimestamp = 11 Const xlParamTypeLongVarChar = -1 Const xlParamTypeBinary = -2 Const xlParamTypeVarBinary = -3 Const xlParamTypeLongVarBinary = -4 Const xlParamTypeBigInt = -5 Const xlParamTypeTinyInt = -6 Const xlParamTypeBit = -7 Const xlParamTypeWChar = -8 Const xlButtonControl = 0 Const xlCheckBox = 1 Const xlDropDown = 2 Const xlEditBox = 3 Const xlGroupBox = 4 Const xlLabel = 5 Const xlListBox = 6 Const xlOptionButton = 7 Const xlScrollBar = 8 Const xlSpinner = 9 Const xlSourceWorkbook = 0 Const xlSourceSheet = 1 Const xlSourcePrintArea = 2 Const xlSourceAutoFilter = 3 Const xlSourceRange = 4 Const xlSourceChart = 5 Const xlSourcePivotTable = 6 Const xlSourceQuery = 7 Const xlHtmlStatic = 0 Const xlHtmlCalc = 1 Const xlHtmlList = 2 Const xlHtmlChart = 3 Const xlReport1 = 0 Const xlReport2 = 1 Const xlReport3 = 2 Const xlReport4 = 3 Const xlReport5 = 4 Const xlReport6 = 5 Const xlReport7 = 6 Const xlReport8 = 7 Const xlReport9 = 8 Const xlReport10 = 9 Const xlTable1 = 10 Const xlTable2 = 11 Const xlTable3 = 12 Const xlTable4 = 13 Const xlTable5 = 14 Const xlTable6 = 15 Const xlTable7 = 16 Const xlTable8 = 17 Const xlTable9 = 18 Const xlTable10 = 19 Const xlPTClassic = 20 Const xlPTNone = 21 Const xlCmdCube = 1 Const xlCmdSql = 2 Const xlCmdTable = 3 Const xlCmdDefault = 4 Const xlCmdList = 5 Const xlGeneralFormat = 1 Const xlTextFormat = 2 Const xlMDYFormat = 3 Const xlDMYFormat = 4 Const xlYMDFormat = 5 Const xlMYDFormat = 6 Const xlDYMFormat = 7 Const xlYDMFormat = 8 Const xlSkipColumn = 9 Const xlEMDFormat = 10 Const xlODBCQuery = 1 Const xlDAORecordset = 2 Const xlWebQuery = 4 Const xlOLEDBQuery = 5 Const xlTextImport = 6 Const xlADORecordset = 7 Const xlEntirePage = 1 Const xlAllTables = 2 Const xlSpecifiedTables = 3 Const xlHierarchy = 1 Const xlMeasure = 2 Const xlSet = 3 Const xlWebFormattingAll = 1 Const xlWebFormattingRTF = 2 Const xlWebFormattingNone = 3 Const xlDisplayShapes = -4104 Const xlHide = 3 Const xlPlaceholders = 2 Const xlAtTop = 1 Const xlAtBottom = 2 Const xlPivotTableVersion2000 = 0 Const xlPivotTableVersion10 = 1 Const xlPivotTableVersionCurrent = -1 Const xlPrintErrorsDisplayed = 0 Const xlPrintErrorsBlank = 1 Const xlPrintErrorsDash = 2 Const xlPrintErrorsNA = 3 Const xlPivotCellValue = 0 Const xlPivotCellPivotItem = 1 Const xlPivotCellSubtotal = 2 Const xlPivotCellGrandTotal = 3 Const xlPivotCellDataField = 4 Const xlPivotCellPivotField = 5 Const xlPivotCellPageFieldItem = 6 Const xlPivotCellCustomSubtotal = 7 Const xlPivotCellDataPivotField = 8 Const xlPivotCellBlankCell = 9 Const xlMissingItemsDefault = -1 Const xlMissingItemsNone = 0 Const xlMissingItemsMax = 32500 Const xlDone = 0 Const xlCalculating = 1 Const xlPending = 2 Const xlNoKey = 0 Const xlEscKey = 1 Const xlAnyKey = 2 Const xlSortNormal = 0 Const xlSortTextAsNumbers = 1 Const xlUpdateLinksUserSetting = 1 Const xlUpdateLinksNever = 2 Const xlUpdateLinksAlways = 3 Const xlLinkStatusOK = 0 Const xlLinkStatusMissingFile = 1 Const xlLinkStatusMissingSheet = 2 Const xlLinkStatusOld = 3 Const xlLinkStatusSourceNotCalculated = 4 Const xlLinkStatusIndeterminate = 5 Const xlLinkStatusNotStarted = 6 Const xlLinkStatusInvalidName = 7 Const xlLinkStatusSourceNotOpen = 8 Const xlLinkStatusSourceOpen = 9 Const xlLinkStatusCopiedValues = 10 Const xlWithinSheet = 1 Const xlWithinWorkbook = 2 Const xlNormalLoad = 0 Const xlRepairFile = 1 Const xlExtractData = 2 Const xlAsRequired = 0 Const xlAlways = 1 Const xlNever = 2 Const xlEvaluateToError = 1 Const xlTextDate = 2 Const xlNumberAsText = 3 Const xlInconsistentFormula = 4 Const xlOmittedCells = 5 Const xlUnlockedFormulaCells = 6 Const xlEmptyCellReferences = 7 Const xlListDataValidation = 8 Const xlDataLabelSeparatorDefault = 1 Const xlIndicatorAndButton = 0 Const xlDisplayNone = 1 Const xlButtonOnly = 2 Const xlRangeValueDefault = 10 Const xlRangeValueXMLSpreadsheet = 11 Const xlRangeValueMSPersistXML = 12 Const xlSpeakByRows = 0 Const xlSpeakByColumns = 1 Const xlFormatFromLeftOrAbove = 0 Const xlFormatFromRightOrBelow = 1 Const xlArabicNone = 0 Const xlArabicStrictAlefHamza = 1 Const xlArabicStrictFinalYaa = 2 Const xlArabicBothStrict = 3 Const xlQueryTable = 0 Const xlPivotTableReport = 1 Const xlCalculatedMember = 0 Const xlCalculatedSet = 1 Const xlHebrewFullScript = 0 Const xlHebrewPartialScript = 1 Const xlHebrewMixedScript = 2 Const xlHebrewMixedAuthorizedScript = 3 Const xlSrcExternal = 0 Const xlSrcRange = 1 Const xlSrcXml = 2 Const xlTextVisualLTR = 1 Const xlTextVisualRTL = 2 Const xlListDataTypeNone = 0 Const xlListDataTypeText = 1 Const xlListDataTypeMultiLineText = 2 Const xlListDataTypeNumber = 3 Const xlListDataTypeCurrency = 4 Const xlListDataTypeDateTime = 5 Const xlListDataTypeChoice = 6 Const xlListDataTypeChoiceMulti = 7 Const xlListDataTypeListLookup = 8 Const xlListDataTypeCheckbox = 9 Const xlListDataTypeHyperLink = 10 Const xlListDataTypeCounter = 11 Const xlListDataTypeMultiLineRichText = 12 Const xlTotalsCalculationNone = 0 Const xlTotalsCalculationSum = 1 Const xlTotalsCalculationAverage = 2 Const xlTotalsCalculationCount = 3 Const xlTotalsCalculationCountNums = 4 Const xlTotalsCalculationMin = 5 Const xlTotalsCalculationMax = 6 Const xlTotalsCalculationStdDev = 7 Const xlTotalsCalculationVar = 8 Const xlXmlLoadPromptUser = 0 Const xlXmlLoadOpenXml = 1 Const xlXmlLoadImportToList = 2 Const xlXmlLoadMapXml = 3 Const xlSmartTagControlSmartTag = 1 Const xlSmartTagControlLink = 2 Const xlSmartTagControlHelp = 3 Const xlSmartTagControlHelpURL = 4 Const xlSmartTagControlSeparator = 5 Const xlSmartTagControlButton = 6 Const xlSmartTagControlLabel = 7 Const xlSmartTagControlImage = 8 Const xlSmartTagControlCheckbox = 9 Const xlSmartTagControlTextbox = 10 Const xlSmartTagControlListbox = 11 Const xlSmartTagControlCombo = 12 Const xlSmartTagControlActiveX = 13 Const xlSmartTagControlRadioGroup = 14 Const xlListConflictDialog = 0 Const xlListConflictRetryAllConflicts = 1 Const xlListConflictDiscardAllConflicts = 2 Const xlListConflictError = 3 Const xlXmlExportSuccess = 0 Const xlXmlExportValidationFailed = 1 Const xlXmlImportSuccess = 0 Const xlXmlImportElementsTruncated = 1 Const xlXmlImportValidationFailed = 2
Como crear graficos usando ole en excel
me alegro que te haya servido el ejemplo saludos
Como crear la lib TSbrowse con Harbour y MSVC?
Hola foro, Como hago para crear la lib TSBrowse con Harbour y MSVC? Necesito hacer esto aqui en mi app. Gracias de antemano,
Como crear la lib TSbrowse con Harbour y MSVC?
que version de tsbrowse
Como crear la lib TSbrowse con Harbour y MSVC?
Carlos, Gracias por responder. Yo utilizo la versón 6.0, pero estoy deseando pasar a la versión 9.0... que me dices? Es seguro? Por el momento solo deseo crear la lib que tengo en xHarbour + BCC con Harbour + MSVC. Saludos, PS.: Estoy en linea en Google Talk
Como crear la lib TSbrowse con Harbour y MSVC?
Carlos, No he conseguido crear con lo que me enviaste pues me falta el fichero .ENV de xmate que tiene la configuración para Harbour y MSVC. Puedes enviarmela?
Como crear un reporte en formato Rtf (SIN RESOLVER)
Buenos dias.. Alguien tiene un ejemplo como crear un archivo con formato RTF que incluya por ejemplo: El Logo de la empresa Titulo y subtitulo del reporte (arial de 24ptos) Una relelacion de Productos con sus titulos de detalle en negrita de cuatro columnas : Codigo, Descripcion, Observaciones y Precio ( nota : las observaciones puede tener dos o mas lineas) Es posible esto ?? Lubin
Como crear un servicio de windows
Buenos días para todos Queremos crear un proceso que se ejecute todo el tiempo, nos gustaría hacerlo como un servicio de windows, algo similar a lo que hace mysql. Pero no sabemos cual es el camino? Asumimos que debemos tener un exe, pero como se hace para activarlo y desactivarlo, que tambien salga en la configuración del windows? [img:2tgwjlsf]https&#58;//hymplus&#46;com/forofw/servicio&#46;png[/img:2tgwjlsf]
Como crear un servicio de windows
Leandro: Mira este link a ver si te es de utilidad [url:283yhitk]https&#58;//learn&#46;microsoft&#46;com/es-es/troubleshoot/windows-client/deployment/create-user-defined-service[/url:283yhitk]
Como crear un servicio de windows
Amigo buenos días, muchas gracias por la ayuda. Buscando en el foro encontré varios post que habían hecho con anterioridad, voy a revisarlas a ver que solución encuentro. El tema que mas preocupa es que parece que todo esto esta escrito en harbour y nosotros usamos xharbour. [url:gck1uioe]https&#58;//forums&#46;fivetechsupport&#46;com/viewtopic&#46;php?f=3&t=37183&p=222119&hilit=windows+service&sid=44c61e70e378c65cc7f50edc3c430988&sid=af6c71cf3417d24e0c3c30ce5da764af#p222119[/url:gck1uioe] [url:gck1uioe]https&#58;//forums&#46;fivetechsupport&#46;com/viewtopic&#46;php?f=6&t=32147&p=188240&hilit=servicio+windows&sid=35e26bdbdaedf076522bce8d24b768c5&sid=af6c71cf3417d24e0c3c30ce5da764af#p188240[/url:gck1uioe]
Como crear un servicio de windows
Leandro: Por lo que leí en el link que te pasé, hablaba de como poner un programa (un exe) como servicio. Creo que independientemente de con qué esté hecho.
Como crear un servicio de windows
Si tienes toda la razón, voy a crear un pequeño ejecutable para hacer la prueba de funcionamiento, otro de los problemas es que necesitamos que ese servicio se instale de manera automática, sin intervención del usuario.
Como crear un servicio de windows
Para eso puedes hacerlo mediante comandos de consola de windows desde dentro de tu programa Por ejemplo con net start > servicios.txt puedes guardar los servicios que estan corriendo en windows, y ver luego el archivo servicios.txt si existe tu servicio, y sino, instalarlo. Y así cualquier otro comando de windows. Por ejemplo, si quiero saber si está instalado MySQL en la terminal, hago lo siguiente: [code=fw:oweli2z4]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'fivewin.ch'</span><br /><br /><span style="color: #00C800;">Function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> cComando , cRta<br />cComando := <span style="color: #ff0000;">"C:<span style="color: #000000;">\w</span>indows<span style="color: #000000;">\s</span>ystem32<span style="color: #000000;">\n</span>et.exe start > .<span style="color: #000000;">\s</span>ervicios.txt"</span><br />MemoWrit<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">'servicios.bat'</span>,cComando<span style="color: #000000;">&#41;</span><br />DELETE FILE servicios.txt<br />WaitRun<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">'servicios.bat'</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span><br />cRta := MemoRead<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"servicios.txt"</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">IF</span> !<span style="color: #ff0000;">"MySQL"</span>$cRta<br />   MsgStop<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"MySQL Error"</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #B900B9;">//O instalar el servicio</span><br />   <span style="color: #00C800;">ELSE</span><br />   <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"MySQL Ok"</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #B900B9;">// Seguir con tu logica</span><br /><span style="color: #00C800;">ENDIF</span><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">nil</span></div>[/code:oweli2z4]
Como crear un servicio de windows
Cesar muchas gracias por la ayuda... tu código funciono de maravilla. El problema es que parece que ese POST que me recomendaste ya es algo antiguo, o no tengo los ejecutables necesarios para hacerlo, ya que al intentar correr el ejemplo no funciona, estuve buscando dentro de la carpeta los exe, pero no están. [code=fw:2mh4d4h8]<div class="fw" id="{CB}" style="font-family: monospace;">C:\Users>C:\Program Files\<span style="color: #0000ff;">Resource</span> Kit\Instsrv.exe Notepad C:\Program Files\<span style="color: #0000ff;">Resource</span> Kit\Srvany.exe<br /><span style="color: #ff0000;">"C:<span style="color: #000000;">\P</span>rogram"</span> no se reconoce como un comando interno o externo,<br />programa o archivo por lotes ejecutable.</div>[/code:2mh4d4h8] Abusando de tu confianza y conocimiento, me podrías indicar como puedo crear el servicio con las instrucciones que sugieres. <!-- s:oops: --><img src="{SMILIES_PATH}/icon_redface.gif" alt=":oops:" title="Embarassed" /><!-- s:oops: --> De antemano gracias
Como crear un servicio de windows
Leandro, yo nunca lo he hecho, solo busque en google. Probé intentando crearlo con el siguiente comando: [code=fw:1hf04g8u]<div class="fw" id="{CB}" style="font-family: monospace;"><br />sc.exe create prueba binpath= <span style="color: #ff0000;">"c:<span style="color: #000000;">\f</span>wh21<span style="color: #000000;">\s</span>amples<span style="color: #000000;">\l</span>eandro.exe"</span><br />&nbsp;</div>[/code:1hf04g8u] Tienes que ejecutarlo con privilegios de administrador El servicio lo crea pero no pude ponerlo a correr
Como crear una DLL de funciones con FW+H
Quiero crear una DLL via fw+h. Esta Harbour preparado para crear DLL no como "contenedor de RC" sino como "contenedor de funciones". Gracias de antemano. Si tienen algun ejemplo quedaria agradecido.
Como crear una DLL de funciones con FW+H
Sí se puede. Existen tres formas. Lee el siguiente documento: <!-- m --><a class="postlink" href="http://hyperupload.com/download/01cdd50783/windll.txt.html">http://hyperupload.com/download/01cdd50 ... l.txt.html</a><!-- m -->
Como crear una DLL de funciones con FW+H
Antonio, no puedo bajar el archivo, no lo encuentra, de que otro lado puedo conseguirlo ? Gracias Miguel
Como crear una DLL de funciones con FW+H
<!-- m --><a class="postlink" href="http://rapidshare.com/files/32208291/windll.txt.html">http://rapidshare.com/files/32208291/windll.txt.html</a><!-- m -->
Como crear una DLL de funciones con FW+H
Ok, lo revisaremos Lo unico raro es que quizas el tiempo que tomaste fue algo excesivo. Saludos
Como crear una DLL de funciones con FW+H
Julio, Ese documento, junto a otros, estan disponibles en el CVS de Harbour Te contestamos el 16 de Mayo del año pasado, quizá no vistes nuestro post
Como crear una carpeta con Tftp
Hola amigos del foro, Estoy utilizando el ejemplo icopyfil.prg para cargar y descargar archivos de un sitio web y funciona bien pero no encuentro el metodo para crear una nueva carpeta. Podria alguien indicarme la manera de hacer esto (Harbour), gracias. Saludos Alvaro Urdaneta [/url]
Como crear una libreria?
Hola a todos, estoy tratando de crear una .lib de la clase tsbutton, tengo los obj, pero no encuentro aqui en el foro algo ya escrito al respecto. Si alguien sabe como hacerlo o ya la tiene como lib, desde ya agradecido. Jorge Jaurena
Como crear una libreria?
Hola Jorge... ¿Cómo andás tanto tiempo? Buscá acá en el foro el programa ExplorerLib de Andrés Reyes. Tal vez sea lo que estás queriendo hacer. Saludos, Esteban.
Como crear una libreria?
Jorge, Con Borland es tan sencillo como: c:\bcc582\bin\tlib.exe mylib.lib -+ modulo.obj
Como crear una libreria?
Antonio, todo bien con el tlib.exe, pero me complico un poco el armado de la liberia SButtonH, tengo los prg que compilo sin problemas, pero hay un BPAINT.C que tengo que incluir y el BCC582 me da error al compilarlo, esto es lo ultimo que me falta para poder estrenar mi nuevo FWH. Error E2209 C\BPAINT.C 5: Unable to open include file 'WinTen.h' Error E2209 C\BPAINT.C 7: Unable to open include file 'ClipApi.h' Error E2141 C\BPAINT.C 33: Declaration syntax error No se si esos dos .h habra que incluirlos y la lina 33 es la segunda del siguiente bloque. #ifndef __HARBOUR__ CLIPPER SBtnPaint( PARAMS ) // ( hWnd, hBitmaP, lPressed, // hFont, cText, nPos, nClrText, ClrBack, // lMouseOver, lOpaque, hBrush, nRows, lW97, // lAdjust, lMenu, lMenuPress, lFocused, // nShape, lBorder, lBox, nClip, nClrTo, lHorz, lRound ) #else HARBOUR HB_FUN_SBTNPAINT( PARAMS ) #endif Muchas Gracias. Jorge Jaurena
Como crear una libreria?
Jorge, Puedes copiar aqui el contenido de bpaint.c ? gracias <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Como crear una libreria?
No me permite ya que es demasiado largo. Te lo envio por mail. Gracias Jorge Jaurena
Como crear una libreria?
Jorge, Con estas modificaciones ha compilado bien haciendo: c:\bcc582\bin\bcc32 -c -Ic:\harbour\include -Ic:\fwh\include BPAINT.C [url:1tfi39wa]https&#58;//code&#46;google&#46;com/p/fivewin-contributions/downloads/detail?name=bpaint&#46;zip&can=2&q=[/url:1tfi39wa]
Como creo un Boton con el Color de Texto y Fondo que desee
Como crear un Boton con el Color de Texto y Fondo que desee, por ejm : Fondo Rojo con Texto Negro. Probe con el comando @ nRow, nCol BUTTON ...... y no se puede cambiar el color. Lo toma predeterminado de Windows. Master Antonio, me dice que pruebe con el comando @ nRow, nCol BTNBMP ... pero tampoco veo el atributo COLOR. Gracias por la atencion prestada, Regards, Saludos,
Como creo un Boton con el Color de Texto y Fondo que desee
@ nRow, nCol BTNBMP oBtn ... oBtn:SetColor( nColorTexto, nClrFondo )
Como creo un Boton con el Color de Texto y Fondo que desee
[quote="Antonio Linares":38mllowe]@ nRow, nCol BTNBMP oBtn ... oBtn:SetColor( nColorTexto, nClrFondo )[/quote:38mllowe] MAESTRO ANTONIO... PUEDO HACER ESTO CON BUTTONBMP TANBIÉN??? USO DESDE RECURSOS DEL WORKSHOP.EXE the best. Gracias, Regards, saludos.
Como creo una dll con mi codigo y como lo uso con otros exes
Amigso tengo un funcion por ejemplo Func sumar( a , b ) retu(a+b) Como hago para pasar esa funcion a un dll y luego como invoco ese dll desde otro ejecutable sera algo como DLL function sumar( a , b ) Ahora esto es mas rapido que hacer en un ejecutable y pasarle parametros con . Gracias por la ayuda la necesida de crear una dll
Como creo una dll con mi codigo y como lo uso con otros exes
Vladimir, Puedes crear dos tipos de DLL: 1: Solo contiene pcode y usa la "maquina virtual" de Harbour contenida en el EXE. 2: Es una DLL autocontenida que puede usarse desde cualquier EXE, escrito en cualquier lenguaje. Cual de esas dos opciones te interesa ? Existe una tercera opcion que es usar un EXE que solo contiene pcode y usa la "maquina virtual" que esta dentro de una DLL. Son EXEs muy pequenos, ya que solo contienen pcode.
Como creo una dll con mi codigo y como lo uso con otros exes
Gracias por contestar Esta seria la opcion que me interesa. 2: Es una DLL autocontenida que puede usarse desde cualquier EXE, escrito en cualquier lenguaje. Muchas Gracias
Como creo una dll con mi codigo y como lo uso con otros exes
Vladimir, La opción 2 la hemos comentado recientemente a fondo en: <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=14863">viewtopic.php?f=3&t=14863</a><!-- l --> Revisa FWH\samples\babu.prg y babudll.prg
Como creo una dll con mi codigo y como lo uso con otros exes
Buenas Antonio y resto Disculpen responder a un tema tan viejo pero estoy buscando información sobre el punto 1 y no la localizo: 1: Solo contiene pcode y usa la "maquina virtual" de Harbour contenida en el EXE. Encontre el tema: <!-- l --><a class="postlink-local" href="http://fivetechsupport.com/forums/viewtopic.php?f=6&t=15374&start=15">viewtopic.php?f=6&t=15374&start=15</a><!-- l --> pero guao al parecer hay que programar practicamente en C y no es lo que busco. Mi idea es tener funciones en DLL que van a ejecutarse unicamete con mi EXE. Esas funciones deben poder llamar otras funciones que estan en el EXE, o sea, que el codigo de la DLL se comporte como si fuese parte del mismo EXE Gracias de antemano por su tiempo.
Como creo una dll con mi codigo y como lo uso con otros exes
hidroxid. Todo esto lo tome de samples hace algunos meses y estuve jugando un poco. Espero te sea de alguna utilidad. [code=fw:1dwyozr6]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #B900B9;">// Build a DLL from this code using: buildhd.bat mydll</span><br /><span style="color: #B900B9;">// Please review TESTMYDL.prg to see how to use this DLL.</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Inside DLL main()"</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><span style="color: #00C800;">function</span> OneParam<span style="color: #000000;">&#40;</span> x <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span> x <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> &nbsp; <br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><span style="color: #00C800;">function</span> OtraMas<span style="color: #000000;">&#40;</span> x <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">local</span> cTxt := x+<span style="color: #ff0000;">" &nbsp;(un texto recibido mas uno agregado)"</span><br /><br />&nbsp; &nbsp;MsgStop<span style="color: #000000;">&#40;</span> cTxt <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> &nbsp; <br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00D7D7;">#pragma</span> BEGINDUMP <br /><br /><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <hbapi.h> <br /><span style="color: #00D7D7;">#include</span> <hbapiitm.h> <br /><br />__declspec<span style="color: #000000;">&#40;</span> dllexport <span style="color: #000000;">&#41;</span> LONG pascal DOPROC<span style="color: #000000;">&#40;</span> char * cProcName, char * cParam <span style="color: #000000;">&#41;</span> <br /><span style="color: #000000;">&#123;</span> <br />&nbsp; &nbsp;PHB_ITEM pItem = hb_itemPutC<span style="color: #000000;">&#40;</span> <span style="color: #00C800;">NULL</span>, cParam <span style="color: #000000;">&#41;</span>; <br /><br />&nbsp; &nbsp;<span style="color: #00C800;">if</span><span style="color: #000000;">&#40;</span> cProcName <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #000000;">&#123;</span><br />&nbsp; &nbsp; &nbsp; hb_itemDoC<span style="color: #000000;">&#40;</span> cProcName, <span style="color: #000000;">1</span>, <span style="color: #000000;">&#40;</span> PHB_ITEM <span style="color: #000000;">&#41;</span> pItem, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span>; <br />&nbsp; &nbsp; &nbsp; hb_itemRelease<span style="color: #000000;">&#40;</span> pItem <span style="color: #000000;">&#41;</span>; <br />&nbsp; &nbsp;<span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">else</span> &nbsp; <br />&nbsp; &nbsp; &nbsp; MessageBox<span style="color: #000000;">&#40;</span> <span style="color: #000000;">0</span>, <span style="color: #ff0000;">"inside the DLL"</span>, <span style="color: #ff0000;">"DOPROC"</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span>;<br /><br />&nbsp; &nbsp;<span style="color: #00C800;">return</span> <span style="color: #000000;">0</span>; <br /><span style="color: #000000;">&#125;</span> <br /><br /><span style="color: #00D7D7;">#pragma</span> ENDDUMP <br /><br />&nbsp;</div>[/code:1dwyozr6] [code=fw:1dwyozr6]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #B900B9;">// Calling a Harbour DLL</span><br /><span style="color: #B900B9;">// Please review samples\MyDLL.prg and build it before</span><br /><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"FiveWin.ch"</span> <br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <br /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> cString := <span style="color: #ff0000;">"Hola a todo el mundo!"</span><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> c1 := <span style="color: #ff0000;">"Primer texto"</span><br /><br />&nbsp; &nbsp;DOPROC<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"ONEPARAM"</span>, cString <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;DOPROC<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"OTRAMAS"</span>, c1 <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Todo correcto, hasta el momento."</span> <span style="color: #000000;">&#41;</span> <br />&nbsp; &nbsp;<br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br />DLL <span style="color: #00C800;">FUNCTION</span> DOPROC<span style="color: #000000;">&#40;</span> cProc AS LPSTR, cText AS LPSTR <span style="color: #000000;">&#41;</span> AS LONG PASCAL LIB <span style="color: #ff0000;">"MYDLL.dll"</span></div>[/code:1dwyozr6] [code=fw:1dwyozr6]<div class="fw" id="{CB}" style="font-family: monospace;">@ECHO OFF<br />CLS<br />ECHO ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿<br />ECHO ³ FiveWin <span style="color: #00C800;">for</span> xHarbour <span style="color: #000000;">12.04</span> - Apr. <span style="color: #000000;">2012</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;xHarbour development <span style="color: #0000ff;">power</span> ³Ü<br />ECHO ³ <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> FiveTech, <span style="color: #000000;">1993</span><span style="color: #000000;">-2012</span> &nbsp; &nbsp; <span style="color: #00C800;">for</span> Microsoft Windows 9X/NT/200X/ME/XP/Vista/<span style="color: #000000;">7</span> ³Û<br />ECHO ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙÛ<br />ECHO ÿ ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß<br /><br /><span style="color: #00C800;">if</span> A%<span style="color: #000000;">1</span> == A GOTO :<span style="color: #000000;">SINTAX</span><br /><span style="color: #00C800;">if</span> NOT EXIST %<span style="color: #000000;">1</span>.prg GOTO :<span style="color: #000000;">NOEXIST</span><br /><br />ECHO Compiling...<br /><br /><span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%FWDIR%"</span> == <span style="color: #ff0000;">""</span> set FWDIR=C:\FWH1204\<br /><span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%XHDIR%"</span> == <span style="color: #ff0000;">""</span> set XHDIR=c:\xharbour_BCC582_20120330<br />rem <span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%2"</span> == <span style="color: #ff0000;">"/b"</span> set GT=gtwin<br />rem <span style="color: #00C800;">if</span> not <span style="color: #ff0000;">"%2"</span> == <span style="color: #ff0000;">"/b"</span> set GT=gtgui<br />set GT=gtgui<br /><br />set hdir=%XHDIR%<br />set hdirl=%hdir%\lib<br />set bcdir=c:\bcc582<br />set fwh=%FWDIR%<br /><br />%hdir%\bin\harbour %<span style="color: #000000;">1</span> /n /i%fwh%\include;%hdir%\include /w /p %<span style="color: #000000;">2</span> %<span style="color: #000000;">3</span> > comp.log<br /><span style="color: #00C800;">IF</span> ERRORLEVEL <span style="color: #000000;">1</span> GOTO COMPILEERRORS<br />@type comp.log<br /><br />echo -O2 -e%<span style="color: #000000;">1</span>.exe -I%hdir%\include -I%bcdir%\include %<span style="color: #000000;">1</span>.c > b32.bc<br />%bcdir%\bin\bcc32 -M -c -v @b32.bc<br />:<span style="color: #000000;">ENDCOMPILE</span><br /><br /><span style="color: #00C800;">IF</span> EXIST %<span style="color: #000000;">1</span>.rc %bcdir%\bin\brc32 -r -I%bcdir%\include %<span style="color: #000000;">1</span><br /><br />echo %bcdir%\lib\c0w32.obj + > b32.bc<br />echo %<span style="color: #000000;">1</span>.obj, + >> b32.bc<br />echo %<span style="color: #000000;">1</span>.exe, + >> b32.bc<br />echo %<span style="color: #000000;">1</span>.map, + >> b32.bc<br />echo %fwh%\lib\Fivehx.lib %fwh%\lib\FiveHC.lib + >> b32.bc<br />echo %hdirl%\rtl.lib + >> b32.bc<br />echo %hdirl%\vm.lib + >> b32.bc<br />echo %hdirl%\%GT%.lib + >> b32.bc<br />echo %hdirl%\lang.lib + >> b32.bc<br />echo %hdirl%\macro.lib + >> b32.bc<br />echo %hdirl%\rdd.lib + >> b32.bc<br />echo %hdirl%\dbfntx.lib + >> b32.bc<br />echo %hdirl%\dbfcdx.lib + >> b32.bc<br />echo %hdirl%\dbffpt.lib + >> b32.bc<br />echo %hdirl%\hbsix.lib + >> b32.bc<br />echo %hdirl%\debug.lib + >> b32.bc<br />echo %hdirl%\common.lib + >> b32.bc<br />echo %hdirl%\pp.lib + >> b32.bc<br />echo %hdirl%\pcrepos.lib + >> b32.bc<br />echo %hdirl%\ct.lib + >> b32.bc<br />echo %hdirl%\zlib.lib + >> b32.bc<br />echo %hdirl%\hbzip.lib + >> b32.bc<br />echo %hdirl%\png.lib + >> b32.bc<br /><br />rem Uncomment these two lines <span style="color: #0000ff;">to</span> use Advantage RDD<br />rem echo %hdir%\lib\rddads.lib + >> b32.bc<br />rem echo %hdir%\lib\Ace32.lib + >> b32.bc<br /><br />echo %bcdir%\lib\cw32.lib + >> b32.bc<br />echo %bcdir%\lib\import32.lib + >> b32.bc<br />echo %bcdir%\lib\uuid.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\odbc32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\rasapi32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\nddeapi.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\msimg32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\psapi.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\gdiplus.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\iphlpapi.lib, >> b32.bc<br /><br /><span style="color: #00C800;">IF</span> EXIST %<span style="color: #000000;">1</span>.res echo %<span style="color: #000000;">1</span>.res >> b32.bc<br /><br />rem uncomment this line <span style="color: #0000ff;">to</span> use the debugger and comment the following one<br /><span style="color: #00C800;">if</span> %GT% == gtwin %bcdir%\bin\ilink32 -Gn -Tpe -s -v @b32.bc<br /><span style="color: #00C800;">IF</span> ERRORLEVEL <span style="color: #000000;">1</span> GOTO LINKERROR<br /><span style="color: #00C800;">if</span> %GT% == gtgui %bcdir%\bin\ilink32 -Gn -aa -Tpe -s -v @b32.bc<br /><span style="color: #00C800;">IF</span> ERRORLEVEL <span style="color: #000000;">1</span> GOTO LINKERROR<br />ECHO * Application successfully built *<br />%<span style="color: #000000;">1</span><br />GOTO EXIT<br />ECHO<br /><br />rem delete temporary files<br />@del %<span style="color: #000000;">1</span>.c<br /><br />:<span style="color: #000000;">COMPILEERRORS</span><br />@type comp.log<br />ECHO * Compile errors *<br />GOTO EXIT<br /><br />:<span style="color: #000000;">LINKERROR</span><br />ECHO * Linking errors *<br />GOTO EXIT<br /><br />:<span style="color: #000000;">SINTAX</span><br />ECHO &nbsp; &nbsp;SYNTAX: <span style="color: #000000;">Build</span> <span style="color: #000000;">&#91;</span>Program<span style="color: #000000;">&#93;</span> &nbsp; &nbsp; <span style="color: #000000;">&#123;</span>-- No especifiques la extensi¢n PRG<br />ECHO &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span>-- Don<span style="color: #ff0000;">'t specify .PRG extension<br />GOTO EXIT<br /><br />:NOEXIST<br />ECHO The specified PRG %1 does not exist<br /><br />:EXIT<br /><br />PAUSE</span></div>[/code:1dwyozr6] [code=fw:1dwyozr6]<div class="fw" id="{CB}" style="font-family: monospace;"><br />@ECHO OFF<br />CLS<br />ECHO ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿<br />ECHO ³ FiveWin <span style="color: #00C800;">for</span> xHarbour <span style="color: #000000;">11.09</span> - Sep. <span style="color: #000000;">2012</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;xHarbour development <span style="color: #0000ff;">power</span> ³Ü<br />ECHO ³ <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> FiveTech, <span style="color: #000000;">1993</span><span style="color: #000000;">-2012</span> &nbsp; &nbsp; <span style="color: #00C800;">for</span> Microsoft Windows 9X/NT/200X/ME/XP/Vista/<span style="color: #000000;">7</span> ³Û<br />ECHO ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙÛ<br />ECHO ÿ ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß<br /><br /><span style="color: #00C800;">if</span> A%<span style="color: #000000;">1</span> == A GOTO :<span style="color: #000000;">SINTAX</span><br /><span style="color: #00C800;">if</span> NOT EXIST %<span style="color: #000000;">1</span>.prg GOTO :<span style="color: #000000;">NOEXIST</span><br /><br />ECHO Building <span style="color: #00C800;">self</span> contained DLL<br />ECHO Compiling...<br /><br /><span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%FWDIR%"</span> == <span style="color: #ff0000;">""</span> set FWDIR=c:\fwh1204\<br /><span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%XHDIR%"</span> == <span style="color: #ff0000;">""</span> set XHDIR=c:\xharbour_bcc582_20120330<br />rem <span style="color: #00C800;">if</span> <span style="color: #ff0000;">"%2"</span> == <span style="color: #ff0000;">"/b"</span> set GT=gtwin<br />rem <span style="color: #00C800;">if</span> not <span style="color: #ff0000;">"%2"</span> == <span style="color: #ff0000;">"/b"</span> set GT=gtgui<br />set GT=gtgui<br /><br />set hdir=%XHDIR%<br />set hdirl=%hdir%\lib<br />set bcdir=c:\bcc582<br />set fwh=%FWDIR%<br /><br />%hdir%\bin\harbour %<span style="color: #000000;">1</span> /n /i%fwh%\include;%hdir%\include /w /p %<span style="color: #000000;">2</span> %<span style="color: #000000;">3</span> > comp.log<br /><span style="color: #00C800;">IF</span> ERRORLEVEL <span style="color: #000000;">1</span> GOTO COMPILEERRORS<br />@type comp.log<br /><br />echo -O2 -e%<span style="color: #000000;">1</span>.exe -I%hdir%\include -I%bcdir%\include %<span style="color: #000000;">1</span>.c > b32.bc<br />%bcdir%\bin\bcc32 -M -c -v @b32.bc<br />:<span style="color: #000000;">ENDCOMPILE</span><br /><br /><span style="color: #00C800;">IF</span> EXIST %<span style="color: #000000;">1</span>.rc %bcdir%\bin\brc32 -r -I%bcdir%\include %<span style="color: #000000;">1</span><br /><br />echo %bcdir%\lib\c0d32.obj + > b32.bc<br />echo %<span style="color: #000000;">1</span>.obj, + >> b32.bc<br />echo %<span style="color: #000000;">1</span>.dll, + >> b32.bc<br />echo %<span style="color: #000000;">1</span>.map, + >> b32.bc<br />echo %fwh%\lib\Fivehx.lib %fwh%\lib\FiveHC.lib + >> b32.bc<br />echo %hdirl%\rtl.lib + >> b32.bc<br />echo %hdirl%\vm.lib + >> b32.bc<br />echo %hdirl%\%GT%.lib + >> b32.bc<br />echo %hdirl%\lang.lib + >> b32.bc<br />echo %hdirl%\macro.lib + >> b32.bc<br />echo %hdirl%\rdd.lib + >> b32.bc<br />echo %hdirl%\dbfntx.lib + >> b32.bc<br />echo %hdirl%\dbfcdx.lib + >> b32.bc<br />echo %hdirl%\dbffpt.lib + >> b32.bc<br />echo %hdirl%\hbsix.lib + >> b32.bc<br />echo %hdirl%\debug.lib + >> b32.bc<br />echo %hdirl%\common.lib + >> b32.bc<br />echo %hdirl%\pp.lib + >> b32.bc<br />echo %hdirl%\pcrepos.lib + >> b32.bc<br />echo %hdirl%\ct.lib + >> b32.bc<br />echo %hdirl%\zlib.lib + >> b32.bc<br />echo %hdirl%\hbzip.lib + >> b32.bc<br /><br />rem Uncomment these two lines <span style="color: #0000ff;">to</span> use Advantage RDD<br />rem echo %hdir%\lib\rddads.lib + >> b32.bc<br />rem echo %hdir%\lib\Ace32.lib + >> b32.bc<br /><br />echo %bcdir%\lib\cw32.lib + >> b32.bc<br />echo %bcdir%\lib\import32.lib + >> b32.bc<br />echo %bcdir%\lib\uuid.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\odbc32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\rasapi32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\nddeapi.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\msimg32.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\psapi.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\gdiplus.lib + >> b32.bc<br />echo %bcdir%\lib\psdk\iphlpapi.lib, >> b32.bc<br /><br /><span style="color: #00C800;">IF</span> EXIST %<span style="color: #000000;">1</span>.res echo %<span style="color: #000000;">1</span>.res >> b32.bc<br /><br /><span style="color: #00C800;">if</span> %GT% == gtgui %bcdir%\bin\ilink32 -Gn -Tpd -s -v @b32.bc<br /><span style="color: #00C800;">IF</span> ERRORLEVEL <span style="color: #000000;">1</span> GOTO LINKERROR<br />ECHO * DLL successfully built *<br />GOTO EXIT<br />ECHO<br /><br />rem delete temporary files<br />@del %<span style="color: #000000;">1</span>.c<br /><br />:<span style="color: #000000;">COMPILEERRORS</span><br />@type comp.log<br />ECHO * Compile errors *<br />GOTO EXIT<br /><br />:<span style="color: #000000;">LINKERROR</span><br />ECHO * Linking errors *<br />GOTO EXIT<br /><br />:<span style="color: #000000;">SINTAX</span><br />ECHO &nbsp; &nbsp;SYNTAX: <span style="color: #000000;">Build</span> <span style="color: #000000;">&#91;</span>Program<span style="color: #000000;">&#93;</span> &nbsp; &nbsp; <span style="color: #000000;">&#123;</span>-- No especifiques la extensi¢n PRG<br />ECHO &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span>-- Don<span style="color: #ff0000;">'t specify .PRG extension<br />GOTO EXIT<br /><br />:NOEXIST<br />ECHO The specified PRG %1 does not exist<br /><br />:EXIT<br /><br />PAUSE</span></div>[/code:1dwyozr6]
Como creo una librerias con MinGW gcc y Visual Studio
Saludos al forum Com creo una libreria con MinGW gcc y Visual Studio Gracias
Como creo una librerias con MinGW gcc y Visual Studio
Ruben, sabes hacerlo usando Borland ? Con estos compiladores es igual, salvo que el manejador de librerias de mingw es ar.exe: ...\bin\ar rc libreria modulo.obj y para Visual Studio: ...\lib.exe lib\libreria out\libreria modulo.obj
Como criar um WebService
Alguem tem algum exemplo de como criar um WebService em Harbour ou xHarbour? Não é para conectar em um WebService, mas sim criar um novo, que consome metodos HTTP GET e POST.
Como criar um WebService
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?p=152371#p152371">viewtopic.php?p=152371#p152371</a><!-- l -->
Como de puede cargar varios DLL.
Como de puede cargar varios DLL. Actualmente cargo Uno asi SET RESOURCES TO "winsistema.dll"
Como de puede cargar varios DLL.
Ruben, Puedes cargar otra DLL usando el mismo comando nuevamente: SET RESOURCES TO "otra.dll"
Como de puede cargar varios DLL.
Antonio Antes yo intente asi, pero no mantiene las dos. no se puede obtener los recursos de la primera. Saludos, Adhemar
Como de puede cargar varios DLL.
No lo he probado. ¿Y si se intenta asi?: hDll1:=LoadLibray("Libdll1") hDll2:=LoadLibray("Libdll2") FreeLibrary("hDll1") FreeLibrary("hDll2") Saludos.
Como de puede cargar varios DLL.
Saludos, no seria mas facil si las cargas a un ARRAY aLib[n] aLib[1]:=LoadLibray("Libdll1") aLib[2]:=LoadLibray("Libdll2") aLib[n]:=LoadLibray("Libdlln")
Como de puede cargar varios DLL.
Holas,,, SET RESOURCES TO "una.dll", "otra.dll", "unamas.dll" Salu2
Como de puede cargar varios DLL.
Si, asi es, es la forma correcta de usar varias DLLs simultaneamente, gracias Willi! <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Como de puede cargar varios DLL.
Como indica Willi no funciona Sólo se pueden obtener los recursos de la primera. Saludos, Adhemar
Como de puede cargar varios DLL.
Si solamente se pueden obtener los recursos de la primera. segun la prueba que hice, Att. Ruben Dario Saludos,
Como de puede cargar varios DLL.
Hice pruebas y efectivamente estan activos los de la ultima DLL cargada.
Como de puede cargar varios DLL.
Holas,,, recuerdo haber usado de este modo creo con clipper...SET RESOURCES TO "una.dll", "otra.dll", "unamas.dll", en todo caso esto si funciona: [code=fw:3de3q8m4]<div class="fw" id="{CB}" style="font-family: monospace;"><br />SET <span style="color: #0000ff;">RESOURCE</span> <span style="color: #0000ff;">TO</span> primera.dll<br />Funcion xxxxxxx<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />...<br />..<br />.<br />hOldRes := GetResources<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">// guardamos la dll inicial</span><br />SetResources<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"nuevadll.dll"</span><span style="color: #000000;">&#41;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">// cargamos una nueva</span><br />. &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #B900B9;">// utilizamos la nueva dll</span><br />..<br />...<br />SetResources<span style="color: #000000;">&#40;</span>hOldRes<span style="color: #000000;">&#41;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #B900B9;">// volvemos a cargar la dll inicial</span><br />.<br />..<br />...<br />&nbsp;</div>[/code:3de3q8m4]
Como definir el tamaño del papel y Oridentaciion al REPORTE
Como se Define el tipo de papel que voy a Utilizar si es Carta o Oficio. La Orientacion si es Horizontal o Vertical , y direccionarlo a una impresora especifica en este caso tengo una red y son varias impresoras.
Como definir el tamaño del papel y Oridentaciion al REPORTE
Mas Informacion <!-- m --><a class="postlink" href="http://fivetechsoft.com/forums/viewtopic.php?t=5795&highlight=papel">http://fivetechsoft.com/forums/viewtopi ... ight=papel</a><!-- m -->
Como definir/crear/inicializar variable desde una función
La idea es: fMyFunc_C (“MiTabla”) ?MiTabla->MiCampo1 ?MiCampo2 # Pragma BEGINDUMP HB_FUNC (fMyFunc_C) { Que debo hacer acá para que se generen/creen/definan las variables MiCampo1 y MiCampo2, y al retornar de esta función no de error, variable MiCampo1 no exite. } # Pragma ENDDUMP Se agradece cualquier ayuda.
Como definir/crear/inicializar variable desde una función
Ya estoy revisando el código de Jorge para buscarle la solución <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Como dejar el sistema en ISO-8859-1
¿Al exportar que? ¿En que formato? ¿Donde lo ves y no se ve como debiera?
Como dejar el sistema en ISO-8859-1
Hola a todos ; Necesito una orientacion, como puedo setear para que al compilar el programa, quede creado en formato ISO-8859-1. Requiero hacer esto en xHarbour, pero no se que funciones hay que poner al inicio del programa, alguien las sabe ? Esto lo necesito para que los archivos que exporte el sistema en texto plano , vayan también en ese formato y en español. Que reconozcan los caracteres como Ñ, ñ , y acentos . Me está provocando problemas al exportar. <!-- s:( --><img src="{SMILIES_PATH}/icon_sad.gif" alt=":(" title="Sad" /><!-- s:( --> <!-- s:( --><img src="{SMILIES_PATH}/icon_sad.gif" alt=":(" title="Sad" /><!-- s:( --> Saludos,
Como dejar el sistema en ISO-8859-1
Hola Carlos , gracias por responder. Estoy creando unos xml, los cuales en su encabezado llevan definido el <?xml version="1.0" encoding="ISO-8859-1"?> , pero aun asi, me reclaman que no va ese formato , por eso para asegurarme requiero que mi ejecutable haya sido tambien creado en este formato ISO-8859-1. Buscando en un foro del google en ingles , encontre estas funciones , REQUEST HB_LANG_DE // request German language HB_SetCodePage( "DE" ) // Queries or changes the current code page. HB_LangSelect( "DE" ) // Select a specific nation message module Set Date German // Assigns a date format GERMAN dd.mm.yy Pero cuales son los comandos para dejarlos en español y en esa ISO que menciono. Si alguien sabe, que lo comente por favor. Saludos,
Como dejar el sistema en ISO-8859-1
Que significa "no va"? Ellos no pueden leer ese encoding? El contenido del fichero no esta realmente en ISOxxxx? no entiendo cual es el problema concreto.
Como dejar el sistema en ISO-8859-1
Carlos , me dicen que aunque el archivo tiene su encoding, por no estar mi ejecutable creado en este mismo formato, lo que exporta , ( en este caso el xml ), igual se ve afectado , por ello requiero asegurarme que mi ejecutable, este en el mismo formato. No se si ahora me explico mejor.
Como dejar el sistema en ISO-8859-1
jcaro, No necesariamente tienes que colocar tu EXE con ese tipo de codificacion. El cambiar la codificacion solo al momento de crear el XML, despues regresar la codificacion a como la tenias inicialmente. y efectivamente debes usar las funciones que comentas anteriormente.
Como dejar el sistema en ISO-8859-1
Completamente de acuerdo con Willy, no tiene nada que ver. El problema no se puede resolver si no vemos un ejemplo para saber donde está el problema. Lo que te dicen los alemanes dice donde está el problema, pero a partir de ahí solo estamos especulando, solo se puede responder si muestras algo de código, un ejemplo del fichero o algo de donde tirar, seguir con especulaciones me parece poco razonable. Muéstranos algo. Si subes un fichero de ejemplo podremos saber si hay algo bien o mal. Si ellos lo usna en UTF-8 te remito a la solución de las funciones de conversión, que es la solución que parece ser la más adecuada.
Como dejar el sistema en ISO-8859-1
Gracias por las respuestas, lo voy a resolver solo desde el XML. Atte.,
Como desabilitar BarTitle de uma Dialog=
Ola. Bom dia. Tres Questoes : 1 - Como desbilitar a BarTitle de uma Dialog? Pretendo fazer o meu proprio teclado.... numa dialog sem bartitle. 2 Num get é possivel executar uma acção quando clicka nesse get ? Uma clausula do tipo "GotFocus e LostFocus" ? Assim quando o operador clica num determinado get poderia activar/desactivar automaticamente um teclado personalizado. Isto é possivel em FWPPC? 3 - Como desactivar o Icon do teclado do Win Mobile na Barra inferior? Desculpem tantas questoes, mas é que comecei agora a desnvolver com FWPPC e tenho muito pouco tempo. Qualquer ajuda é muito preciosa. Muito obrigado. Cumprimento
Como desabilitar BarTitle de uma Dialog=
Pedro, 1) Si el diálogo lo creas desde código puedes usar la claúsula STYLE: [code=fw:33hhgjr2]<div class="fw" id="{CB}" style="font-family: monospace;"><br />&nbsp; &nbsp;<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;">10</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">20</span>, <span style="color: #000000;">40</span> ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Dialog"</span> <span style="color: #0000ff;">STYLE</span> nOr<span style="color: #000000;">&#40;</span> WS_VISIBLE, WS_OVERLAPPEDWINDOW <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:33hhgjr2] Si el diálogo está definido en tu fichero RC de recursos, cámbiale el estilo para sólo use: WS_VISIBLE, WS_OVERLAPPEDWINDOW
Como desabilitar BarTitle de uma Dialog=
2) Todos los controles admiten estos codeblocks: oControl:bGotFocus y oControl:bLostFocus asi, puedes hacer: oGet:bLostFocus = { || ... tu código } oGet:bGotFocus = { || ... tu código }
Como desabilitar BarTitle de uma Dialog=
Pedro, 3) Puedes usar la función SHFullScreen( hWnd, nMode ) [url:20v7yzoe]http&#58;//msdn&#46;microsoft&#46;com/en-us/library/aa453694&#46;aspx[/url:20v7yzoe] #define SHFS_HIDESIPBUTTON 8 SHFullScreen( oWnd:hWnd, SHFS_HIDESIPBUTTON )
Como desabilitar BarTitle de uma Dialog=
Antonio. Muito Obrigado pelo excelente apoio que me esta a ser muito importante. Vou ja experimentar as tuas dicas. Cordiais cumprimentos.
Como desabilitar BarTitle de uma Dialog=
Antonio, Desculpa insistir mas é que tentei usar en mi codigo: [code=fw:1muhoutv]<div class="fw" id="{CB}" style="font-family: monospace;"><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;">10</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">20</span>, <span style="color: #000000;">40</span> ;<br />      <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Dialog"</span> <span style="color: #0000ff;">STYLE</span> nOr<span style="color: #000000;">&#40;</span> WS_VISIBLE, WS_OVERLAPPEDWINDOW <span style="color: #000000;">&#41;</span><br /><br /> </div>[/code:1muhoutv] Compila bien. mas en elprograma da un erro : WS_VISIBLE - vARIABLE DOES NOT EXIST. Falta-me algum define ou include? Gracias
Como desabilitar BarTitle de uma Dialog=
Hola Peter agrega al principio del prg #define WS_VISIBLE 0x10000000
Como desabilitar BarTitle de uma Dialog=
Daniel. Muchas Gracias por feed back. Cumprimentos.
Como desabilitar BarTitle de uma Dialog=
Daniel. desculpa e para : WS_OVERLAPPEDWINDOW qual o valor de define? onde puedo consultar estas variaveis? Gracias.
Como desabilitar BarTitle de uma Dialog=
Peter.. busca en \include\winapi.ch alli estan todos los valores... prueba con agregar esa cabecera en el prg #include "winapi.ch" sino te funciona agrega los valores de cada define
Como desabilitar el Return por omisión en un dialogo
En alguna parte del foro ya se contesto esto, pero no lo ubico; quisiera saber como puedo hacer para desabilitar que en un dialogo al presionar ENTER en cualquier control asuma que se presiono el boton "Aceptar" o "OK". Esto porque requiero que en un Listbox que esta en el dialogo al presionar ENTER se ejecute una función, pero siempre se ejecuta el Button por omisión. Saludos Fernando Espinoza
Como desabilitar el Return por omisión en un dialogo
Fernando: Eso lo debes solucionar en los recursos, en el botón que se activa cuando oprimes ENTER cambia la propiedad DEFAULT PUSHBUTTON por PUSHBUTTON. Saludos