Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Event Log String Extract Post Reply Post New Topic
Author Message
cobby1812
Newbie
Newbie
Avatar

Joined: 18 Feb 2009
Location: United Kingdom
Online Status: Offline
Posts: 2
Quote cobby1812 Replybullet Topic: Event Log String Extract
    Posted: 14 Jan 2013 at 11:46pm
Morning All,
 
I am trying to extract the User Name from an evt file as follows
 

CoID={xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}: The user xxxxxxxxxxx\Mark Cobb connected on port VPN2-119 has been assigned address 111.111.11.11

 

So the Mark Cobb is the Part I want to extract, obviously I am not the only person I need to extract so I need to find a generic way of getting all users after the xxxxxxxxxxx\ to be shown.

Any Idea's??
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 15 Jan 2013 at 6:47am
local numbervar i := instr({table.field}, "\") + 1;
local numbervar x := instr({table.field}, " connected", i) - 1;
mid({table.field}, i, x - i + 1)
 
should return the name, provided the string is formatted as described.
 
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.