How can I get a list of DSNs currently registered?
Hi everybody,
Can anyone tell me how to obtain a list of the DSNs currently registered on my machine using Java?
I want to populate a drop-down list for the user (an administrator) to select the requisite DSN to work with.
I realise that this is probably platform-specific (Windows in my case), hence posting here under JNI.
I have searched the forums here at great length for the solution, but only seem to find unhelpful replies along the lines of 'JDBC can't do that - you'll need to resort to JNI'. So could I politely ask that if you don't actually know how to do it (or can at least provide a pointer or two) then please do not reply telling me ways in which it can't be done.
Many thanks for your help.
Paul.
Hi,
Thanks for the pointers.
I already know the Windows API (I'm converting a VB app into Java and need to pick up the DSNs created for the original VB app to use via JDBC).
Regarding picking it up from the registry - I don't know how to do this via Java. I've been looking at Preferences, but it seems to me that you don't have complete access to the Registry via Preferences - am I right about that?
Re the third-party library: I have seen it mentioned a few places, seached on Google, etc, and even followed a few hopefull-looking links but I always come up with nothing :(
Ho-hum...any other suggestions please?
Cheers,
Paul.
Similar Messages
-
How can i get a print of all my registered apple products?
How can I get a list of all my registered Apple products so I can print and keep on hand?
http://support.apple.com/kb/HT2526 - If you registered a device you can use My Support Profile to find a list of serial numbers that have been purchased or registered with your Apple ID.
My Support Profile - https://supportprofile.apple.com/MySupportProfile.do -
How can I get a list of apps which are supported on ipod touch model ma623zo?
How can I get a list of apps which are supported on ipod touch model ma623zo?
It's about 6 years old I think.
I have put the latest IOS on there (currently 3.1.3 (7E18)).
I download apps from the app store but they often fail to launch. I assume they're incompatible.
Is there a way to check which apps will work and which won't before I buy them?
Thanks!I have no idea how my reply could be "misleading". I stated the exact situation: there are millions of apps in the iTunes Store, and providing a comprehensive, accurate list of which apps support which version(s) of iOS would be highly impractical. You can perhaps help with your search by going to AppShopper:
http://appshopper.com/search/?search=iOS+3
That will give you at least some starting points, but AppShopper is neither comprehensive nor completely accurate. I've found a number of apps listed there over the time the site has existed that either are no longer offered or which have been updated beyond the iOS version indicated. But it might help.
Regards. -
How can I get a list of database names from environment
Hi,
How can I get a list of database names from environment.
I had found a method in JE API Docs named Environment.getDatabaseNames(), and i couldn't found the same method in Berkeley DB.
I use java interface, is it supported?
Thanks.Hello,
I don't know if it would work for you, but have you checked the db_archive utility at:
http://download.oracle.com/docs/cd/E17076_01/html/api_reference/C/db_archive.html
Check the -s option.
Thanks,
Sandra -
HT1420 how can I get a list of the computers that are currently authorized?
I need to authorize my home computer after switching from PC to Mac. How can I get a list of which devices are currently authorized?
There is no list.
-
Hi ,how can I get a list of all laptops or users with folder direction enabled or offline files enabled, be it sccm
or poerwshell . i have struggled for a week
tchocrHi,
There is no such PowerShell command can achiev this. Maybe you can use a script to get the user name with folder redirection enabled. However, I am not familiar with writing script, and it would be better for you to ask in script forum below for professional
assistance:
http://social.technet.microsoft.com/Forums/en-US/home?forum=ITCG&filter=alltypes&sort=lastpostdesc
Best Regards,
Mandy
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact [email protected] -
How can I get a list of purchased apps?
Recently restored my iPhone from backup, and I need to download my apps. How can I get a list of apps that I've downloaded/purchased?
If I search for an app via the app store that I had previously installed, the Install icon turns into a Cloud with a down arrow symbol on it - there must be a way to get a list of all of these right?
Anyone clever enough to solve this riddle?Open the App Store app, go to the Updates pane and tap Purchased.
-
How can I get a list of all workbooks
Can anybody please tell me how can I get a list of all my workbooks that are on my Oracle Discoverer database without having to manually write them down? I am using Oracle Database 10g Enterprise Edition.
Hi,
To implement the EUL Management BA follow metalink NOTE:556932.1
there are very simple steps you need to perform in order to use it -
How can I get a list of all my annotations to send to someone else, listed by PAGE #, not order??
The comments list is sorted by page by default. If it's not for some reason, click the "Sort comments" button and select that option. It looks like this:
-
How can I get a list of all laptops or users with folder direction enabled or offline files enabled, be it sccm or poerwshell . i have struggled for a week.
Hi,
There is no such PowerShell command can achiev this. Maybe you can use a script to get the user name with folder redirection enabled. However, I am not familiar with writing script, and it would be better for you to ask in script forum below for professional
assistance:
http://social.technet.microsoft.com/Forums/en-US/home?forum=ITCG&filter=alltypes&sort=lastpostdesc
Best Regards,
Mandy
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact [email protected] -
How can I get file list for a given directory?
Hi,
How can I get file list for a given directory? Is there a function?
Thanks.Hi friend,
Try this sample report. It displays all files in a directory.
While executing give some directory name in input. ex: C:\
Mention file type in filter parameter. ex: *.DOC
REPORT ztests.
DATA : file_table LIKE TABLE OF sdokpath WITH HEADER LINE .
DATA : dir_table LIKE TABLE OF sdokpath WITH HEADER LINE .
PARAMETERS:p_dir(50) TYPE c.
CALL FUNCTION 'TMP_GUI_DIRECTORY_LIST_FILES'
EXPORTING
directory = p_dir
filter = '*.DOC'
TABLES
file_table = file_table
dir_table = dir_table
EXCEPTIONS
cntl_error = 1
OTHERS = 2.
LOOP AT file_table .
WRITE:/ file_table-pathname.
ENDLOOP.
Might be helpful...
Thanks.....
Edited by: Guest77 on Feb 11, 2009 5:30 AM -
How can I get a list of active savepoints for the current session?
Hi,
In Oracle Applications, we are getting the following error while performing ROLLBACK to a Savepoint.
"Unexpected Error: ORA-01086: savepoint 'PTNR_BULK_CALC_TAX_PVT' never establishe d ORA-06510: PL/SQL: unhandled user-defined exception"
So how can I get a list of active savepoints for the current session?
Could you please also let me know if there is any better way to debug this issue.
Appreciate any quick response as the issue is very critical.
Thanks,
Somauser776523 wrote:
Hi,
In Oracle Applications, we are getting the following error while performing ROLLBACK to a Savepoint.
"Unexpected Error: ORA-01086: savepoint 'PTNR_BULK_CALC_TAX_PVT' never establishe d ORA-06510: PL/SQL: unhandled user-defined exception"It sounds like there's an execution path in the code where the SAVEPOINT is never issued.
There is no way to get a list of active savepoints. Is this your code or a "canned" procedure? If it is your code you can go through the code looking for answers, possibly tracing execution using DBMS_OUTPUT.PUT_LINE or writing messages to a log table. If its a "canned" procedure you may need to open an SR with Oracle -
How can i get the list of all users present in the LDAP
Hi Experts,
How can i get the list of all users present in the LDAP ?
Is there any API or function Code to get all user list??
Please help me out!!!
Help will be rewardedWell it will depend on exactly where your UME configuration points to in the LDAP tree but yes, it is possible to get all users. Something like the following should do it:
import com.sap.security.api.*;
import com.sapportals.portal.prt.component.*;
IUserFactory iuf;
ISearchResult isr;
IUser user
String userid;
iuf = UMFactory.getUserFactory();
isr = iuf.getUniqueIDs();
you will need to iterate the ISearchResult object but you can get IUser objects by
userid = (String)isr.next();
user = iuf.getUser(userid);
then you can imanipulate / identify / or whatever you need with the user object
Haydn -
How can i get the list of all users present in the UME ?
Hi Experts,
How can i get the list of all users present in the UME ?
Is there any API or function Code to get all user list??
Please help me out!!!
Help will be rewarded
-pankaj chouhanHi Pankaj,
find the official NetWeaver security javadocs (including access to UME) <a href="http://help.sap.com/javadocs/NW04S/current/se/index.html">here</a>. Look for classs UMFactory and proceed from there.
Best regards,
Martin -
How can I get a list of products
Hi!
How can I get a list of products via java interface? I know how to get items of product (via SBOCOMUtil.getProductTrees(company, "PcCw0001")), but which source of code list for second param?Should be sth like this (I have no chance to test Java code ):
IRecordset Src_Rec;
int i, ii;
String str2="";
try
Src_Rec= SBOCOMUtil.newRecordset(aCompany);
Src_Rec.doQuery("SELECT Code FROM OITT");
ii = Src_Rec.getRecordCount().intValue();
// could be a while-loop as well
for(i =0; i< ii;i++)
try
str2 = Src_Rec.getFields().item(new Integer(0)).getValue().toString();
Src_Rec.moveNext();
catch(Exception e)
catch(Exception e2)
HTH,
Frank
Maybe you are looking for
-
PS3 / Xbox 360 / PC Router Guide For GAMERS
Downloadable for Wordpad or Microsoft Word: http://www.filefactory.com/file/b1e67ga/n/Gaming_Router_Guide.rtf Or just read below: PS3, XBOX 360, PC GAMING Router Guide and Modem Guide Introduction: Having issues trying to get your PS3, or XBOX 360 fr
-
Firefox recently did an automatic update for firefox to version 29 upon restart and all the tabs I had before won't load as before. It appears that the number of tabs open up saying "new tab" on each one but they won't load once I click on them as be
-
Good Reader question ...
I have an issue with not being able to bring back auto disapearing menu . ( Ipad ios 4.2.1 Good Reader v 3.2.0 ) I have a simple sheet PDF document and when I tap a link in the PDF document it shows desired html file - but ..... menu disapears after
-
Starting with the 2nd page, the pages are expanded and the whole right side of the page is gone. This only seems to happen on my Mac. I run Firefox on my PC and it prints correctly. At first I thought it was a problem with certain websites, but it al
-
Its looking like on big nightmare..
So I just bought a used older ibook from 2000, and the thing seems to be this big problem now. it did not come with any softwear, so i wanted to reformat the machine using my tiger cd's but the thing did not come with a DVD drive so i went and bought