|
You'll have to write a VB.NET wrapper around the function you want to use from the Web Service. This wrapper should expose all of its functions to COM. You can see an example of the technique here[^] on MSDN. It doesn't deal with consuming Web Services from VB6 specifically, but it does show the technique you'll need to wrap the method calls in something usable to COM applications.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi!
I have a web service that returns an order-object to the user. The object consists of price, orderID and an array of products. When I try to run the service, I get an error message telling me that I must "implement a defult accessor on System.Array because it inherits from ICollection". Anyone here who knows how to send an array in an object? or what I have to do to overcome this errormessage? Also -> is it better to use array or arraylist when doing this?
cheers Ole!
|
|
|
|
|
Hi there.I want to have a larger form than the original form.
Actually, i have a lot of pictures(1000 pictures),option button,
and i need to fit them all in my form.
Can i have form that has it own vertical scrolling bar?so that i can
just scroll to put more pictures.Plz somebody help me...
|
|
|
|
|
check the form property. select scrolling property to ture.
|
|
|
|
|
What abhi2008 said is correct principally.
But you shouldnt place too many controls onto one single form. Placing 1000 PictureBoxes onto one form will surely create some performance issues. What are you trying to achieve? Probably there is a better way to do it.
|
|
|
|
|
i've encountered some errors using parameters on my data adapter
i.e.
SELECT studno, studlastname, studfirstname, studmiddlename FROM students WHERE(studno = ?)
where the question mark will be the handler for the yet unknown student number that will be entered on runtime, thus will search for a specific row on the table
and the following error occurs
"the parameter ?_1 is unknown" or something like it i can't remember the exact words of the error message coz i'm away from my home computer.
needed immediate help thanks
|
|
|
|
|
Assuming you're using a database, you should use a stored procedure. If you're stuck with something that takes SQL and does not allow stored procedures, then shouldn't you do something like this:
string.Format("SELECT studno, studlastname, studfirstname, studmiddlename FROM students WHERE(studno = {0}", nStudNo)
to build your SQL ? Or have I missed something here ?
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
i'm sorry i forgot to mention that i use access database so it's oledb provider i'm using, also i am configuring the parameters in the data adapter configuration wizard. will it work if i code it in the program.
|
|
|
|
|
Assuming that Access does not support stored procs ( I believe the latest version might ), then I'd simulate stored procedures by creating one class whose job it is to handle database code, so you still get that level of abstraction. Then if I *had* to generate SQL in my code, I'd do something like I suggested to build the query using a supplied parameter before passing the SQL string to Access.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
thanks christian i'll try what you suggested
|
|
|
|
|
Christian Graus wrote:
string.Format("SELECT studno, studlastname, studfirstname, studmiddlename FROM students WHERE(studno = {0}", nStudNo)
Christian, I expected better of you! You might want to ready my article on SQL Injection Attacks and Tips on How to Prevent Them[^]
Access does support parameterised queries, if not Stored Procedures.
[EDIT]
Actually, given that nStudNo is most likely an integer type then it is unlikely to be a viable target for an injection attack - but getting into the habit not inserting values like this means just not having to second guess what is going to open up a security hole and what is not.
[/EDIT]
My: Blog | Photos | Next SQL Presentation
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and More
|
|
|
|
|
Colin Angus Mackay wrote:
Actually, given that nStudNo is most likely an integer type then it is unlikely to be a viable target for an injection attack
Yeah, I was coming back to make that point You're right though, I should have pointed out that such an approach is open to injection attacks generally, even though mentally I noted it didn't matter in this case. Certainly, any string that gets passed into SQL in my code would first be cleansed to protect against such an attack.
Colin Angus Mackay wrote:
Access does support parameterised queries, if not Stored Procedures.
That must be what he was trying to call, I have no idea about access, I think it's crap.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
<id>4054
<r>255
<g>249
232
this is my XML file.so i need to add some data like
R=45
G=69
B=123
to this XML File through vb.net
how can i do this task.
suis
|
|
|
|
|
LOL - I take it the tags are <R> <G> and <B>, given that you didn't check 'Do not treat <'s as HTML tags' and so they were turned into HTML.
Why are you turning an image into a HTML file ?
The web abounds with examples on how to do this, you really should look for yourself before asking.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
<id>4054
<r>255
<g>249
232
this is my XML file.so i need to add some data like
R=45
G=69
B=123
to this XML File through vb.net
how can i do this task.
suis
|
|
|
|
|
I'm porting a VC++ (6.0) function i wrote into VB - VBA code in my MS Access database.
My question is how can i preserve the precision of variables in VB? (I'm not very familiar with VB and the differences in types between VB and VC++).
Example:
#define MY_PI (3.1415926535897932384626433832795)<br />
#define MY_2PI (MY_PI*2.0)<br />
#define MY_DEG_TO_RADS (MY_PI / 180.0)<br />
#define MY_RADS_TO_DEG (180.0 / MY_PI)
then when I do similiar in VB
'VB - VBA code<br />
Public Const VB_PI As Double = (3.1415926535897932384626433832795)<br />
... it get shortend automatically to
<br />
Public Const VB_PI As Double = (3.1415926535897)<br />
For now, I'm only concerned with converting between Degrees <-> Radians, but the difference in precision is still a concern.
Thanks,
Johnny
|
|
|
|
|
Use Decimal instead of Double
// TODO: Write code.
|
|
|
|
|
You didn't get that kind of precision in C++. The C++ Reference says that only 15 digits of signifigance are maintained around the decimal point, using a 1-bit sign, 11-bit exponent, and a 52-bit mantissa. So in effect, your statements are identical. VC6 just didn't go back and drop the numbers that weren't being used.
The Double type in VBA is the same as the Double type in C++.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Thanks all for the info/help. I needed some verification on this from the experts.
Johnny
|
|
|
|
|
i m doing an ASP.NET Web Application...i would like to know how to use regular expressions for validating phone no, email id, date...etc..
please give an example
|
|
|
|
|
|
Hi,
I want to copy from .txt/.doc to clipboard .
How can i do this?.
Plz help me.
Thanks in advance,
Nisha
|
|
|
|
|
Hi,
Any thing has been avail in MSDN website. Goto there!!!
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon98/html/vbconcuttingcopyingpasting.asp
bye by
Somasundar R
|
|
|
|
|
just anybody know that how to store a .GIF images to a ms access database ?
suis
|
|
|
|
|
You can serialise an image in any format ( jpg, raw, gif, etc ), and get it as a stream of bytes. You can get that stream from your DB and use it to rebuild the GIF.
Christian Graus - Microsoft MVP - C++
|
|
|
|