Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 06/24/2021 in all areas

  1. Jos

    Format strings

    sure, well I can guarantee that is a lot of fun to modify working source files and ensure the still function after being processed by the utility!
    3 points
  2. Within strictly-formatted JSON objects, the "name" portion of a "name":value pair, should be surrounded by double quotes, not single quotes. Any JSON parser that requires strict formatting would give an error if 'name':value was encountered. Also, JSON is case-sensitive when it comes to boolean values. The boolean literals are lowercase (true and false). I'm not sure if the WebDrivers require strictly-formatted JSON, but it is best to get in the habit of using the correct syntax in order to prevent issues when strictly-formatted JSON is required. For example: _WD_PrintToPdf($oFF,"{'background': True}") should be _WD_PrintToPdf($oFF, '{"background": true}')
    2 points
  3. mikell

    Format strings

    And why not... guess what ? #Include <Array.au3> $s = StringStripWS(FileRead("test.txt"), 2) ; use a replacement character to replace the 'string' parts $s = StringRegExpReplace($s, '([''"]).*?\1', ChrW(0xFFFD)) ; then split $res = StringSplit(StringTrimRight($s, 1), ChrW(0xFFFD), 3) _ArrayDisplay($res) Edit Simpler but assumes that the non-string parts contain word chars and/or spaces only, one or more (to be adapted if needed) #Include <Array.au3> $s = StringStripWS(FileRead("test.txt"), 2) $res = StringRegExp($s, '([''"]).*?\1(*SKIP)(*F)|[\w\s]+', 3) _ArrayDisplay($res)
    2 points
  4. Correct, I added a couple "phrases" since the last upgrade that are commonly used by us.
    2 points
  5. Nope @mLipok . Time for y'all to use your GoogleFu and find the answer yourself. 😄 P.S. I posted a link earlier to the W3C specs. That may help you identify a way to control the print options.
    2 points
  6. Thanks @TheXman. I was just testing this myself and was about to post my findings. 😀
    1 point
  7. mikell

    Format strings

    Sure ! but it seems that it may be sometimes gratifying to reinvent the wheel
    1 point
  8. Guys, What about simply reporting the post in stead of commenting as these now totally make ZERO sense. These post will self-destruct soon. Edit is fine too.
    1 point
  9. ..ok, I'll pretend that it does not exist. But I'm here if you need to talk about it
    1 point
  10. @gtatsI reviewed the source file you uploaded. Unfortunately, AFAICS it doesn't contain anything that would explain the behavior you're experiencing. What process / tools are you using to find the correct xpath?
    1 point
  11. The double click is there to prevent closing the window/app by misclicks. If you do not like it, the source code is in the archive. Change the following code Case $GUI_EVENT_CLOSE If $closecounter = 1 Then If TimerDiff($TimeHandle) <= 1000 Then ExitLoop EndIf EndIf If $closecounter = 0 Then $closecounter = 1 $TimeHandle = TimerInit() WinSetTitle($h_SnipForm, "", "Doubleclick to close") EndIf Into Case $GUI_EVENT_CLOSE ExitLoop And the main window will close on single click. Then seek the Case $GUI_EVENT_CLOSE, $BTN_EXIT If $closecounter = 1 Then If TimerDiff($TimeHandle) <= 1000 Then $snipeditclose = 0 If $snipeditchanged = True Then $iMsgBoxAnswer = MsgBox(8244, "Exit without saving ?", "Do you want to close the editor without saving the changes ?") If $iMsgBoxAnswer = 7 Then $snipeditclose = 1 ;No EndIf If $snipeditclose = 0 Then GUIDelete($Form1) ExitLoop EndIf WriteToolBar("Please save your file.") EndIf EndIf If $closecounter = 0 Then $closecounter = 1 $TimeHandle = TimerInit() WinSetTitle($Form1, "", "Doubleclick to close") EndIf code and change it into: Case $GUI_EVENT_CLOSE, $BTN_EXIT $snipeditclose = 0 If $snipeditchanged = True Then $iMsgBoxAnswer = MsgBox(8244, "Exit without saving ?", "Do you want to close the editor without saving the changes ?") If $iMsgBoxAnswer = 7 Then $snipeditclose = 1 ;No EndIf If $snipeditclose = 0 Then GUIDelete($Form1) ExitLoop EndIf WriteToolBar("Please save your file.") And the editor will close on single click.
    1 point
  12. Hi everybody, The attached script (version 2y) allows to drag and resize any column (even column 0) without having characters overlap other columns Well... this is the end of my "journey through incremental search" as all functionalities have been added. Thanks to all contributors and a special thanks to LarsJ Edit: June 22, 2021 * minor update (less code for computing col 0 coords, in Func WM_DRAWITEM, after an horizontal scrolling has been performed) * added functionality : do not draw actual non-visible column(s), this makes a big difference when LV got many columns : the scrolling stays smooth (tested) Edit: June 25, 2021 * Fixed issue with left-aligned columns in Func WM_DRAWITEM (thanks Norm73) Incremental Search (2y).au3
    1 point
×
×
  • Create New...