Kaydet (Commit) 9476a735 authored tarafından Rüdiger Timm's avatar Rüdiger Timm

INTEGRATION: CWS sdk01 (1.3.20.1.6); FILE MERGED

2003/03/13 11:39:21 jsc 1.3.20.1.6.1: #107908# catch exception
üst 19633396
...@@ -102,8 +102,18 @@ int SAL_CALL main( int argc, char **argv ) ...@@ -102,8 +102,18 @@ int SAL_CALL main( int argc, char **argv )
Reference< XUnoUrlResolver > resolver( xInterface, UNO_QUERY ); Reference< XUnoUrlResolver > resolver( xInterface, UNO_QUERY );
// Resolves the component context from the office, on the uno URL given by argv[1]. // Resolves the component context from the office, on the uno URL given by argv[1].
xInterface = Reference< XInterface >( try
resolver->resolve( sConnectionString ), UNO_QUERY ); {
xInterface = Reference< XInterface >(
resolver->resolve( sConnectionString ), UNO_QUERY );
}
catch ( Exception& e )
{
printf("Error: cannot establish a connection using '%s':\n %s\n",
OUStringToOString(sConnectionString, RTL_TEXTENCODING_ASCII_US).getStr(),
OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US).getStr());
exit(1);
}
// gets the server component context as property of the office component factory // gets the server component context as property of the office component factory
Reference< XPropertySet > xPropSet( xInterface, UNO_QUERY ); Reference< XPropertySet > xPropSet( xInterface, UNO_QUERY );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment