Read Images from a different server
I need to read an image which is on a different server and place on my form. Can any one help me how this can be acomplished.
I have the url where all the images are residing. Though I hard code it in my form it gives me error that it cannot find the image.
Any ideas?
What is the code you are trying to use. If you tried READ_IMAGE_FILE then this doesn't work because it looks on the file system for images (see online help)
Frank
Similar Messages
-
Read File From A Different Server
Hello Friends,
We have a file (.txt) sitting in a server (not the application server) and there is a requirement to read data from this file into R/3. Manually, one needs a username and password to access this file as the server in which it resides is connected to a network. Now, what are my options? How can I do this? Please let me know!
Thanks,
SamIf the server has FTP capability, you could connect via FTP to get the file and place it on the application server. Another option is to have the folder in which the file resides NFS mounted to your app server, the the file is visible to your ABAP program and can be processed using OPEN/READ/CLOSE DATASET.
-
Getting images from a different server?
ok, I have a site, wich I cant upload anything onto, and I have a site I can upload stuff onto. On the site that I cant upload onto, I have a page with a java object on it. whos code follows:
<APPLET archive="DuriusWaterPic.jar" WIDTH="400" HEIGHT="100" ALIGN="MIDDLE" CODE="DuriusWaterPic.class">
<PARAM NAME="cabbase" VALUE="DuriusWaterPic.cab">
<PARAM NAME="dotsize" VALUE="7">
<PARAM NAME="image" VALUE="iben.jpg">
<PARAM NAME="dim" VALUE="6">
<PARAM NAME="noise" VALUE="0">
<PARAM NAME="mouse" VALUE="1">
<PARAM NAME="bg" VALUE="ffffff">
<PARAM NAME="reg" VALUE="43752326">
</APPLET>
Basically, its sercing on the free sites server for the files it needs, but they are all actually hosted at www.nimagineca.com/xanga/
so I replaced all of the address feilds with ie: "http://www.nimagineca.com/xanga/DuriusWaterPic.jar"
but that doesnt work...
so basically, how do I point these address areas to the correct server, obviously what Im doing is wrong...Applets can only access the host that they came from. So unless you can install the applet from the server where the images are, you're out of luck.
Well, actually one can change the security rules re: applets, so maybe the applet can access the host with the images. But I'd advise against this. It means that you'd have to make the users of the applet do extra work. -
Open Data Set Error while trying to read file from non SAP server
Hi all,
is it possible to read data from non-SAP application Sever?
I'm using OPEN DATASET p_filin FOR INPUT IN LEGACY TEXT MODE CODE PAGE '1504',
Where p_filin is other Windows server.Our applicition server is under Unix.Is it a problem?
I make test to read file from SAP application server and it was ok.So how to call other server?
Thanks!Hi,
Yes it is possible to read data from a non SAP server through the statement OPEN DATASET.
The important thing to check is that the SAP Server got enough access to the non SAP server so it can perform a reading/writing process depending on your needs.
You should contact your network administrator and BASIS to help you check the permissions. This can be pretty tricky, specially if the servers are in different domains.
Regards,
Gilberto Li -
Trying to use FTP to get data from a different server
Hi Friends,
I have to use FTP to get data from a different server and upload it on SAP server. Now my problem is when I m trying to do ftp through command line it brings the file but with no data.
Through ABAP program nothing is happening.
Here's my code--
V_PASSWORD = 'test@123'.
V_PWD_LEN = STRLEN( V_PASSWORD ).
CALL FUNCTION 'HTTP_SCRAMBLE'
EXPORTING
SOURCE = V_PASSWORD
SOURCELEN = V_PWD_LEN
KEY = CS_KEY_500098
IMPORTING
DESTINATION = V_PASSWORD.
CALL FUNCTION 'FTP_CONNECT'
EXPORTING
USER = 'test'
PASSWORD = V_PASSWORD
HOST = '176.0.1.6'
RFC_DESTINATION = 'SAPFTPA'
IMPORTING
HANDLE = MI_HANDLE
EXCEPTIONS
NOT_CONNECTED = 1
OTHERS = 2.
CHECK SY-SUBRC = 0.
cmd = 'lcd d:\ftp'. .
PERFORM FTP_COMMAND USING CMD.
CMD = 'asc'.
PERFORM FTP_COMMAND USING CMD.
CONCATENATE 'dir' 'ftpt*' INTO CMD SEPARATED BY SPACE.
PERFORM FTP_COMMAND USING CMD.
cmd = 'ls'.
concatenate 'ls' INTO CMD SEPARATED BY SPACE.
PERFORM FTP_COMMAND USING CMD.
cmd = 'mget trial.txt'.
CONCATENATE 'mget' 'trial.txt' INTO CMD SEPARATED BY SPACE.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
HANDLE = MI_HANDLE
COMMAND = CMD
TABLES
DATA = MTAB_DATA1
EXCEPTIONS
TCPIP_ERROR = 1
COMMAND_ERROR = 2
DATA_ERROR = 3
OTHERS = 4.
IF SY-SUBRC = 0.
LOOP AT MTAB_DATA1.
WRITE: / MTAB_DATA1.
ENDLOOP.
ELSE.
CONCATENATE 'Error in FTP Command while executing' CMD INTO ERROR SEPARATED BY SPACE.
WRITE: / ERROR.
ENDIF.Hi
try this.....in one of my reqt, i done this successfully....
FORM FTPCON.
FTP-------------------------------------------------------*
CLEAR DSTLEN.
SET EXTENDED CHECK OFF.
DSTLEN = STRLEN( S_PWD ). -
> (S_PWD (password) is a selection screen field )
CALL FUNCTION 'HTTP_SCRAMBLE'
EXPORTING
SOURCE = S_PWD
SOURCELEN = DSTLEN
KEY = KEY
IMPORTING
DESTINATION = S_PWD.
CALL FUNCTION 'FTP_CONNECT'
EXPORTING
USER = P_USER -
> Username
PASSWORD = S_PWD -
> password
HOST = P_HOST -
> Host
RFC_DESTINATION = P_DEST -
> Destination
IMPORTING
HANDLE = HDL
EXCEPTIONS
NOT_CONNECTED = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
HANDLE = HDL
COMMAND = 'set passive on'
TABLES
DATA = RESULT
EXCEPTIONS
TCPIP_ERROR = 1
COMMAND_ERROR = 2
DATA_ERROR = 3.
CALL FUNCTION 'FTP_R3_TO_SERVER'
EXPORTING
HANDLE = HDL
FNAME = G_FCNAME
CHARACTER_MODE = 'X'
TABLES
TEXT = T_FILE1
EXCEPTIONS
TCPIP_ERROR = 1
COMMAND_ERROR = 2
DATA_ERROR = 3
OTHERS = 4.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'FTP_R3_TO_SERVER'
EXPORTING
HANDLE = HDL
FNAME = G_FCNAME1
CHARACTER_MODE = 'X'
TABLES
TEXT = T_FILE2
EXCEPTIONS
TCPIP_ERROR = 1
COMMAND_ERROR = 2
DATA_ERROR = 3
OTHERS = 4.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'FTP_DISCONNECT'
EXPORTING
HANDLE = HDL.
CALL FUNCTION 'RFC_CONNECTION_CLOSE'
EXPORTING
DESTINATION = P_DEST
EXCEPTIONS
DESTINATION_NOT_OPEN = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " FTPCON
Hope it helps..... -
Stream-in images from client to server,without running the transmit code
Hello all,
Im using JMF for my current project.Right now,I am trying to only recieve images from the client without the client transmitting it.That is I dont want the transmit code to run on the client.
I should just be able to stream in the images from client to server, without running the transmit code on client.
Can this be done?
Thanks in advancesuppigs wrote:
Can I know more about this?Sure.
<Side A>
You'd just need to write an application that doesn't have a GUI (so, a console-based application) that listens on some pre-determined port for a message to start broadcasting. Maybe you'd send it the IP/PORT number to start broadcasting on. Once it receives that message, it'd start broadcasting the web cam to the IP/PORT number until it received a message to stop. Once it stops, it'll just go back to waiting for the next "start" signal.
<Side B>
On the other side, you'd write an application that sends the start messages, receives/displays the videos, and then sends the stop signal. This will have a GUI, and be your "control program" so to speak.
Then, once of have both of those programs working...if you're using Linux, you're done. If you're using Windows, you'd need to modify the <Side A> program so that it can run as a Windows service.
There are a lot of ways to do this, you can google it or look at the following link:
[http://twit88.com/blog/2007/09/19/open-source-software-to-start-up-java-as-windows-serviceunix-daemon/] -
Accessing an object from a different server
Hi,
I am making a program that will access an object from a different server.
I have a program that when I run calls a jsp page running on Server A which in turn should request an object A from Server B.
I am relatively new to Java and jsp. What would my best course of action be.
Thanks in advance,
BrianOr RMI?OK, sounds good, I will look up some RMi on the site.
Thanks, will prob have more questions for you later. -
Reading Data From a Different Planning Package in a Exit Function
Hi,
Is it possible to read data from a planning level / package other than the package that the exit function was executed with? I want to read data into an internal table from another package and use that data in combination with the data in the current package to create new records. If this is possible sample code for how to read data from a different package would be appreciated.
Thanks!
Mel WaldnerHi,
As an example lets say you have restricted 0calmonth in your package to 6.2007. In the planning layout to fetch values for 5.2007 (read only), you can take 0calmonth in data columns, and for this column restrict it as 5.2007.
Similarly in Planning functions, you can mark 0calmonth as field to be changed and fetch data for 5.2007.
Hope this helps. -
JAVA, sqlserver - Need to load an image from the sql server database
hi,
I need to load an image from the sql server database using java. I have connected to the database and getting all other records except the records for a photo (datatype = LONGVARBINARY) and Remarks (datatype = LONGVARCHAR).
I am using java and sql server db. The photo and remarks are stored in the db. and i need to show the image and the remarks fetching them from there.
I get the error :
Thread-9 org.hibernate.MappingException: No Dialect mapping for JDBC type: -1
How can I achieve this?
Thanks,
GargiExactly. And are you using MySQL?
No. You are using Microsoft SQL server if I have to believe your initial post. A quick google tells me that the dialect class to use is:
org.hibernate.dialect.SQLServerDialect -
i want to interact with hardware(scanner) in java
i want to read image and store in database
for this
1.) i want to read image from scanner
2.) how do i start scanner process
from where i gonna start
plz help me to interact with hardwareHi, I have faced a similar problem and solved it using the morena api http://www.gnome.eu/Twain/examples/studio.html
Problem is the scanner works fine with TWAIN, but with SANE, it is totally failing. There is a permanent connection refusal form the scanner ip whenever
i try to use a network scanner. I am not sure how to solve it. If anyone has solved this please revert back.
Regards,
Anthony -
Read image from excelsheet using labview
i need to know how to read image from excel sheet using Labview...m not able to get the appropriate property to display the image stored in excel sheet.
thank youyou need to ask Microsoft to find out the property name/location under Microsoft Excel.
-
Hi,
I am having a very difficult time being able to read images from a JAR file via my Applet. I have tried everything that I know about with no luck. The only way I can get this to work is to store the images individually in a sub directory of public_html on the websever. This works, but I would like the images to come down in a JAR file for performance reasons.
I am using Internet Explorer 5.5 for my browser. I checked the options and everything seems to be in order, but......
I would appreciate any feedback that anyone might have on this topic..........
Thank You....once in a jar file i inserted a image
the jar file on clicking starts an frame.
so the image was for getting that image at the icon place at top and at minimized window
i could not get that image from jar file by new imageicon().getimage();
but i get the image if it is in the directory in which jar file is.....
can one explain the reason -
Hi everyone,
How can I read images from R3?
Regards
Eduardo Camposyou need to ask Microsoft to find out the property name/location under Microsoft Excel.
-
Taking rman backup from a different server
HI Al,
Is it possible for us run the rman backup from a different server other than the server on which database exist .
For Ex :
Our database is on server X
But , I want to schedulde the archive backup from the server Y .
How can we do this and is it possible ...
Regds
Rahul GuptaYes, as long the RMAN executable is compatible to the target database, on metalink:
RMAN Compatibility Matrix
Doc ID: 73431.1
rman sys/<password>@<connect_string>
Werner -
I am facing a Problem with reading images from database
Hi everybody..
any help will be most appreciated, I am facing problem with reading images from database. I am pasting my code...
string connect = "datasource = localhost; port = 3306; username = root; password = ;";
MySqlConnection conn = new MySqlConnection(connect); // creating connecting string
MySqlCommand sda = new MySqlCommand(@"select * from management.add_products ", conn); //creating query
MySqlDataReader reader;
try
conn.Open(); // Opening Connection
reader = sda.ExecuteReader(); // Executing my Query..
while (reader.Read())
byte[] imgg = (byte[])(reader["Picture"]);
if (imgg == null)
pc1.Image = null;
else
MemoryStream mstream = new MemoryStream(imgg);
pc1.Image = System.Drawing.Image.FromStream(mstream);
It says Parameter not Valid... i am reading all the images from databaseI agree with Viorel. You are getting the error because the format of the data is incorrect probably because the data was modify. It may not be the reading of the database the is incorrect, but the application that wrote the data into the database. You need
to compare the imgg array data with the data before it was written to the database to see if the data matches. I usually start by comparing the number of bytes which is easier to check then compare the actual to isolate which function is changing the
byte count.
An image is binary data. The standard VS methods for reading and writing data (usually stream classes) default to ASCII encoding which will corrupt binary data. The solution usually is to use UTF8 encoding instead of the default ascii encoding.
Ascii encoding with stream often aligns the data and adds extra null bytes to the end of the data which can produce these type errors.
jdweng
Maybe you are looking for
-
Prompting for UserName and Password when I click Report Server Web Service URLs in ssrs 2008 R2
Hi All, I am using SQL Server Reporting services 2008 R2 . When I tried to open report server webservice URL in SSRS 2008 R2 It is prompting username and password. I tried to resolve the issue by deleting the <!-- <RSWindowsNegotiate/> -
-
I recently installed vista to my mac (32bit). My headphones are not working on it. I could not find the "3.5mm jack" that apple suggests to "solve" this issue. And I have tried installing/uninstalling audio drivers. Can anyone help?
-
'No further confirmations expected ' in a PO
We have a service PO and when i click on 'No further confirmations expected' for a line items and order the PO. The check box of 'No further confirmations expected' is reset to blank.Please advise .
-
Why does my itunes has an error reported everytime when i get ready to sync my stuff?
everytime i plug my phone up to itunes, and get ready to sync stuff to my phone...my computer finds an error in itunes .. what do i do ?
-
CS5 can't read Canon G-15 raw files - is there any fix for that?
CS5 can't read Canon G-15 raw files - is there any fix for that?