Login
Search   Moderators Wanted: If you're interested please send your portfolio to info[at]itechforums.com
Welcome to the iTechForums.
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.
To register now click here.
Latest Threads
Advertisements
Forum Statistics
Threads:
Posts: 3
Members:
Number of Users Online:
Welcome to our newest member,
Reply
 
Thread Tools Display Modes
  #1  
Old 09-17-2009, 03:47 AM
uncreativenickname167 uncreativenickname167 is offline
Junior Member
 
Join Date: Sep 2009
Posts: 1
Default

Microsoft Access/Visual Basic If... Then... statement help!?


Microsoft Access/Visual Basic If... Then... statement help!?

In MS Access, I'm designing a form and I'm trying to make an If, Then statement that causes one text field to display a phrase when another text field is blank. Does anyone know how to do this?

For instance:

If text field named X is blank, then text field Q displays the phrase Current Owner.

And which field would I apply the If, Then statement to?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #2  
Old 09-17-2009, 03:47 AM
maito maito is offline
Junior Member
 
Join Date: May 2008
Posts: 16
Default

you already answered your own question..

If text field named X is blank, then text field Q displays the phrase Current Owner.
...
if (x=null)
{
q=current owner;
}
...
I did not do the whole syntax for you as i don't know how you have them set up..
that is just the pseudocode to help
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3  
Old 09-17-2009, 03:48 AM
DzSoundNirvana DzSoundNirvana is offline
Member
 
Join Date: Jan 2009
Posts: 37
Default

Dim X as String
Dim Q as String

X = Me.X
Q=Me.Q

if IsNull(X) then
Q.value=Current Owner
else
Q.value=Not Current Owner
end if
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Everytime I open Excel a box pops up with Microsoft Visual Basic File not found. Charlie Visual Basic 4 09-17-2009 03:46 AM
does red hat enterprise linux supports microsoft visual studio 2006(visual basic... Sivanesh M Oracle 1 01-08-2009 09:54 PM
What is the use of & in Visual Basic or MS Access SQL statement? sherqa MS SQL 2 05-28-2008 04:46 PM
Microsoft to bring back Visual Basic in Office for Mac (Macworld.com) Tech News Tech News 0 05-13-2008 07:54 AM
i want to know how to use Visual Basic 6.0 language on Visual Basic 2008.? Nik Visual Basic 1 05-06-2008 12:40 PM

Your Ad Here

All times are GMT. The time now is 03:20 AM.