Minimalist 96 Posting Pro

How are we supposed to help you if you don't show any code and where the prorgam is not doing what you expect to happen?

Minimalist 96 Posting Pro

Dear oh dear,
why don't you go to control panel -> uninstall a program and check if the file actually installed. There you can also search for the date of the installation of the program if it installed.

Minimalist 96 Posting Pro

And the question is?

Minimalist 96 Posting Pro

Have a look at this link. This might explain wgat you are looking for.
http://www.sevenforums.com/tutorials/57455-file-extension-icon-change-default-icon.html

Minimalist 96 Posting Pro

No I haven't. I am sort of careful not to introduce more problems by not getting rid of another adon. I am looking at sysinternals from MS at the moment. I also got now 2 other stupid programs, Snapdo and search safe.finder. Well, think I got some learning todo of how to remove thése. Thanks anyway.

Minimalist 96 Posting Pro

Had anyone else problems with this add on. Seems to be almost impossible to get rid of it

Minimalist 96 Posting Pro

I use bookmarks in chrome to arrive vb.net etc. So here I quickly scan things I might be interested in. If nothing happened in a thread I was interested I just leave again, if I see there was some activity or alot I follow from where I know I left.

Minimalist 96 Posting Pro

Well it is just for really long threads. Like you got one just now with 48 replies. I know I read the first page, came back a while later and it is now up to page 3. I can now either start scrolling down to get to page 2 or jump to page 3 and start scrolling up. I am not that often on the community page so I did missed the question Dani, do forgive. Cheers

Minimalist 96 Posting Pro

I like to see a button to move to the next page in a thread on top of the thread. Now, if a thread spans more pages I have to scroll to the bottom of each page to go to the next page. Maybe I missed a shortcut?

dtpp commented: spot on +0
Minimalist 96 Posting Pro
Minimalist 96 Posting Pro
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button5.Click
        Dim str As String = Trim(TextBox1.Text)
        Label1.Text = Mid(str, 1, 2)
        Label2.Text = Mid(str, 3, 1)
        Label3.Text = Mid(str, 4, 1)
        Label4.Text = Mid(str, 5, 1)
    End Sub
Minimalist 96 Posting Pro

Assuming you added "Vehicle" to the list you can replace the lines between these ------------ two lines with this code snippet.

 '-------------

        Dim lineIndex As Integer = 0
        For Each lin As String In TextBox1.Text.Split(vbNewLine)
            If Len(lin) < 3 Then
                indexlist.Add(lineIndex)
            End If
            lineIndex += 1
        Next
        If indexlist.Count > 1 Then
            found = indexlist(1) + 1
        Else
            found = 100
        End If
        '-------------
Minimalist 96 Posting Pro

Since you got a few indexes: looklist.index, listbox1.index and from the string.split you need to be more specific which index is going out of range and show the code where the error occurs. Otherwise we can't even guess what is happening.

Minimalist 96 Posting Pro

Every vb.net program has colections of the controls that are contained within. You can get all the controls with something like:

  For Each ctl As Control In Me.Controls
    'do something
     Next

which will loop theough all controls.
With my code I restrict the controls to the type of label:

 For Each Cont As Label In Me.Controls.OfType(Of Label)()
           'do something
        Next

Cont just means control.
So, since we running through all the controls you don't need another loop.
So, cont.name is a controls name,in this xase a label, and we use this to get to the control you want by using the how the name text ends: Inyour case with a number, this what
If Cont.Name.EndsWith(condi) Then
does since cont.name is the name of the label, which is text whixh I feed through textbox1.text.
So the only thing you have to do replace my names with what you want, place a second for .. next loop for the textboxes and the apply your condition.

Minimalist 96 Posting Pro

Well, he got already the controls array. As I said it depends just on the conditions. To get all labels with a condition from a textbox I would use something like:

Public Class Form1

    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load

    End Sub
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Application.Exit()
    End Sub

    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
        Dim condi As String = TextBox1.Text
        For Each Cont As Label In Me.Controls.OfType(Of Label)()
            If Cont.Name.EndsWith(condi) Then
                Cont.Visible = False
            Else
                Cont.Visible = True
            End If
        Next
    End Sub

End Class
Minimalist 96 Posting Pro

Could you elaborate at what the conditions are that make them visible or hide these?

Minimalist 96 Posting Pro

You shouldn't allow duplicate records in your database. To prevent this use a unique or primary key to avoid this. Anyway, here is a possible solution at stackoverflow:
http://stackoverflow.com/questions/1840782/how-to-find-duplicates-in-recordset-using-vb6

