WebQuery türü Dış Veri Bağlantısı ile çalışma

WebQuery türü Dış Veri Bağlantısı ile çalışma

Aşağıdaki kod, harici veri bağlantısı türüyle nasıl çalışılacağını gösterir.Web sorgusu . Bu kullanırörnek excel dosyası verilen bağlantıdan indirebilirsiniz. Aşağıda bu kodun konsol çıktısını da görebilirsiniz.

// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-Java
// The path to the documents directory.
String dataDir = Utils.getDataDir(WorkingWithExternalDataConnection.class);
Workbook workbook = new Workbook(dataDir + "WebQuerySample.xlsx");
ExternalConnection connection = workbook.getDataConnections().get(0);
if (connection instanceof WebQueryConnection)
{
WebQueryConnection webQuery = (WebQueryConnection)connection;
System.out.println("Web Query URL: " + webQuery.getUrl());
}

Konsol Çıkışı

İşte bununla yukarıdaki kodun konsol çıktısıörnek excel dosyası.

 Web Query URL: http://www.aspose.com/docs/display/cellsnet/Home