Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27513

Can't deploy my images and wmv files

$
0
0
I have a simple VB.net project. Works fine in the IDE.

I am trying to deploy it onto a server so my helpdesk guys can deploy it to all the workstations.

The project has two pictures (used as buttons) and a WMV file.

When I publish - I get a black box for the WMV file and two red x boxes for the images.

I know the files can't be found and that's why they aren't displaying after I deploy and run the install.

As you can see in my code below - I've tried lots of things to get my wmv and pictures deployed but can't get them to copy over and read from the correct directory.

Code:

        'If My.Application.IsNetworkDeployed Then
        '    Me.PictureBox1.ImageLocation = "\\WSIPR2\GSAP\yes.jpg"
        'End If

        Me.BackColor = Color.FromArgb(152, 0, 136)
        Me.TransparencyKey = Color.FromArgb(152, 0, 136)
        'black screen when running wmv from server until I changed this..
        'AxWindowsMediaPlayer1.URL = "\\WSIPR2\GSAP\g4s_new.wmv"
        ' If My.Application.IsNetworkDeployed Then
        'AxWindowsMediaPlayer1.URL = My.Application.Info.DirectoryPath & "\resources\g4s_new.wmv"
        '  End If
        'AxWindowsMediaPlayer1.URL = Application.StartupPath & "\g4s_new.wmv"
        RectangleShape2.Visible = False
        Label1.Visible = False
        PictureBox1.Visible = False
        PictureBox2.Visible = False
        If My.Application.IsNetworkDeployed Then
            PictureBox1.ImageLocation = My.Application.Info.DirectoryPath & "\resources\yes.jpg"
        End If
        If My.Application.IsNetworkDeployed Then
            PictureBox1.ImageLocation = My.Application.Info.DirectoryPath & "\resources\no.jpg"
        End If
        'PictureBox1.ImageLocation = "C:\yes.jpg"
        'PictureBox2.ImageLocation = "C:\no.jpg"
    End Sub


Viewing all articles
Browse latest Browse all 27513

Trending Articles