Minimalist 96 Posting Pro

Could also be done just using vb.net and regex. I create a lookup list first to filter the lines out that get used. Than clean it all up.

Imports System.IO
Imports System.Text.RegularExpressions
Public Class Form1
    Dim lookList As New List(Of String)
    Dim indexlist As New List(Of Integer)
    Dim found As Integer = 0
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        If My.Computer.FileSystem.FileExists(mpath) Then
            Dim readText() As String = File.ReadAllLines(mpath)
            For Each lin As String In readText
                TextBox1.Text = TextBox1.Text & vbCrLf & lin
            Next
        End If
        lookList.Add("Monday")
        lookList.Add("Tuesday")
        lookList.Add("Wednesday")
        lookList.Add("Thursday")
        lookList.Add("Friday")
        lookList.Add("Saturday")
        lookList.Add("Sunday")
        lookList.Add("Created:")
        lookList.Add("Updated:")
        lookList.Add("Location:")
        lookList.Add("Shift")
        lookList.Add("Car")
        lookList.Add("Bus")
        lookList.Add("Created:")
        'Apply filter
        Dim str As String = ""
        For Each words As String In lookList
            For Each lin As String In TextBox1.Text.Split(vbNewLine)
                If lin.Contains(words) Then
                    str = str & vbCrLf & lin
                End If
            Next
        Next
        str = str.Replace("�", "°")
        TextBox1.Text = str
    End Sub
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Application.Exit()
    End Sub
    Function StripTags(ByVal html As String) As String
        ' Remove HTML tags.
        Return Regex.Replace(html, "<.*?>", " ")
    End Function
    Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click
        Dim str As String = Trim(TextBox1.Text)
        str = str.Replace("<br/>", vbCrLf)
        TextBox1.Text = str
        'Remove tags
        Dim html As String = TextBox1.Text
        Dim Tagless As String = StripTags(html)
        TextBox1.Text = Tagless
        'Move to Listbox
        str = Trim(TextBox1.Text)
        str = str.Replace(" ", "")
        TextBox1.Text = str
        '-------------
        Dim match As String = (vbLf & vbCr)
        Dim lineIndex As Integer = 0
        For Each …
Minimalist 96 Posting Pro

I have been there before and ended up writing a .bat file to a) move some files to the correct directories and b) register some controls(before by hand via cmd). This fixed the problems. Here is a complete quote from superuser:
"
download from Microsoft this tool for Exchange 2000, that incidentally is a VB6 program redistributed with msstdfmt.dll
run the program, extracting its contents to a folder of your choice
copy msstdfmt.dll to c:\windows\system32 if running on 32 bit OS or to c:\windows\syswow64 if running on a 64 bit OS
open a command prompt (cmd.exe) with administrator privileges
in the prompt type on 32 bit OS
regsvr32 c:\windows\system32\msstdfmt.dll
or on 64 bit OS
regsvr32 c:\windows\syswow64\msstdfmt.dll
"
I also checked out on win98 (vitual machine) where files got installed. This way you can see where troubling files should be. Last word, do a rewrite with vb.net, using the latest free version to avoid all these troubles in the future.

Minimalist 96 Posting Pro
Minimalist 96 Posting Pro

Here I mostly used your code but added a list to store your strings and a listbox to display these.

Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
        Dim idList As New List(Of String)
        Dim i As Integer = 1
        Dim txtProps As String = ""
        Dim objReader As New System.IO.StreamReader(propFileName)
        ListBox1.Items.Clear()
        If System.IO.File.Exists(propFileName) = True Then
            Do While objReader.Peek() <> -1
                txtProps = objReader.ReadLine()
                idList.Add("Props " & i.ToString & ", PropId  " & txtProps) 'add the properties to the list
                i += 1
            Loop
        End If

        'display strings in lisbox
        For i = 0 To idList.Count - 1
            ListBox1.Items.Add(idList.Item(i))
        Next
    End Sub
Minimalist 96 Posting Pro

I would use a list of string to create the variables. No need to use redim statements:

Public Class Form1
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        TextBox1.Text = "1" 'pevents error if textbox is empty
    End Sub
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim idList As New List(Of String)
        ListBox1.Items.Clear()
        'Create the variables
        Dim j As Integer = CInt(TextBox1.Text) - 1 'need to take 1 as list stats at 0
        Dim i As Integer
        For i = 0 To j
            idList.Add("Props" & i.ToString)
        Next
        'display variables in lisbox
        For i = 0 To idList.Count - 1
            ListBox1.Items.Add(idList.Item(i))
        Next

    End Sub

    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
        Application.Exit()
    End Sub
End Class

Click Here

Minimalist 96 Posting Pro

Hi Don,
its not that hard. There is good example here:
http://www.visual-basic-tutorials.com/WriteToExcel2007.php
The most important thing is to follow the instructions in regard to add the reference.

Minimalist 96 Posting Pro

Well, the deliminator depends on the region for which your computer's system or program is set.
To only display the required digits use the math.round function:
Math.Round(value, 1)
https://msdn.microsoft.com/en-us/library/75ks3aby.aspx

Minimalist 96 Posting Pro

You need to apply some division to the file.length as this comes in bytes based on the charcters in your file. Here are some of the divisions:
info.Length / 1024 '= kilobytes
info.Length / 1048576 ' =megabytes
info.Length / 1073741824 '= gigabytes

Minimalist 96 Posting Pro

I moved straight to the newest version of vb.net. Especially the API calls were a headache foe me. Got rid of these now as they were always a problem (16 bit to 32 bit to 64 bit). I think you also might save time moving to vb.net and learning at the same time.

Minimalist 96 Posting Pro

@Mr M
In line5 you probably mean: Answer = Value1 - Value2 ?
@Arun
1) I would use the read out (textbox ?) also as a variable to keep on with the operations.
2) I would use select case stements for your operations code

Minimalist 96 Posting Pro

You need to check if th form does exist and if it does set the window.state to normal. Something like this:

 Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim frmCollection = System.Windows.Forms.Application.OpenForms
        For Each f As Form In frmCollection
            If f.Name = "Form2" Then
                MsgBox("Form exists")
                f.WindowState = FormWindowState.Normal
                Exit Sub
            End If
        Next
        Dim form2 As New Form
        form2.Show()
        form2.Name = "Form2"
         form2.Text = "Form2"
    End Sub
Minimalist 96 Posting Pro

Looks more like a select case statement where there are more than one clause. See a good example of it here:
https://msdn.microsoft.com/de-de/library/cy37t14y.aspx

Minimalist 96 Posting Pro
Minimalist 96 Posting Pro

This link might give you some insight of how to check some common files for tempering.
http://www.forensicprotection.com/Education_Authenticate.html

Minimalist 96 Posting Pro

Sorry, but this is all I could think of.

Minimalist 96 Posting Pro

Well only you know which namespaces or libaries you need to import or refer too. Obviously you are using amethod and not referring to the namespace you would need.
https://support.microsoft.com/en-us/kb/304260
http://stackoverflow.com/questions/14665713/the-name-does-not-exist-in-the-namespace-error-in-xaml
Quote from thread:
I noticed via Subversion that I apparently changed the project build Platform target to x64. This was the only change I had made and after making that change, the code was working for a bit. I changed it to x86 to test and suddenly my designer was working again. Subsequently, I changed it back to x64, and the problem has disappeared completely. I suspect that the designer builds some kind of cached code in x32 and changing the x64 build platform breaks it when you make code changes.
End Quote

Minimalist 96 Posting Pro

O.K. so you did all the cleaning and rebuilding. Now, if I open your Breakage.Designer file I still can see references to the powerpacks. You need to remove these as well and the shapes you still might have in your forms. Also I just imported your file into a project and that works O.K. So make a copy of your project with the errors and import the 3 files that worked well into your stuffed project. You can do this from the menu bar-> Project-> import existing file.

Minimalist 96 Posting Pro

In the formload event:
Me.Width = Screen.Width
Me.Height = Screen.Height

However, that might not display all of the controls, depending on the layout of the form. You need to deal with this by resizing these as well.
Something like in the form resize event:
Me.MyControl.Width = me.ScaleWidth / 2
Additional information:
The layoutpanel might suit your needs for resizing controls automatically.
http://www.vbforums.com/showthread.php?727993-make-my-form-fit-any-size-screen-same-resolution

Also do you mean "namespace error" ?

Minimalist 96 Posting Pro

In the resx of your first zip file you still have a reference to the powerpack. Try to import the original resx file into your project and do a rebuild. Keep backups. Good luck.

Minimalist 96 Posting Pro

Well as I stated before, can create 9 small bitmaps and move these into the pictureboxes. That way you won't get any line and since it's always the same picture it doesn't really matter.

