|
You asked this question just below. Don't repost.
|
|
|
|
|
Hello,
I use this method to encode in base 64 :
[WebMethod]
public string EncodeFileTo64Digits(string File_Path_input)
{
string base64;
using (FileStream fs = new FileStream(File_Path_input, FileMode.Open, FileAccess.Read))
{
string ext;
byte[] data = new byte[fs.Length];
fs.Read(data, 0, data.Length);
base64 = Convert.ToBase64String(data);
ext = base64;
return ext;
}
}
Thank you verry mutch for hlep me to resolve this great problem.
|
|
|
|
|
You seem to be intent in persisting in this behaviour. Instead of adding this snippet here, you should amend the question below because that contains the original question, along with answers that have already been given. I will say that if your intent is to download the file, you should return a byte[] and not an encoded string.
|
|
|
|
|
Hello,
I am sorry, but i must return the encoded base 64 file, i consume my web service like this :
ServiceReference2.TEST_ServicesSoapClient ff = new encode_consommation.ServiceReference2.TEST_ServicesSoapClient();
string rr = ff.transformPDF("fqrgfqfsgfdsgfg.....");
I checked the all execution step, so they stops at the return of my string.
Thank you verry mutch.
modified on Monday, December 27, 2010 4:37 AM
|
|
|
|
|
You still haven't learned: no-one is going to answer a question here as yip have re-posted. Edit your original question (which, BTW, missed all the vital information you have posted since).
|
|
|
|
|
I have popcorn, and I'm watching with great interest...
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass." - Dale Earnhardt, 1997
|
|
|
|
|
I guess it wouldn't be worth to answer him in the right thread... He does not read the answers...
|
|
|
|
|
Hello,
I test my web service with soapUI, my methos return the correct encode base 64.
I call the web service correctly ?
|
|
|
|
|
5'd, if only to keep you in the same rep zone as JSOP !
|
|
|
|
|
Thanks Keith. Surprisingly enough, I'm not actually in competition with JSOP. He's written far more articles than me so his position would be difficult to assail - what I do want though, is for JSOP and me to be able to beat CG on combined post counts.
|
|
|
|
|
I don't think that will ever happen. CG has far too many hardware and software problems and disputes with Qantas, Telstra, and TicketMaster to complain about, and every couple of weeks, his post count goes up by 1000 or so while he describes his latest travails...
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass." - Dale Earnhardt, 1997
|
|
|
|
|
John Simmons / outlaw programmer wrote: I don't think that will ever happen.
No john, surely your Tag team can beat CG as Pete said. I wish CG will get good things & good net connection soon quickly.
|
|
|
|
|
This is true. It's a worthy goal though, and some people want me to post follow up articles on jQuery, so I might be able to push my article count up that way. That should help us beat CG.
|
|
|
|
|
I read somewhere (lounge IIRC) that 1O'H+ 1JSOP currently has an exhange rate of 1G.
|
|
|
|
|
Hello,
I have an exception on my web service, the error show that we must modify the value of "XmlDictionaryReaderQuotas" How i can modify the value of "XmlDictionaryReaderQuotas"? whene i can find the file whitch contain "XmlDictionaryReaderQuotas"?
Thank you verry mutch
|
|
|
|
|
A quick google gave loads of hits, most of which, including this[^] one, indicate that the problem lies in your .config file.
BTW: I googled on XmlDictionaryReaderQuotas
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
For WCF services you can configure it in your service binding configuration:
<bindings>
<wsHttpBinding>
<binding name="....">
...
<readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647"
...
</binding>
</wsHttpBinding>
</bindings>
|
|
|
|
|
Hello,
whene i can fin the service binding configuration ? can you give me the path of file witch contain this ?
Thank you verry mutch.
|
|
|
|
|
It is probably in the WCF's web.config file, depending on how you have set things up.
|
|
|
|
|
Hello,
I dont have "XmlDictionaryReaderQuotas" in web.config of my project (web service).
Thank you verry mutch.
modified on Sunday, December 26, 2010 1:25 PM
|
|
|
|
|
is your service a wcf service or do you have asmx files?
|
|
|
|
|
i have asmx files.
Thank you verry mutch.
|
|
|
|
|
I can only find answers for WCF services, and it's been so long since I've touched plain SOAP services that I can't really help. Sorry.
|
|
|
|
|
Hello,
My web service modify the PDF File, in the input parameters i set the encoding base 64 of my original PDF but there are the excpetion when i try to get the encoding base 64 of my pdf modified.
What is the difference between the asmx et wcf ?
Thank you verry mutch.
modified on Sunday, December 26, 2010 2:11 PM
|
|
|
|
|
Hello,
I test my web service with soapUI, my methos return the correct encode base 64.
I call the web service correctly ?
Thank you verry mutch.
|
|
|
|