Hi,
simple question, and maybe I'm just too blind finding it, but: is there a
simple way to have Option Explicit and Option Strict switched to on by
default with the IDE, or do I have to create new templates for
VB-Applications?
Thanks,
Klaus 19 1047
Without any project opened. Set option strict to ON and then it will remain
on.
OHM
Klaus Löffelmann wrote: Hi,
simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications?
Thanks,
Klaus
* "Klaus Löffelmann" <fo***********@loeffelmann.de> scripsit: simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications?
In the project properties, "General properties" -> "Bild" set "Option
Strict" to "On".
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
OHM,
without any project opened, who *do* I actually set this option to on?
Klaus
(feeling like No Eyed Man... ;-)
"One Handed Man" <Bo****@Duck.net> schrieb im Newsbeitrag
news:bp**********@titan.btinternet.com... Without any project opened. Set option strict to ON and then it will
remain on.
OHM
Klaus Löffelmann wrote: Hi,
simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications?
Thanks,
Klaus
Hi Herfried,
I thought will I write a message, Herfried is giving a message in German,
that is to tickle, and then I saw it was just a typo :-( In the project properties, "General properties" -> "Bild" set "Option Strict" to "On".
:-)
Cor
TOOLS / OPTIONS/ PROJECTS/VB DEFAULTS
OHM
Klaus Löffelmann wrote: OHM,
without any project opened, who *do* I actually set this option to on?
Klaus (feeling like No Eyed Man... ;-)
"One Handed Man" <Bo****@Duck.net> schrieb im Newsbeitrag news:bp**********@titan.btinternet.com... Without any project opened. Set option strict to ON and then it will remain on.
OHM
Klaus Löffelmann wrote: Hi,
simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications?
Thanks,
Klaus
* "Cor" <no*@non.com> scripsit: I thought will I write a message, Herfried is giving a message in German, that is to tickle, and then I saw it was just a typo :-(
Ooops... Really ugly typo. In German it's called "Erstellen". In the project properties, "General properties" -> "Bild" set "Option Strict" to "On".
Replace "Bild" with "Build".
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
I think he wanted this as a default, not for the specific project.
OHM ( God I wish I could be an MVP )
Herfried K. Wagner [MVP] wrote: * "Cor" <no*@non.com> scripsit: I thought will I write a message, Herfried is giving a message in German, that is to tickle, and then I saw it was just a typo :-(
Ooops... Really ugly typo. In German it's called "Erstellen".
In the project properties, "General properties" -> "Bild" set "Option Strict" to "On".
Replace "Bild" with "Build".
* "One Handed Man" <Bo****@Duck.net> scripsit: I think he wanted this as a default, not for the specific project.
Mhm... You already gave the answer. I thought he wanted it as default
for all files in the project.
;->
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
"Klaus Löffelmann" <fo***********@loeffelmann.de> schrieb simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications?
In VB 2003, you can go to Extras -> Optionen -> Projekte -> VB-Standard:
Option Strict ON
In VB 2002, you can change the template, e.g. in
E:\Programme\Microsoft Visual Studio
..NET\Vb7\VBWizards\WindowsApplication\Templates\1 031\WindowsApplication.vbpr
oj
There must be
<Settings
OutputType = "WinExe"
OptionExplicit = "On"
OptionStrict = "On"
--
Armin http://www.plig.net/nnq/nquote.html http://www.netmeister.org/news/learn2quote.html
I was referring to 2003 - see my post.
OHM
Armin Zingler wrote: "Klaus Löffelmann" <fo***********@loeffelmann.de> schrieb simple question, and maybe I'm just too blind finding it, but: is there a simple way to have Option Explicit and Option Strict switched to on by default with the IDE, or do I have to create new templates for VB-Applications? In VB 2003, you can go to Extras -> Optionen -> Projekte -> VB-Standard: Option Strict ON
In VB 2002, you can change the template, e.g. in
E:\Programme\Microsoft Visual Studio
..NET\Vb7\VBWizards\WindowsApplication\Templates\1 031\WindowsApplication.vbpr oj
There must be <Settings OutputType = "WinExe" OptionExplicit = "On" OptionStrict = "On" >
I didnt realise that the TOOLS/OPTIONS etc was not not available in 2002
Version as Armin pointed out.
Cheers - OHM
Herfried K. Wagner [MVP] wrote: * "One Handed Man" <Bo****@Duck.net> scripsit: I think he wanted this as a default, not for the specific project.
Mhm... You already gave the answer. I thought he wanted it as default for all files in the project.
;->
* "One Handed Man" <Bo****@Duck.net> scripsit: I didnt realise that the TOOLS/OPTIONS etc was not not available in 2002 Version as Armin pointed out.
Huh... I didn't remember that too...
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
* "One Handed Man" <Bo****@Duck.net> scripsit: I was referring to 2003 - see my post.
.... and I still prefer these 3 lines on top of every source file:
\\\
Option Explicit On
Option Strict On
Option Compare Binary
///
;-)
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Hi Herfried, ... and I still prefer these 3 lines on top of every source file:
\\\ Option Explicit On Option Strict On Option Compare Binary ///
Maybe that will be in Withbey?
:-)))
Cor
* "Cor" <no*@non.com> scripsit: ... and I still prefer these 3 lines on top of every source file:
\\\ Option Explicit On Option Strict On Option Compare Binary /// Maybe that will be in Withbey?
Why? That's possible since VB.NET 2002.
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Herfried,
Than I do something wrong,
I did everything you and OHM said, but I still have to put it by hand above
my code.
So what do I wrong.
Cor
* "Cor" <no*@non.com> scripsit: Than I do something wrong,
I did everything you and OHM said, but I still have to put it by hand above my code. So what do I wrong.
You checked the options in the project's settings?
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Herfried,
Yes and I cannot write my favorite code on a brand new form
Dim a As Integer = 3 * 2 / 1
So option Strict is on, but not placed above the form.
But it is not that important, has its charm if I forgot it, and today I saw
I did.
:-))
Cor This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Microsoft News |
last post by:
I have a project that was created all with Option Strict OFF. Works great,
not a problem with it. But if I turn Option Strict ON then I get a LOT of
errors.
My question, should I even care...
|
by: Brett |
last post by:
I find there is more casting required in C# than VB.NET. If Option
Strict/Explicit is turned on, will this basically create the same
environment as C# - uppercase, more casting required, must...
|
by: zacks |
last post by:
A common programming technique I use in VB is making a collection of
structures. But if Option Strict is on (which I would prefer), the .Add
that adds the structure to the collection is flagged...
|
by: YYZ |
last post by:
After reading many messages in this group, it seems that the preferred
setting for this is ON. Okay, I did that in my project (first with
..Net -- long time VB6 developer) and now a bunch of...
|
by: guy |
last post by:
when i first started using .net (beta 1) i came across option strict and
thought hey this could be really good, and since then have always turned it
on, most people here seem to agree that this is...
|
by: John |
last post by:
Hi
I have a vs 2003 project which I have just imported into vs 2005. Now I am
getting the "Option Strict On disallows operands of type Object for operator
'='. Use the 'Is' operator to test for...
|
by: jonniethecodeprince |
last post by:
Hello everyone. Last Friday I finally found a good compiler for PERL and the "shebang" line I think I need to run. They might not be running on a server but certainly they compiling well on my hard...
|
by: =?Utf-8?B?R3JlZw==?= |
last post by:
We have an application in our office that has the Option Strict option set to
off right now. I do understand it should be set to ON, but right now, I'm
just going to continue with it this way since...
|
by: Erwin Moller |
last post by:
Hi group,
I encoutered page validation error, but I don't know a way around.
The page has the following doctype:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: Shællîpôpï 09 |
last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |