Ctype Again

0 graham burgess · May 31, 2015
After typing in this code, I get the error message "Error 1 'txtRawVariable' is not declared. It may be inaccessible due to its protection level."
I read somewhere that there is a setting that you can change so that undeclared variable are handled.
Would this cure the problem and is anyone else familiar with this and can point me in the right direction

Post a Reply


Oldest  Newest  Rating
0 Glenn Walker · June 25, 2015
Bummer about losing the data.  I won't remind you that you should backup frequently......... I guess I just did.
I don't often have a reason to use CType, so I don't remember that much about it (I can look it up when I need it again), but as I recall it is fairly simple to use and you probably already have fixed it up.
I am always tinkering around with a couple of projects I am currently working on and zap my data not infrequently.  What I do to keep my losses at a minimum is I frequently print out the code for the different forms/classes/namespaces/modules in my project.  Of course that doesn't help me with my queries, etc. that are sitting out in the .xsd file.  But I have had to re-do them so many times that I pretty much have them all memorized.  All of my projects revolve around databases.
Good luck getting it all back together.
0 graham burgess · June 24, 2015
Hello again Glenn,

I just remembered it was tutorial 53, Ctype in The New Boston
0 graham burgess · June 24, 2015
Hi Glenn, thanks for your reply, unfortunately I have had a computer problem and lost the all my v.b. code
0 Glenn Walker · June 22, 2015
That is an error I used to see a lot.  Perhaps you might provide the code that is being executed when this error occurs and what it is that the code is supposed to do?
  • 1

Visual Basic


One of the first products to provide a graphical environment and a paint metaphor for developing user interfaces.

Bucky Roberts Administrator