Minimalist 96 Posting Pro

Since you are declaring snumber as string your inputbox statement should be:

sNumber = InputBox("Enter a number", "Numbers Only", iNumber.ToString)

https://msdn.microsoft.com/de-de/library/6z0ak68w%28v=vs.90%29.aspx

Minimalist 96 Posting Pro

Do check this one out. Maybe it helps.
http://www.saetechnologies.com/data-view-automation-error-element-not-found-vb6/
You also can google Data Automation Error! No elements found vb6 which brings up a number of results.

Minimalist 96 Posting Pro

What about a backup of your project when every thing still was O.K.?
What I would be doing is:
1) Remove all powerpck controls from your project
2) Remove all poerpck controls from the toolbox
3) Go to the menu bar to Build
4) In build use Clean Solution and run this
5)In Build run Rebuild Solution
This at least should give you a working solution again. Then I would remove all instance of powerpack from vs and load the newest version down and install this and make sure you only use one version of powerpack which was mentioned somewhere on the net.
If nothing helps, maybe zipping your project and posting here so we can have a look might be a way.
Good luck

Minimalist 96 Posting Pro

Well what you can try is to have another picturebox. Move each part into this picturebox, crop the edge off and than move it into the designated picturebox.

Minimalist 96 Posting Pro

Well that is why I get the line which is part of a neihbouring part of the picture. That means division by 3 will be not exactly give the slicing.

Minimalist 96 Posting Pro

Thanks ddanbe, will work on it when I get time again. Actually was just a matter of setting the forms doublebuffering to true and works like a charm now.

Minimalist 96 Posting Pro

Well if it is always the same picture it just would be easier to load the numbers as single bitmaps into the pictureboxes. It can be split but needs fiddling to get the size of the initial picture correct for splitting. Now I am trying to find a solution for the resizing. And yes, it makes a difference.
O.K. that's what I came up with sofar but there is a flicker so I try to improve it.

Minimalist 96 Posting Pro

O.K. Thank you Dani

Minimalist 96 Posting Pro

Well again, is this always the same initial picture with the numbers or does this initial picture change? Is it always the same numbers that stretch and the corners stay the same? A user may change the window through pulling on the sides or corners. Is the scaling in the three events the same?

Minimalist 96 Posting Pro

I am just wondering about a really long thread on the vb.net forum not beeing displayed in a few pages. At the moment it is a really long scroll job.
https://www.daniweb.com/software-development/vbnet/threads/496489/error-message-when-application-opens#

Minimalist 96 Posting Pro

To find the line that throws the exception try the following:
On the menu bar in visual basic:
1) Click on the 'Debug' menu item
2) Click 'Exceptions...'
3) Select 'Common Language Runtime Exceptions' - 'Thrown'
This should stop the program at the line the exception is thrown in.

Minimalist 96 Posting Pro

Ok this raises two questions:
1) Is this always the same image?
2)How do you want to resize the different parts of the picture? Button,Clicking on the part etc?

Minimalist 96 Posting Pro

What should be the end product? Sliding game? It is hard to give good advice without knowing what the result should look like. Ayway one way of doing it is this,I only used three pictureboxes for demonstration:
Just click on the image to see the animation.

Public Class Form1

    Private Sub Scale_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Me.PictureBox1.Size = New System.Drawing.Size(70, 70)
        Me.PictureBox2.Size = New System.Drawing.Size(70, 70)
        Me.PictureBox3.Size = New System.Drawing.Size(70, 70)
        PictureBox2.Top = PictureBox1.Top
        PictureBox2.Left = PictureBox1.Left + PictureBox1.Width + 4
        PictureBox3.Top = PictureBox1.Top + PictureBox1.Height + 4
        PictureBox3.Left = PictureBox1.Left
    End Sub
    Private Sub ScaleUp_Click(sender As Object, e As EventArgs) Handles Button2.Click
        Me.PictureBox1.Size = New System.Drawing.Size(100, 100)
        Me.PictureBox2.Size = New System.Drawing.Size(100, 100)
        Me.PictureBox3.Size = New System.Drawing.Size(100, 100)
        PictureBox2.Top = PictureBox1.Top
        PictureBox2.Left = PictureBox1.Left + PictureBox1.Width + 4
        PictureBox3.Top = PictureBox1.Top + PictureBox1.Height + 4
        PictureBox3.Left = PictureBox1.Left
    End Sub
End Class

Scale.gif