select-case Questions

14

Solved

How can I use a condition inside a switch statement for JavaScript? In the example below, a case should match when the variable liCount is <= 5 and > 0; however, my code does not work: switch...
Placeman asked 28/3, 2011 at 19:57

7

Solved

So I have something like the following in Vb6; Select case Case case "Case0" ... case "Case1" if Condition Then Exit Select End If *Perform action* case "Case2" ... End Select But for so...
Galen asked 23/5, 2012 at 14:55

2

Solved

I'm looking to carry out a Select Case with just one case - where the case is not equal to "P", "Ev" or "Af". This is what I have so far. Select Case Range("my_range").Offset(0, column_offset).Va...
Offence asked 10/4, 2014 at 11:55

3

Solved

I have tried the below: Select Case Combo1.SelectedItem Or Combo2.SelectedItem But I get the error: Conversion from String "string here" to type 'Long' is not valid Is it possible to have mul...
Muir asked 20/12, 2012 at 10:56

1

Solved

This is not a duplicate of this question : VB.NET Stacking Select Case Statements together like in Switch C#/Java. The answer provided here does not answer my question. The answer there is stating ...
Milkfish asked 10/5, 2016 at 14:28

2

Solved

I'm using the following query to create a view in Oracle 11g (11.2.0.3.0). CREATE OR REPLACE FORCE VIEW V_DOCUMENTS_LIST ( ID_DOC, ATTACHMENTS_COUNT, TOTAL_DIMENSION, INSERT_DATE, ID_STATE, ...
Seven asked 20/11, 2015 at 13:48

2

I'm working on a macro that takes the current value of the ActiveCell and changes that value based on a select case. However, I am unable to determine if the ActiveCell contains a wild card strin...
Cookie asked 23/8, 2013 at 18:23

6

Solved

I was wondering if there was a way to directly convert the integer DayOfWeek returns into a string representing the day like Monday, Tuesday etc. Sample code: MessageBox.Show(Date.Today.DayOfWeek...
Foliose asked 30/1, 2010 at 19:31

3

Solved

I'm trying to create a series of commands that can take parameters. To pick up each separate command I am using Select Case The problem with this is I can't sense the 'parameters' (the second part ...
Duhamel asked 5/1, 2014 at 10:10

5

Solved

I recently switched from VB to C#. One thing that I noticed was that in C#, I have problems using comparisons as part of the case. I am not sure how to explain it in words, so here is an example of...
Corrinacorrine asked 10/9, 2013 at 7:16

3

Solved

Let's say you want do something along the following lines: SELECT CASE WHEN (SELECT COUNT(id) FROM table WHERE column2 = 4) > 0 THEN 1 ELSE 0 END Basically just return 1 when there's one o...
Autogamy asked 30/10, 2012 at 13:55

5

Solved

I'm not sure if this valid C#, but hopefully you get the idea. :) switch (msg.GetType()) { case ClassA: // blah case ClassB: // blah 2 case ClassC: // blah 3 } How would I switch on an obj...
Buddhism asked 19/8, 2009 at 18:43

2

Solved

Is there a way to use the Select Case statment in VB.net for beginswith? Or do i have to use a long elseif? Example: If text.StartsWith("/go") then elseif test.StartsWith("/stop") elseif test.Star...
Leandroleaning asked 22/9, 2010 at 19:33

4

Solved

I'm converting some VB6 logic to C# and have encountered the following SELECT/CASE statement. Select Case ZipCode Case 1067 To 19417, 35075 To 35085, 48455 To 48465, 55583 To 55596, 67480 To 67551...
Talishatalisman asked 27/8, 2010 at 13:4

1

Solved

Is there anyway I can build a Select statement that uses the Contains function? Like this: Select commentStr Case commentStr.Contains("10") Case commentStr.Contains("15")
Pitiful asked 15/4, 2010 at 17:58

2

Solved

Here are a couple of questions I gathered regarding exit select... Is there any reason for using exit select in VB.NET? Does the reason have anything to do with performance? Is the exit select eq...
Superfine asked 17/12, 2009 at 19:50
1

© 2022 - 2024 — McMap. All rights reserved.