-
August 25th, 2015, 03:21 PM
#1
syntax error
="This letter is to verify that " & UCase([LastName]) & IIf(Len([FirstName])=0,"",", ") & UCase([FirstName]) & " " & UCase([MiddleName]) & " has been accepted to study at our institution, accredited by the Accrediting Council for Continuing Education & Training. This student will be enrolled as a full-time international student enrolled in " & [Forms]![Fr_Dialog Rep Acceptance Letter].[CbClass].[Column](1) " & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtMrMs] " & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtStdLastName] & "."
It works when I stop it after the (1) but i need to put the Mr and Mrs as well as the last name any help??
-
August 26th, 2015, 06:48 AM
#2
Re: syntax error
The " after the (1) seems out of place as does the one after the MrMs]
The line may also be to long
Always use [code][/code] tags when posting code.
-
August 26th, 2015, 02:16 PM
#3
Re: syntax error
Hey thanks for the reply
The 1 works in the code if i leave it there but the rest does not, and if MrMs] is out of place how or where should it be?
and sorry i did not know about that i am new to this
-
August 26th, 2015, 02:33 PM
#4
Re: syntax error
As I said before the Quotes are what look to be a problem
international student enrolled in " & [Forms]![Fr_Dialog Rep Acceptance Letter].[CbClass].[Column](1) " & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtMrMs] " & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtStdLastName] & "."
Those ones I marked in red don;t look like they should be there.
Your line may also be to long
Always use [code][/code] tags when posting code.
-
August 26th, 2015, 02:46 PM
#5
-
August 26th, 2015, 05:56 PM
#6
Re: syntax error
I have more question if you can help me out with when i try to put the date in i get the same error but i only want it to show when they click the yes bubble if not then not appear does this look correct? If not can you help me?
[ & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtMrMs] & [Forms]![Fr_Dialog Rep Acceptance Letter]![TxtStdLastName] will begin his studies on =[Forms]![Fr_Dialog Rep Acceptance Letter]![date box][Forms]![Fr_Dialog Rep Acceptance Letter]![bubble two]![Forms]![Fr_Dialog Rep Acceptance Letter]![bubble one] & "." ]
-
August 26th, 2015, 11:08 PM
#7
Re: syntax error
I have no idea what bubble is, I don't even know what that code is from. It definitely does not look like VB code, I'm guessing maybe Word VBA but I have never bothered to write code in Word so only a guess.
Seems very cluttered and hard to follow due to all the repetition of [Forms]![Fr_Dialog Rep Acceptance Letter]. Surely even in Word there is a way to code this without all of that junk in there.
Always use [code][/code] tags when posting code.
-
August 27th, 2015, 12:45 PM
#8
Re: syntax error
Well the thing is im new to vb6 and this is our project im just editing it is in access and im just looking at the code in vb and it looks like that maybe if i could turn the access project into vb6 it would be easier?
But i dont know how to do that so im stuck
-
August 27th, 2015, 04:18 PM
#9
Re: syntax error
Just to be clear when you are in Access and viewing code what you are actually using is VBA. The IDE does say it is VB6 but it really isn't. VB6 is a different and totally separate animal. VBA does share a lot of features with VB and then has other features depending on which product it is used from.
At any rate the line of code you posted is not a complete line and the part that is there does not look valid. It is far to cluttered and really needs to be trimmed down for the sake of readability.
I still have no idea what "bubble" is
Always use [code][/code] tags when posting code.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|