Jump to content


Photo

VB6 Problem


  • Please log in to reply
8 replies to this topic

#1 Sonic

Sonic

    Young Padawan

  • Members
  • Pip
  • 4 posts
  • Gender:Male

Posted 25 July 2007 - 07:25 PM

Hello,

I just installed VB6 off a CD of mine and whenever I run code that has an "If statement" in it, the program crashes.

I can make buttons and all, but once I code them I get something like so:
http://img19.imagesh...ualbasicop1.jpg

Any clue as to why this may be happening?

Thanks

#2 Mezzo

Mezzo

    Young Padawan

  • Members
  • Pip
  • 102 posts
  • Gender:Male
  • Location:Toronto Ontario

Posted 25 July 2007 - 11:06 PM

Hello,

I just installed VB6 off a CD of mine and whenever I run code that has an "If statement" in it, the program crashes.

I can make buttons and all, but once I code them I get something like so:
http://img19.imagesh...ualbasicop1.jpg

Any clue as to why this may be happening?

Thanks


A few questoions:
1) Does the program crash in every single If statement. Like if you had a second text box and just set the text in it instead of a msgbox does this crash?
2) Can you post a picture (or copy the text) of the data the error report contains?
3) Have you tried re-installing VB6?

Hopefully these things will help us diagnose your problem

PS. I can't see anythign wrong with your code (I haven't coded in VB in a while though)

#3 SatanicPenguins

SatanicPenguins

    P2L Jedi

  • Members
  • PipPipPip
  • 541 posts
  • Gender:Male
  • Interests:Photoshop, Web Design, Graphic Design, Internet.

Posted 26 July 2007 - 03:18 AM

His code looks to be fine

My VB stopped working a while back, when i tried to run any code at all it would crash. Reinstalling it fixed it.

Dim Problem as Solved. (sorry, had to be done)

(just curious, does your vb crash when using Case's?)

Select Case Text1.text
Case "4"
Msgbox("hi")
End Select

Edited by SatanicPenguins, 26 July 2007 - 03:20 AM.


#4 mattcch2007

mattcch2007

    Young Padawan

  • Members
  • Pip
  • 111 posts

Posted 26 July 2007 - 04:16 AM

just a reminder
vb6 is a very old one, which runs more smoothly on win95/98 platforms.

#5 SatanicPenguins

SatanicPenguins

    P2L Jedi

  • Members
  • PipPipPip
  • 541 posts
  • Gender:Male
  • Interests:Photoshop, Web Design, Graphic Design, Internet.

Posted 26 July 2007 - 05:06 AM

Visual basic 6 runs fine on XP?

6 is the last true visual basic in a sense, seeing as .Net is nothing at all like its predeccesors

#6 Mezzo

Mezzo

    Young Padawan

  • Members
  • Pip
  • 102 posts
  • Gender:Male
  • Location:Toronto Ontario

Posted 26 July 2007 - 10:53 AM

VB6 Runs perfectly fine in XP (not sure about vista). I used to code in VB6 purely in XP (I've never tried it in 95/98.

#7 Sonic

Sonic

    Young Padawan

  • Members
  • Pip
  • 4 posts
  • Gender:Male

Posted 26 July 2007 - 12:37 PM

Thanks for the replies all ^^

I installed a visual basic service pack from the Microsoft site and this seems to have fixed the problem :tiphat:

#8 Mezzo

Mezzo

    Young Padawan

  • Members
  • Pip
  • 102 posts
  • Gender:Male
  • Location:Toronto Ontario

Posted 26 July 2007 - 01:37 PM

Thanks for the replies all ^^

I installed a visual basic service pack from the Microsoft site and this seems to have fixed the problem :D


Glad we could help :tiphat: And welcome to P2L. Hope you stay around. Theres not many questions in the Desktop Programming section ....We Need more!!

#9 Sonic

Sonic

    Young Padawan

  • Members
  • Pip
  • 4 posts
  • Gender:Male

Posted 26 July 2007 - 04:34 PM

:tiphat: ill try to hang around, i have one more question also, which ill post xP




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users