cancel
Showing results for 
Search instead for 
Did you mean: 

How to search the KM Resource file by using these input fields( like as file resource Name, File Description, Created By, Modified by, Created By Date and Modified By Date)

vijay_kumar49
Active Contributor
0 Kudos

Hello

How to search the KM Resource files by using these input fields( like as file resource Name, File Description, Created By, Modified by, Created By Date and Modified By Date) in Webdynpro JAVA Application

How to get the File Resource Size and Document Relevance(%) By  in Webdynpro JAVA Application

I need to display table in  File Resource Size and Document Relevance(%) by using Webdynpro JAVA Application

I’m using EP 7.0 version,

Could you please help me.

Regards

Vijay Kalluri

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Vijay,

FYI

Thanks,

Patralekha

vijay_kumar49
Active Contributor
0 Kudos

Hello friends,

When I ever I search the data by using Created By, Modified by, Created By Date and Modified By Date

It will throws some  exception and data is not displayed. Please check attached issue.doc. file

Regards

Vijay Kalluri

vijay_kumar49
Active Contributor
0 Kudos

Hello friends,

By using FileName and File discription i will search the data from KM.

How to Search the KM resource files from the KM Repository by using these input fileds (Search by CreatedBy, ModifiedBy, CreatedDate and Modified Date)

I used attached Code for search.

When ever i will search the data from (CreatedBy, ModifiedBy, CreatedDate and Modified Date) i will get " IMSRC_MISSARG;location=frvs447a:30203 (Errorcode 2988)" Exception

Is it possible to search the data form KM Repository by usng these input fileds (CreatedBy, ModifiedBy, CreatedDate and Modified Date) in WDJ

vijay_kumar49
Active Contributor
0 Kudos

How to get the File Resource Size and Document Relevance(%) By  in Webdynpro JAVA Application

Document Relevance(%)

ISearchResult result = iter.next();  

IResource resource = result.getResource();

float rankValue = result.getRankValue();

float docRelevance = rankValue*100; 

int documentRelevance1 = (int)docRelevance;

String perSymbol= "%";

String  documentRelevance = String.valueOf(documentRelevance1)+perSymbol; 

srcResults.setDocumentRelevance(documentRelevance);

File Resource Size

String fileSize = "0";
try{
// for .html file Size
if(resource.getContent().getContentLength() == -1){
double d1 = 0.0;
d1 = resource.getContent().getInputStream().available();
fileSize = this.getFileSize(d1);
srcResults.setFileSize(fileSize);
}else{
// .jpg, txt, etc .... file Size
fileSize = this.getFileSize(resource.getContent().getContentLength());
srcResults.setFileSize(fileSize);
}
}
catch(Exception ex){
wdComponentAPI.getMessageManager().reportException(ex.getMessage(), false);   
}

this.getFileSize () methods returns the KB, MB and GB...

Please tell me, how to search on KM resource files by using CreatedBy and Modified by usernames.

Regards

Vijay Kalluri

Answers (0)