A Microsoft Office (Excel, Word) forum. OfficeFrustration

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.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Syntax ^'(ctrl + ')



 
 
Thread Tools Display Modes
  #1  
Old September 12th, 2005, 03:17 PM
michael
external usenet poster
 
Posts: n/a
Default Syntax ^'(ctrl + ')

i am trying to do an update of a table with an IIF() statement where if my
criteria is true the upade copies the previous record i cannot get the synatx
right for sendkeys it may that it is not possible?
  #2  
Old September 12th, 2005, 06:23 PM
John Vinson
external usenet poster
 
Posts: n/a
Default

On Mon, 12 Sep 2005 07:17:02 -0700, "michael"
wrote:

i am trying to do an update of a table with an IIF() statement where if my
criteria is true the upade copies the previous record i cannot get the synatx
right for sendkeys it may that it is not possible?


Well... DON'T use Sendkeys for this. It's unreliable and buggy, and
there's never a *good* reason to use it.

I would suggest either using DLookUp to find the value in the
"previous" record in the Table, if you have some criteria to identify
which is the 'previous' record (a table has no order so this may be
difficult); or, you can use a contro'ls AfterUpdate event to set that
control's Tag property to its Value, and then pull the value from the
Tag in your conditional code.

Could you explain what you're attempting to accomplish? There may be
an easier way!

John W. Vinson[MVP]
  #3  
Old September 12th, 2005, 08:29 PM
Mike Gill
external usenet poster
 
Posts: n/a
Default

I am importing an excel spreadsheet that has been exported from another
proprietry program i first import it and the append to my tblImportProducts
with fldPartNumber,fldDescription and fldProductGroup. The imported spread
sheet has a empty PartNumber in the first row but has a Product Group in the
Description. I append the Description to both the fld Description and
fldProductGroup then i was going to update the fldProductGroup with IIf
(fldPartNumber is not null,ctrl', fldProductGroup)


Part Number Description ProductGroup
Widgets Widgets
1 W1 W1
2 W2 W2
3 W3 W3
Things Things
4 T1 T1
5 T2 T2


Michael


"John Vinson" wrote in message
...
On Mon, 12 Sep 2005 07:17:02 -0700, "michael"
wrote:

i am trying to do an update of a table with an IIF() statement where if

my
criteria is true the upade copies the previous record i cannot get the

synatx
right for sendkeys it may that it is not possible?


Well... DON'T use Sendkeys for this. It's unreliable and buggy, and
there's never a *good* reason to use it.

I would suggest either using DLookUp to find the value in the
"previous" record in the Table, if you have some criteria to identify
which is the 'previous' record (a table has no order so this may be
difficult); or, you can use a contro'ls AfterUpdate event to set that
control's Tag property to its Value, and then pull the value from the
Tag in your conditional code.

Could you explain what you're attempting to accomplish? There may be
an easier way!

John W. Vinson[MVP]



 




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 Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Syntax error in CONSTRAINT Corrado Running & Setting Up Queries 1 May 3rd, 2005 04:25 PM
Make the syntax in Access consistent aoeusnth General Discussion 1 April 7th, 2005 05:59 AM
Complex Subquery: ... FROM (TRANSFORM.... Syntax error Stephen Rasey Running & Setting Up Queries 2 August 25th, 2004 03:44 PM
syntax to run PL/SQL stored proc via ms access pass through query Edwinah63 General Discussion 2 June 23rd, 2004 03:47 AM
Syntax of excel Tapani Tuominen Worksheet Functions 2 March 30th, 2004 09:12 PM


All times are GMT +1. The time now is 02:44 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.