nighttrain's Profile User Rating: -----

Reputation: 8 Worker
Active Members
Active Posts:
435 (0.24 per day)
22-September 10
Profile Views:
Last Active:
User is offline Sep 28 2015 12:04 AM

Previous Fields

OS Preference:
Favorite Browser:
Internet Explorer
Favorite Processor:
Favorite Gaming Platform:
Your Car:
Dream Kudos:
Icon   nighttrain still drilling

Posts I've Made

  1. In Topic: Delete specific symbol and number at the end of filename if exist

    Posted 25 Sep 2015

    I am not sure about other brackets which could appear within filenames - but i assume the could appear.


    What i am aware files could contain as above files (number) at the end. But there could be situation that e.g file would be like this:

    in above cases code should only check - recognize only the bracets at the end of file and not bracets 'before'.
  2. In Topic: Delete specific symbol and number at the end of filename if exist

    Posted 24 Sep 2015

    Basically all of our codes are not secure on situation that there would be more brackets within filename.

    Maybe it's good to make additional assumptions:

    1) if file contains more/less than 1 open bracket And 1 close bracket- then return original file name

    I took Razor's code and made function out of it. please take a look what can be tuned up here?
       Private Function DeleteBrackets(ByVal fn As String) As String
            Dim countOpenBracket As Integer = fn.Split("(").Length - 1
            Dim countCloseBracket As Integer = fn.Split(")").Length - 1
            '-- If only one occurence of ( and one occurence of )
            If countOpenBracket = 1 And countCloseBracket = 1 Then
                Dim filextension = IO.Path.GetExtension(fn)
                Dim filewithoutExtension As String = IO.Path.GetFileNameWithoutExtension(fn)
                'Debug.Print("Oryginal file name = " & fn)
                'Debug.Print("File name without extension = " & filewithoutExtension)
                'Debug.Print("Extension = " & IO.Path.GetExtension(fn))
                If filewithoutExtension.EndsWith(")") Then
                    fn = filewithoutExtension.Remove(filewithoutExtension.LastIndexOf("("))
                    'Debug.Print("After removing last index of ( = " & fn)
                    'Debug.Print("Adding again extension = " & fn & filextension)
                End If
            End If
            Return fn
        End Function
  3. In Topic: Respond from subscriber to an event with given information

    Posted 20 Sep 2015

    Why i decided to do it is to learn correctly how event working therefore i decided to make event better than just select case within DoSomething.

    It's fully clear for me but i am just wondering is it good use of events like we have here. From my knowledge use of events is exactly how we did so: the parser raising event then some subscriber is getting that notification by his method event handler which is called at the moement event in Parser has been executed right? What we do additionaly is sending back some value by custom event class to parser.

    So my question is it all correct what i wrote or there is completly diffrent point of using events?
  4. In Topic: Respond from subscriber to an event with given information

    Posted 20 Sep 2015

    Thanks for youur answer. I am thinking right now what's benefit to use event in this way? It would be easier to just use select case within "DoSomething" method without creating additional event, custom event class etc. Why it is good to go this way with event i mean is much simpler and less code without. Can you explain? Maybe usage of event i am doing is not correct example of event use?
  5. In Topic: Adding images to photoshop a4 template

    Posted 3 Jul 2015

    problem is i cannot find out some enough resource from where start to go. I found only inputs how to read images from photoshop or similar Staff. Hope someone from this forum can point correct place i could Begin. Anyhow i am still looking for it myself without success.

My Information

Member Title:
D.I.C Regular
Age Unknown
Birthday Unknown
Full Name:
Years Programming:
Programming Languages:

Contact Information

Click here to e-mail me
ICQ  637172526



Page 1 of 1
  1. Photo

    FlashM Icon

    24 Sep 2010 - 14:17
    no problem... you're welcome anytime...
Page 1 of 1