Reply to post

Regex -- any Documentation?

Author
rgbigel
User
  • Total Posts : 2
  • Reward points: 0
  • Joined: 2015/03/04 05:38:35
  • Status: offline
2015/03/04 07:06:53 (permalink)

Regex -- any Documentation?

Hi, I'm new around here. Two problems:
I've looked at some examples, but not one of them specifies a replacement with placeholders/variables. Problem is this: in German, the pronunciation of a time span (e.g. 11:30-12:00) uses a wrong word (probably because the English Language only uses "to" for many situations, while German is more specific.) So, I would like to do something like this:
Pattern: ([0-9:]*)-([0:9]*)
Replace: $1 bis $2
The idea being that the round bracketed parts are replaced in the positions 1 and 2, while the "-" is replaced by "bis"
It does not work, but I assume that I'm just using the wrong syntax or the special character is not "$".
 
My second problem is a little odd. First, I do not know which app automatically speaks my events. Second, if this actually is @Voice aloud, it keeps telling me a location for the event that is a constant for all events, even for those which have no location.
Any help you can give me?
Thanks, Rolf
post edited by rgbigel - 2015/03/04 07:07:55

1 Reply Related Threads

    Admin
    Administrator
    • Total Posts : 275
    • Reward points: 0
    • Joined: 2010/11/22 00:00:00
    • Location: USA
    • Status: offline
    Re: Regex -- any Documentation? 2015/03/04 07:40:45 (permalink)
    Hi Rolf,
    the correct RegEx expression for what you want to do is:
     
    (\d+:\d+)(\s*-\s*)(\d+:\d+)
     
    and the "Replace":
     
    $1 bis $3
     
    The app that speaks events is not @Voice, but something else. Maybe the calendar app, or something else, I don't know what - I don't use this feature. You would need to adjust any settings for this in that other app.
     
    Greg
    Jump to:
    © 2024 APG vNext Commercial Version 5.1