Results 1 to 4 of 4
  1. #1
    sri123 is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Dec 2014
    Posts
    12

    VBA string value Truncates and reads (???.????ú ? ???????.?.?y????ú ???? )

    Here is the Scenario:
    I have table with Column Name "Notes", one of these Notes record has below value
    qqwerrrrrrqreqwerewrqewreqwrewrewioruioqweuroiuweo ruoweiquriuqweoruoweiuriouqweoriqwerrrrrrqreqwerew rqewreqwrewrewioruioqweuroiuweoruoweiquriuqweoruow eiuriouqweoriqwerrrrrrqreqwerewrqewreqwrewrewiorui oqweuroiuweoruoweiquriuqweoruoweiuriouqweoriwerrrr rrqreqwerewrqewreqwrewrewioruioqweuroiuweoruoweiqu riuqweoruoweiuriouqweori

    I am trying to pull this value from table and trying to append for all records.

    Set db = CurrentDb()

    Set rs = db.OpenRecordset("qrySummaryNotes")
    rs.Filter = "[tabName] = 'General'"
    Set rsNew = rs.OpenRecordset
    'dbNotes = rs.Fields("totalNotes")
    If rsNew.RecordCount > 0 Then

    If Not (rsNew.EOF And rsNew.BOF) Then

    rsNew.MoveFirst

    Do Until rsNew.EOF = True

    dbNotes = rsNew.Fields("totalNotes")
    strNotes = strNotes & vbCrLf & vbCrLf & dbNotes

    rsNew.MoveNext

    Loop
    End If



    Now the strNotes is reading half value correct: Please see below, why am I seeing these strange ?????

    qqwerrrrrrqreqwerewrqewreqwrewrewioruioqweuroiuweo ruoweiquriuqweoruoweiuriouqweoriqwerrrrrrqreqwerew rqewreqwrewrewioruioqweuroiuweoruoweiquriuqweoruow eiuriouqweoriqwerrrrrrqreqwerewrqewreqwrewrewiorui oqweuroiuweo  ???.????ú ? ???????.?.?y????ú ????
    ?? ?.???.?Ñ?  
    ? ???????.???y????????
    ?y?.????????????? ???

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    You really have gobbledygook in field or you just intended that to represent data?

    You want the same value copied to all records?

    I don't understand the looping structure. What string are you trying to build? Maybe show sample records and desired result.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    sri123 is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Dec 2014
    Posts
    12
    Well the data I have shown you was a sample one, am trying to store the history of Notes, at times the user may enter a long string..

    Below is the sample data..



    DateAdded Notes TabName
    12/1/2014 0:00 fdsfdsfdsfsdfdasf General
    12/9/2014 0:00 dfasdfasdfdasfasd General
    12/23/2014 0:00 adfaefsdfds General
    11/26/2014 0:00 dfdsfasdf General
    10/29/2014 0:00 dsfasdfdasf General
    12/25/2014 0:00 dsfasdfasdfasdf General
    12/1/2014 14:31 This is to test General tab Control Comments section for Martech 100.. General
    12/1/2014 14:46 This is to test the Mat Tech Id 10 in General tab General

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    That is the raw data? Dpesn't show me the result you want.

    Are you trying to save a string that concatenates the date and note of all related records into table? Why would you even want to do that?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Unbound text box truncates leading zeros
    By brharrii in forum Forms
    Replies: 4
    Last Post: 01-10-2016, 08:06 PM
  2. List column(x) reads null
    By edson in forum Access
    Replies: 8
    Last Post: 12-04-2014, 12:33 PM
  3. String
    By Rhubie in forum Queries
    Replies: 1
    Last Post: 05-28-2013, 09:15 PM
  4. Vba string
    By rchtan in forum Programming
    Replies: 5
    Last Post: 05-17-2012, 04:29 AM
  5. Report Field Truncates
    By Topcerv in forum Access
    Replies: 4
    Last Post: 07-23-2011, 03:29 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums