• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

access/vba

zerocool1

Diamond Member
NVM I got it figured out

I'm writing a query for access in vba.

d_clause = d_clause & " FROM temptbl WHERE ((Not ((temptbl.[description of communication]) Like *Scenario '" & scenariono & "':*) And (temptbl.[description of communication]) Like *scenario*));"

once again a quotations problem.
scenariono is an string that comes from a frame.

can someone help me fix it.

thank you much

Amit
 
Lots of things wrong. I assume variation is a string also.

w_clause = "WHERE (((Table1.[description of communication]) Not Like '*" & variation & "*') AND (([Trans type].Abbrev) Like '*" & stTrans & "*') AND ((Table1.State) Like '--' Or (Table1.State) Like '*" & stState & "*'));"
 
Need more info. That statement can be understood a ton of different ways. Assuming the word 'scenariono' is a variable, and you are looking in the 'description of communication' for values that are like '*Scenario ' and the value of the variable 'scenariono' this would do it:

d_clause = d_clause & " FROM temptbl WHERE Not temptbl.[description of communication] Like '*Scenario " & scenariono & "':*' And temptbl.[description of communication] Like '*scenario*'));"
 
Back
Top