vb6 Class Modules

Discussion in 'Software' started by mastermosley, Sep 24, 2006.

  1. mastermosley

    mastermosley Sergeant

    Ok I have an ecryption agorithmn made in a normal module. I want to make in a class module but when I try and call it it says: Object Variable or With Block variable not set. So I try to set it like this:

    Public crypt As Project1.clsCrypt
    Set crypt = Project1.clsCrypt

    But then it tells me I can't. Invalid outside of procedure, what do I do?
     
  2. matt.chugg

    matt.chugg MajorGeek

    Public crypt as new Project1.clsCrypt

    it also depends on the layout of the class module. you can't just rename a module to a class module.
     

MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds