• 0 Votes
    2 Posts
    1k Views
    Terry RT

    @Jahmen-Myst said in How do I Copy/ Paste a YAML.txt file text into Excel and keep the format?:

    I need help to get my YAML game code .txt file

    Excel will try to interpret any input. So if text it will look for columns and this can result in text that looks like numbers being made into numbers. Other changes can also occur. To prevent this I suggest having double quotes (that’s the default character to tell Excel not to alter the content) around each line. Then import and hopefully the line will remain unaltered. Then you can cut the pieces out of column A into the other columns as you require.

    Terry

  • Possible way for User Installation?

    8
    0 Votes
    8 Posts
    6k Views
    PeterJonesP

    @Sebastian said in Possible way for User Installation?:

    tried to update the portable version

    Once you invoke the updater, it is trying to do things the installed way, not the portable way. If you don’t want the installer running, don’t use the “update” command.

    When I want a new version of the portable, it’s easiest to unzip it to a new folder, then do folder renames so that the newer portable ends up in the same directory where my association points. Alternately, you can copy files from one portable folder to another – I know there are other discussions on this forum that talk about what files you need to copy directly, and what files are best to compare an manually merge: search for “portable update” or similar phrasing.

  • Exit NP++ (tab) from cmdline (even there is unsaved, changed content)?

    4
    0 Votes
    4 Posts
    278 Views
  • UDL doesn't work as wanted

    3
    0 Votes
    3 Posts
    252 Views
    Juergen MoorsJ

    @PeterJones said in UDL doesn't work as wanted:

    Delimiter

    Thank you very much Peter! That helps:

    Screen Shot 09-24-20 at 09.40 AM.JPG

    Screen Shot 09-24-20 at 09.41 AM.JPG

    With these settings, the matches are correct shown in the whole logfile!
    Screen Shot 09-24-20 at 09.41 AM 001.JPG

    Screen Shot 09-24-20 at 09.41 AM 002.JPG

    Kind regards,
    Juergen

  • Move Session.xml

    5
    0 Votes
    5 Posts
    798 Views
    Alan KilbornA

    @James-Sabia

    Do we know if the expected behavior is to store the session.xml file in the cloud location or not?

    Based upon the comment here (at link below), I’d expect not, but who believes comments in code? :-)

    https://github.com/notepad-plus-plus/notepad-plus-plus/blob/85914b3c660ff55d06036b571c96c8f94bf1882b/PowerEditor/src/Parameters.cpp#L1064

  • Simple text clean up

    7
    0 Votes
    7 Posts
    3k Views
    guy038G

    Hello, @adam-labuš, @alan-kilborn, @m_andre_z_eckenrode and All,

    Ah, OK ! With your new specifications, it’s easier to get the right regex, at once ;-))

    But when you said :

    For the other lines I want to delete everything else except lines that looks like this

    ;LAYER:1

    We don’t know if you speak of lines which begin, contain or end with ;LAYER:1 ! I suppose that it is which begin…

    Then, from this simple example, below :

    G1 X184.218 Y123.524 E1.81219 G1 X183.179 Y125.34 E1.83974 M204 S625 ;LAYER:1 bla bla blah M205 X10 Y10 G0 F2571.4 X182.84 Y125.092 M204 S500 G1 X183.179 Y125.34 E1.83974

    The following regex S/R

    SEARCH (?-si)^G[01].+(X\d+\.\d+\x20Y\d+\.\d+).*|^(?!;LAYER:1).+\R

    REPLACE \1

    would output this text :

    X184.218 Y123.524 X183.179 Y125.34 ;LAYER:1 bla bla blah X182.84 Y125.092 X183.179 Y125.34

    Notes :

    The in line modifiers (?-si) mean that :

    Any dot regex symbol represents a single standard character and not EOL chars, as \r or \n (?-s)

    The search is run in a non-insensitive way (?-i)

    Then the search regex contains two alternatives, separated with the | symbol :

    The regex ^G[01].+(X\d+\.\d+\x20Y\d+\.\d+).*

    The part ^G[01] looks for strings G0 or G1, beginning current line

    The part .+ represents any non-null range of standard characters

    The part (X\d+\.\d+\x20Y\d+\.\d+) search for the exact letter X, followed with some digits \d+, followed with a literal dot \. followed by decimal digits \d+ and a space char \x20 then the exact letter Y and … ( same process than for X ). As all the part is surrounded by parentheses, its contents are stored as group 1

    Finally, the part .* represents any range of standard characters, possibly null

    The regex ^(?!;LAYER:1).+\R

    The part ^(?!;LAYER:1) search all the lines which not begin with the string ;LAYER:1

    And the part .+\R catches all the characters of any non-null line .+, with its line-break chars \R ( = \r\n for Windows files, \n for Unix files, or \r for Mac files )

    In replacement :

    If the left regex matches, then the group 1 is defined and corresponds to the XY coordinates, which must be rewritten => \1

    Else, the right regex is used. As no group is defined, in the second alternative, the pointer to group 1 \1 return a null string. So, the current matched line is just deleted !

    Best Regards,

    guy038

  • Windows Relative File in Session

    4
  • cannot load c:\Users\xxx\AppData\Roaming\Notepad++\stylers.xml

    2
    0 Votes
    2 Posts
    380 Views
    PeterJonesP

    @Michal-Simek ,

    Did the AppData folder get properly created? Does user xxx have read/write permission to that folder and that file? Did you have another instance of Notepad++ open while trying to do the installation (in which case, maybe there was a lock on the file while the installer tried to install it).

    https://community.notepad-plus-plus.org/topic/15739/faq-desk-request-for-help-without-sufficient-information-to-help-you

  • Font size of file tab

    2
    0 Votes
    2 Posts
    303 Views
    PeterJonesP

    @Mike-McCutcheon ,

    Sorry. The tab bar file names do not have a font-size setting controllable by Notepad++. As far as I know, it uses the same font size as the menu bar does by default, which (I believe) is defined by Windows.

    The Windows Settings “Ease of Access > Display” settings can affect that… but that makes all text in Windows bigger, not just the menu bar and tab bar fonts.

  • View In Edge - Not converting space in file path to %20

    2
    0 Votes
    2 Posts
    204 Views
    Alan KilbornA

    It is probably a Notepad++ thing.
    If I try a similar experiment on a file that has no space in its path, I get the file open in Edge.
    If I put a single space in the path of the file (by renaming it in N++), Edge tells me:

    13caa8dd-697a-458d-8fb0-f9c2612c6bae-image.png

  • Merge 2 Files - Lines Containing Same

    12
    0 Votes
    12 Posts
    515 Views
    Terry RT

    @Shesh-Nioice said in Merge 2 Files - Lines Containing Same:

    I should be start learning regular expressions very interesting and helpful.

    To learn about regexes (regular expressions) start with our FAQ section. There are a number of helpful links to sites (I see you already found one, regex101.com). There is the manual for NPP which is on the NPP homepage. Other references are also linked within the FAQ posts.

    I was where you are now not too long ago, but I too found the regulars here were very helpful to me and now I pass that forward. As always we strive not only to help users, but to guide them so they can gain more knowledge. Regexes are brilliant but don’t forget to start small at first as it can be quite daunting to attempt to read some of the more complex regexes that are provided on this forum. The beauty of regex101.com is that it does explain what the regex is doing so that will give you some insight.

    Cheers
    Terry

  • Can't save an Open File

    8
    0 Votes
    8 Posts
    792 Views
    Alan KilbornA

    @Email-Subjekt said in Can't save an Open File:

    The reason why I never installed the newest version is I kept all my files unsaved in notepad ++

    And no independent backups, right?
    Bad ideas, these.

  • Find Replace Time Stamps?

    2
    0 Votes
    2 Posts
    2k Views
    Terry RT

    @Sean-Bliss said in Find Replace Time Stamps?:

    Is there a way to find and replace all these time stamps? “10:22” “10:24” “05:19”

    I presume we are talking about a text file? As for looking for specific types of character strings regular expressions are the way to go.

    However you haven’t really explained enough nor provided enough of examples in order for us to really help.

    Can you provide a list of perhaps 4-10 different lines showing exactly how they look in the file (starting the line or midway through, whole line etc). When posting the examples please insert them, then highlight all of them and hit the </> button you see immediately above the posting window. This prevents the forum from potentially mangling your examples (it attempts to format and some characters have special meanings).

    To start you off though, to find the time stamps you would likely use something like
    \d\d:\d\d
    each \d is a number position. In fact using that and marking all the lines you will have every time stamp line marked and could then remove marked lines. As what I provided is a regular expression any search or mark function would need the search mode set to “regular expression”.

    But if at all uncertain, please do provide “real” examples in the method I outlined, this will put a black box around them when posted. Also include what you hope to do once selected, do you want to replace them or just delete them?

    Thanks
    Terry

  • Can I have multiple ‘Search Engine’ in the context menu?

    3
    0 Votes
    3 Posts
    232 Views
    Arjen van den BroeckeA

    It took me some time to figure out what you did there (I am new to NPP …) - but yes! that is exactly what I was looking for!
    Thank you so much for your kind help.

  • Want to copy all from specific character to end of line of each line.

    6
    0 Votes
    6 Posts
    5k Views
    Alan KilbornA

    @M-Andre-Z-Eckenrode said in Want to copy all from specific character to end of line of each line.:

    very handy Python script…which allows you to copy all marked text, and requires installing the Python Script plugin

    It appears that this ability might be “going native”, meaning no longer a need for a script to do it.
    See https://github.com/notepad-plus-plus/notepad-plus-plus/pull/8867
    It isn’t accepting in to the actual codebase yet as of this writing, so if you’d like to see that feature with “inside Notepad++” support, maybe comment at that site.
    For me, I’ve had that script set up for a long time, so it makes no difference to me.

  • User configurations files?

    2
    0 Votes
    2 Posts
    230 Views
    PeterJonesP

    @I-neuw ,

    As it says in https://npp-user-manual.org/docs/config-files/

    The underlying XML files are all found in %AppData%\notepad++\ (or, for zip-based local installations, in the Notepad++ executable directory) unless otherwise noted.

  • What is "Selected Line" in Style Configurator for "Search result"

    3
    0 Votes
    3 Posts
    246 Views
    Alan KilbornA

    @PeterJones

    Actually, NOPE!, I sure didn’t.
    Thanks for the reminder.
    I actually think I’m pretty good at remembering previous questions/answers, but not this time.

  • Dancing text selection

    2
    0 Votes
    2 Posts
    263 Views
    PeterJonesP

    @Joseph-McCay ,

    There are some known issues with High DPI. I don’t know if this “dancing text selection” is one of them. (I don’t have high DPI, so cannot test)

    Also, you might want to see if one of your plugins is causing the issue: run with the -noPlugin command line argument and see if the problem persists: if it goes away, it was one of your plugins. You can then start trying plugins one at a time to see which causes it to come back (if you rename the folders in <installdir>/plugins/ and re-run Notepad++, any plugin whose folder name was changed will not be loaded; so you could rename them all, then one-at-a-time name them correctly again, until the problem comes back.)

    Or you may have to wait for a user with High DPI to chime in, if they have seen this.

    “feature” (maybe to mess with intoxicated people)?

    The developer has an odd sense of humor, but I doubt he adds “features” to intentionally mess with people (unless you consider the ghost-typing and easter-egg options to be “messing with people”). :-)

  • Replace. How to solve it?

    3
    0 Votes
    3 Posts
    797 Views
    Olivier ThomasO

    Thanks.

  • 0 Votes
    4 Posts
    498 Views
    guy038G

    Hello, @jeff-brewer, @peterjones, @olivier-thomas and All,

    Here is my solution :

    SEARCH Account Number(:\h*.*[\l\u])|-

    REPLACE ?1Description\1

    Note : When a dash is matched, the group 1 does not exist. As the conditional replacement ?1Description\1 does not contain any else part, any dash character is then deleted !

    Best Regards,

    guy038