Posts by b8engl • 303 points
23 posts
-
1
votes1
answer21
viewsA: If existing category adds in Menu - Woocommerce 3.6.4
The correct term is: term_exists that is to say, if( term_exists( 'samsung', 'product_cat' ) )
-
0
votes1
answer21
viewsQ: If existing category adds in Menu - Woocommerce 3.6.4
I’m using the hierarchy: Samsung>S9 Plus, Category A The code only works at the following address: https://paginaweb.pt/categoria-produto/s9-plus The code is this: // adiciona produto ao menu se…
-
4
votes1
answer461
viewsQ: Update cart status without leaving the page | Woocommerce 3.4+
<?php global $woocommerce; if ( sizeof( WC()->cart->get_cart() ) < 1 ) { ?> <div style="width: 25%;" class="footer-section <?php echo esc_html($woo);?>"> <a…
-
0
votes0
answers176
viewsQ: Check if cart is NOT empty Woocommerce 3.4+
I intend to check if the cart is NOT empty, but I’m not getting it! Can someone help me, please? . add_action( 'wp_footer', 'redirecionar' ); function redirecionar(){ global $woocommerce; if (…
-
0
votes1
answer137
viewsQ: Redirect if basket is empty | Woocommerce 3+
add_action( 'wp_footer', 'redirecionar' ); function redirecionar(){ global $woocommerce; if ( is_page('carrinho-de-compras') and !sizeof($woocommerce->cart->cart_contents) ) { wp_redirect(…
-
3
votes3
answers528
viewsQ: How to deactivate CTRL+C in batch?
You can deactivate the CTRL+C command in batch?
-
0
votes1
answer524
viewsQ: How to put space before the SET/P variable in Batch?
I intend to set the variable in the middle of the screen, but I can’t place it! |____não_funciona____|set /p variável=um |____funciona____|%variável% Thanks in advance!…
-
1
votes1
answer95
viewsQ: Delete an executable file ( .exe ) after finishing without knowing its location?
The bat file has been converted to executable. The command del "%~f0" does not work! You will need to finish running the executable first taskkill /f "nome_do_executável.exe" and only then eliminate…
-
4
votes1
answer2153
viewsQ: A Macro to run all Modules?
I have several modules and within these modules I have several subroutines with some functions on separate sheets. I intend to run macros separately! That is, start the next subroutine after…
-
1
votes1
answer399
viewsA: Search column P for a value > or < and calculate this value in cell U?
REPLY: Cells(i, 26). Select Search column P for a value superior or inferior and calculate this value in cell Z? Sub teste() Application.ScreenUpdating = False rng = Columns(16).End(xlDown).Row For…
-
3
votes1
answer399
viewsQ: Search column P for a value > or < and calculate this value in cell U?
From now on I want to thank @Leandro Felipe Moreira for the help with the following code: Sub teste() rng = Columns(16).End(xlDown).Row MsgBox rng For i = 1 To rng If Cells(i, 16).Value > "0" And…
-
3
votes1
answer831
viewsQ: How to make a loop "for each" in column P up to the last row filled in VBA?
If you define the entire column P:P the leaf will freeze. How do I define the rng, any idea? CODE: Sub teste() Dim rng As Range Set rng = Range("P2:P300") 'Estou a definir até à linha 300 para não…
-
1
votes1
answer2071
viewsQ: How to search in a column by value =< 200 (run command)?
I intend to search row by row within the column P:P a number less than or equal to 200 and execute a command. If more than 200 execute another. The values are defined as 0.0. If .Value =< 200…
-
0
votes1
answer62
viewsQ: How to convert Pounds to Euros VBA?
CONVERSION: The conversion will be in Pounds x 1.17 = Value in Euros. To add a percentage the formula will be Pounds x 1.17 x (1 + percentage). METHOD APPLIED: Replacement of the £200 column.50 to…
-
0
votes1
answer63
viewsA: How to convert multiple sheets . XLSL to . CSV of a book and export individually to the desktop?
RESOLVED: Sub guardar() Dim folha As Worksheet For Each folha In ActiveWorkbook.Worksheets folha.SaveAs "C:\Users\" & Environ("Username") & "\Desktop\CSV\" & folha.Name & ".csv",…
-
0
votes1
answer63
viewsQ: How to convert multiple sheets . XLSL to . CSV of a book and export individually to the desktop?
I intend to store multiple sheets on the desktop by their name. And that they are converted from . xlsx to . csv (separated by comma).
-
0
votes2
answers3002
viewsA: How to assign the formula of cell D2 to a variable?
REPLY: .Value Range("AC2").Select Dim tudo As String data_pasta = Format(Date, "/yy/mm/") tudo = "https://www.pagina.pt/wp-content/imagens" & data_pasta & Range("D2").Value & ".png"…
-
1
votes2
answers3002
viewsQ: How to assign the formula of cell D2 to a variable?
CODE: Range("AB2").Select Dim tudo As String data_pasta = Format(Date, "/yy/mm/") tudo = "https://pagina.pt/wp-content/imagens" & data_pasta & **D2** ".png" ActiveCell.Value = tudo…
-
0
votes2
answers1832
viewsA: How to concatenate or use & commercial with date and text?
RESOLVED: Range("AB2").Select Dim tudo As String data = Format(Date, "dd/mm") tudo = "texto1/" & data & "/texto2" ActiveCell.Value = tudo ultima_linha = Range("A" &…
-
0
votes2
answers1832
viewsQ: How to concatenate or use & commercial with date and text?
I am using the following code to present only the day and month. Range("AB2").Select ActiveCell.Value = "=Now()" ActiveCell.NumberFormat = "yy/mm" ultima_linha = Range("A" &…
-
1
votes1
answer415
viewsQ: How to execute a VBA command on a sheet with a specific name?
I have an Excel document with several sheets. In this document I need to execute a command on a specific sheet, that is by the sheet name. But if that sheet does not exist execute another command on…
-
1
votes2
answers695
viewsQ: How to give the option for the user to choose the destination folder in BATCH?
I do not want to enter the destination manually, for example: set /p destino=Escolha o local de destino: robocopy /s /e pasta %destino% RESOLVED: Using cmd (set & for) + Powershell (new-Object…
-
2
votes1
answer254
viewsQ: Convert Mysql to Mysqli
3 Errors are presented: Notice: Undefined variable: save in C: xampp htdocs index.php on line 6 Warning: mysql_num_rows() expects Parameter 1 to be Resource, Boolean Given in C: xampp htdocs…