Solved

urgent: VB error " selected collating sequence not supported by the operating system"

Posted on 2004-09-29
9
1,065 Views
Last Modified: 2008-03-06
Experts,
I have some VB coding as below, and as i run the program it pop up an error state that "selected collating sequence not supported by the operating system".... how to solve this problem...?
Here is my code: In a module

Global cnn As ADODB.Connection
Global gblstrCnnString As String

Sub Main()
 
  'some code here

  gblstrCnnString = "Provider=Microsoft.Jet.OLEDB.4.0;Persist Security Info=False;Data Source="

  Set cnn = New ADODB.Connection
  cnn.Open gblstrCnnString & App.Path & "\Package.mdb" 'open connection
  cnn.CursorLocation = adUseClient
      
  'some code here
End Sub


The Sub Main() I put it in a Module, while in a form, this is my code:



Option Explicit
Dim Rst As ADODB.Recordset

Sub refreshPackage()
   
       
    On Error Resume Next
   
    '****** Move Package Number Into combobox ********'
        strSQL = "SELECT distinct[PackageName] FROM PackageConfigure"  
       
        Set Rst = cnn.Execute(strSQL)
   
        cboSearch.Clear
       
        While Not Rst.EOF
            cboSearch.AddItem Rst.Fields(0)
            Rst.MoveNext
        Wend
        Rst.Close
    '*************************************************'
End Sub


Why when I run this code in other computer, no problem occur, but when I run it in my computer, the error exist. Can anybody help me on this...? I need it urgent.


rdgs,
sawai
0
Comment
Question by:sawai_tan
9 Comments
 

Author Comment

by:sawai_tan
ID: 12177942
some info,
when i change  the strSQL = "SELECT distinct[PackageName] FROM PackageConfigure"  
to                            strSQL = "SELECT * FROM PackageConfigure"  

no error come out.....

what is the solution?



rdgs,
sawai
0
 
LVL 16

Accepted Solution

by:
jimbobmcgee earned 500 total points
ID: 12177953
Microsoft suggest this is a multilanguage issue.  There is a workaround listed at http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/Q202/1/50.ASP&NoWebContent=1

Give that a try...
0
 
LVL 8

Expert Comment

by:mladenovicz
ID: 12177971
Try this
strSQL = "SELECT distinct [PackageName] FROM PackageConfigure"  
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Expert Comment

by:yuvaprakash
ID: 12178538
The problem must be,

You are trying to open a database or an object in a database that was created in another language edition of Microsoft Access.
You are trying to open a database that was created or compacted while the New Database Sort Order was set to a value other than General.

-from Microsoft

for complete describtion see this,
http://support.microsoft.com/default.aspx?kbid=184988

cheers
0
 

Author Comment

by:sawai_tan
ID: 12185891
why I run the program in other computer, no error come out, but when I run it in my computer, the error come out....?
0
 
LVL 16

Expert Comment

by:jimbobmcgee
ID: 12188244
If it is due to the error described in the Microsoft KB article that I posted, it is probably because the Access database file was created using a language/character set/code page that is supported by the other computer but not yours.

In order for the program to work on your machine, you need to have the compatible language/character set/code page installed on your machine.

Read the posted Microsoft articles for more information.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now