G_Waddell 131 Posting Whiz in Training

thanks codeorder
..hehe..it's already working well..this is my new code

Dim wrkStn As String

wrkStn = String.Concat("lbl", (txtSearch.Text.ToUpper))

        If Not CType(Me.Controls(wrkStn), LinkLabel) Is Nothing Then
            With CType(Me.Controls(wrkStn), LinkLabel)
                .BackColor = Color.Orange
            End With
        End If

Hi,

First of all... Dude I'm at work! a bit of patience or you could pay me €50+K a year plus pension and health benefits and I'll work for you.

Second - my bad, Findcontrol is what you use on webpages -DOH!!

G_Waddell 131 Posting Whiz in Training

Hi All,

I hope someone out there can help with this.

I'm writing an app where a user selects a folder on the network for a job to deposit output into.

The person setting up the job will not necessarily be the same person who runs the job and that the job will not be ran on the same machine so I need to keep the path in UNC format.

I can get the user to "see" the network when the FolderBrowserDialog runs by pointing the route folder at the desktop folder.

The issue is that if the network share is local even though the user has selected the folder through the network folders it returns the local path!! Which of course means that when the job is run on the other machine it can not find the folder specified.

E.g. The user on machine1 selects the network share \\machine1\jobs\myjob but the dialog returns C:\work\2010Jobs\Client\jobs\myjob. machine2 then runs the job and looks for C:\work\2010Jobs\Client\jobs\myjob and can not find it then throws an error.

As you can see from the above example I can't just replace c:\ with the local machine name as the share may not be in the root of the drive.

I did think about parsing the text and changing it to \\machine1\c$\work\2010Jobs\Client\jobs\myjob but this would mean I'd have to allow all the users to have admin access to our servers which is a non starter.

Does anyone know …