Sql Syntax To Always Get One?
May 25, 2011
SELECT dbo.Calls.Description, dbo.TicketRead.IsRead, dbo.TicketRead.UserID
FROM dbo.Calls
LEFT OUTER JOIN dbo.TicketRead ON dbo.Calls.CallID = dbo.TicketRead.TicketID
WHERE dbo.TicketRead.UserID = 1 or is null
I want to get a list of all calls, but also a value indicating if the user have read the call. so I made when a user open's the ticket a new record is added in a special table. now if no user have read it then it's ok, but if just one user have read this ticket, then the other users don't have this call in the list..
View 2 Replies
ADVERTISEMENT
Oct 12, 2011
I am having an issue trying to figure this out. I am writing a script editor that uses tabs (a tab control) and I want to implement syntax highlighting. My issue is that every sample I can find on syntax highlighting uses
Private Sub RichTextBox_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RichTextBox1.TextChanged
View 1 Replies
Dec 16, 2009
Can any one translate the following syntax to vb.net.
m_TextBox.Loaded += TextBoxLoaded
m_TextBox.Loaded -= TextBoxLoaded;
private void TextBoxLoaded(object sender, RoutedEventArgs e)[code].....
View 4 Replies
Sep 5, 2011
i have this code:Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
[Code]...
Error 1: Option Strict On disallows late binding.Im using visual basic 2010 express on a gateway laptop thats running Windows 7 OS How do i resolve this error?
View 2 Replies
Apr 9, 2009
I have a listbox and it it I am showing numbers.It should look like this (line by line) 1,2,3,4,5,6,7,8,9,10,11.....but is is showing it like this 1,10,11,...2,20,21...3,30...ow can I make it that it will show it in number order 1,2,3,4,5......
View 5 Replies
Oct 21, 2009
I want to select some rows from a sql express 2005 table. I am using this expression: "Starttime >= " & dtpStart.Value dtpStart is a DateTimePicker But I am getting this error: Syntax error: Missing operand after '14' operator.
View 18 Replies
Aug 7, 2009
I have a web service in c# and its working well in c#.Following is one method i used in it
[WebMethod(EnableSession = true)]
public void abc(BllNew objNew)
{
new DAL.Entity.BllNew().sample();
}
But again i implemented above method in vb and is like this
[WebMethod(EnableSession = true)]
public void abc(BllNew objNew)
{
new DAL.Entity.BllNew().sample();
}
One syntax error is showing near 'new' keyword.What change i hve to get rid of syntax error.
View 2 Replies
Sep 11, 2009
I have the following code snippet:
CODE:
I do not understand the
CODE:
Can someone explain it? For the record...dropOperation is an enum. Can you give vb syntactical equivalent is all I need.
View 10 Replies
Apr 29, 2012
just starting out to learn vb.net. I am doing so cuz i have some vba stuff i need to port.orry for the beginner question: translate this code I use in Outlook to vb.net? I know it's not complete, but I am stuck here.
Private Sub Application_ItemSend(ByVal Item As Object, ByVal Cancel As Boolean)
Dim objNS As NameSpace
im objFolder As MAPIFolder
[code]....
View 1 Replies
Feb 6, 2012
The following is from a WCF sample I am working on.
<ServiceBehavior(InstanceContextMode:=InstanceContextMode.Single)> _
<Foobar()> _
Public Class Service1
I've never understood this and just used examples, but I would like to understand what is going on here. What exactly is the stuff inside the <> brackets? How are these related to Service1? I understand the ServiceBehavior is related to the hosting, but what about Foobar?
View 2 Replies
Jun 7, 2012
I'm trying to display an aggregate feed of several RSS feeds. I'm doing this with an asp page.The problem is I'm getting the error message:Microsoft VBScript compilation error '800a0401' Expected end of statement for the line:Dim feed As SyndicationFe
View 1 Replies
Apr 7, 2011
I used to have this one
Dt = MyMod.GetDataTable("SELECT TOP " & QuestionsPerCats(i) & " * From Questions WHERE CategoriesID ='" & Cats(i) & "' ORDER BY NEWID()")
but now i decided to use sqlparameters like
Dim cmd As New SqlCommand("SELECT TOP @QuestionsPerCats * From Questions WHERE CategoriesID = @CategoriesID ORDER BY NEWID()", conn)
Dim sqlParam As SqlParameter = Nothing
sqlParam = cmd.Parameters.Add("@QuestionsPerCats", SqlDbType.SmallInt)
[code]....
and returns the following error
Incorrect syntax near '@QuestionsPerCats'.
View 3 Replies
Aug 6, 2009
I can't get a handle on the syntax. Can anyone give me a simple demo?
View 3 Replies
Mar 12, 2012
i hope to create an application to check vb.net syntaxes (for simple function or methoe). Application will be given richtext box to add function or method and when submit, need to check that vb.net syntax and it will be execute by powershell.
View 1 Replies
Jun 16, 2010
Is there any differnce between the following syntax? Im thinking that there isnt, as long as the end result of the "AS" portion has RuleType named "AS R.RuleType." Notice that the first snippet of code has the R.RuleType and the second has just Rule.Type.strRule.Append(
"select R.Ruleid,R.RuleNumber,isnull(C.ClientName,'') as ClientName,R.Customerid,Case R.RuleType when 'R' then 'P' when 'B' then 'G' else R.RuleType End as R.RuleType,isnull(C.InternalClientID,'')
as InternalClientID,")
[Code]...
View 2 Replies
Apr 27, 2009
im trying to do a basic calculation and i get a syntax error on what ever if first on the bottom line of this code :
[code].....
at the error is on the bracket on the bottom line but when i remove it , the error goes onto the 805 .everything is declared properly in a module. as integers?
View 2 Replies
Apr 9, 2010
How is VB6 Different from VB.NET in terms of Syntax? what is their relationship and major differences?.
View 7 Replies
Nov 12, 2009
I need to make something like :
if isdbnull(value) or value = something then
'do something
else
[code].....
View 4 Replies
Dec 14, 2009
It was suggested that I use xmldocument.load to do a sql insert statement instead of BULK INSERT.However when I run the Sub I am getting this error: "Incorrect syntax near '<'. "Here is my code, I have no clue what is causing this error, or how to fix it.
Sub AO()
Dim Z As String = Microsoft.VisualBasic.Format(Today.AddDays(-1), "MMddyyyy")
Dim AO_Name As New String("\NetImportAO-M_" & (Z) & ".xml")
Console.WriteLine(AO_Name)
[code].....
View 1 Replies
Jul 14, 2009
tell me the equivalent syntax for the following code in VB.net?
Static Class TestList
{
static void Main()
{
[code].....
View 3 Replies
Jul 4, 2012
how to make this ode right. Public Class FrmSecurityProgram
Private Sub BtnOK_Click(sender As System.Object, e As System.EventArgs) Handles BtnOK.Click
Dim ans As String
'Dim ctr1 As Integer
[code]....
it is a simple security program where it will ask for username and password. the user just have 3 times to try and when its the fourth try the msgbox will show and will tell the user that he exceeds the maximum number of try.
View 14 Replies
Jun 29, 2011
I am getting the error or syntax error , have a look!
[code]...
I am getting the error near the variable "data" I have tried to put double quotes, single quotes and both together but it doesn't solve anything, what is the correct syntax?
View 7 Replies
Jun 25, 2010
In VB.NET, what is the difference between
if foo is Nothing Then
doStuff()
End If
[Code]...
foo is Nothing evaluates to false and foo = Nothing evaluates to true.
However, if bar is declared as an Object and not initialized, then foo is Nothing and foo = Nothing both evaluate to true! I think this is because Integer is a value type and Object is a reference type.
View 6 Replies
Jun 15, 2010
i am already mad at the fact that control arrays are gone..Is the syntax for BitBlt that same from vb6 and vb.net? Can i still use the vbSrcAnd, vbSrcCopy, and vbSrcPaint?I have seen some things on going around control arrays, but how would i do some control arrays for bitblt? i tried
Dim picPicture(0) as picturebox
Dim i
for i = 0 to 10
redim preserve picPicture(i)
picPicture(i).Image = Application.Startuppath & "img" & i & ".bmp"
next
View 30 Replies
May 19, 2010
what is the syntax to round up a decimal leaving 2 digits after the decimal point,
ex: 2.566666 -> 2.57
View 4 Replies
Jan 7, 2012
This my code
Dim verifyUrl As String = Request.Url.GetLeftPart(UriPartial.Authority) & Page.ResolveUrl("~/verify.aspx?ID=" & sGUID)
mail.Body = "<html>" & _
"<head>" & _
"<meta http-equiv=""Content-Language"" content=""fr"">" & _
[code]....
Try for long time to put an like <a href"<%verifyUrl%>"</a> but this not work well................
View 1 Replies
Jul 1, 2011
What is the syntax for != in .net?
eg
if text1.text != "Test" then
Msgbox "Not Test"
end if
View 11 Replies
Apr 22, 2009
I'm trying to figure out what syntax is necessary to disable a particular key. I want the program I'm making to restrict the user to using only letters (basically I just want to figure out how to disable numbers).
View 1 Replies
May 26, 2009
I'm new to Linq, what's the syntax for orderby in VB? [code]Select distinct state from zipcodes order by State
View 2 Replies
Jul 17, 2009
This is a sample of code I'm working with. I don't work with VB6 that much and was wondering if someone could tell me what the .Height refers to:
[code]...
I understand the Screen.Height, but when .Height is subtracted from it, what does .Height represent. Is it also the Screen's Height?
View 7 Replies