|
Do you need the Not in If Not ObjRead.Read Then ?
If you are only wanting to get one value you could use objComm.ExecuteScalar() instead.
|
|
|
|
|
I'm sorry,I forgot to remove the not while testing it. Actually I want to check if the row exist in the database,then it will do something. But eventhough it exited this row but it doesn't run. Can anyone give me a solution how to check the tinytext content in MySQL database column? Am I used the right way?
Thank you~!
|
|
|
|
|
You can still do ExecuteScalar(). If no matching row is found nothing will be returned.
You might want to consider using the MySQL .Net Connector[^]. It has MySqlDbType.TinyText as a database type.
|
|
|
|
|
I am writing an email program, which will send mails to a number of email addresses in one go. But at the same time i want to save all the outgoing messages in my outlook express sent items folder. I am able to send mails in a loop but don't know how to save them in the Outlook Express Sent Items folder.
Is there any way to achieve the above functionality. Any code added will greatly help. I am using VB.Net 2005.
Thanks in advance.
Sekhar
|
|
|
|
|
As far as I know, this can be done through IMAP only.
Since, .NET inherently does not support IMAP so you might have to search for a third party tool to achieve the desired scenario.
Best Regards,
Sam Xavier
www.componentone.com
|
|
|
|
|
I'm having trouble keeping my forms looking the same, or at least similar, across different computers (different versions of Windows; different monitor displays, etc.) Would someone be willing to point me in the right direction to solve this problem?
Thanks
|
|
|
|
|
What exactly do you mean? If you're talking about the window "chrome" (title bar, maximize, minimize, restore buttons, toolbar colors, etc.) there isn't much you will be able to do about it with out a lot of work.
Toolbars (and menu bars, etc. -- basically anything that derives from ToolStrip) isn't bad depending on what you want to do, but requires creating your own ToolStrip Renderer class. For the rest of the window chrome you will need to hook various Windows messages (WM_xxx messages) to control painting the various client and non-client areas of the window. It's possible, but certainly not trivial.
Scott.
—In just two days, tomorrow will be yesterday.
—Hey, hey, hey. Don't be mean. We don't have to be mean because, remember, no matter where you go, there you are. - Buckaroo Banzai
[ Forum Guidelines] [ Articles] [ Blog]
|
|
|
|
|
OK, sorry, I wasn't very clear. What I would like to do is to keep the button, textbox, and combobox controls in the same relative position to each other regardless of the exact size of the form as drawn in different instances of the program on different OS and display sizes. See for instance:
http://www.cstrader.com/Format.jpg[^]
Thanks
|
|
|
|
|
Ok...that clarifies things. The best way to achieve this is going to be through the use of panels and setting the Dock and/or Anchor properties of the panels and controls in those panels. Unfortunately there is no "magic formula" for how to set these properties, you will need to expirement until you get it right.
Scott.
—In just two days, tomorrow will be yesterday.
—Hey, hey, hey. Don't be mean. We don't have to be mean because, remember, no matter where you go, there you are. - Buckaroo Banzai
[ Forum Guidelines] [ Articles] [ Blog]
|
|
|
|
|
What about dealing with variations in text size on different machines? In vb, controls were dimensioned in TWIPs, which were an annoying unit, but had the advantage that control sizes would scale proportional to font sizes. VB.net uses pixels to define control dimensions and placement. Unfortunately, if two systems use different numbers of pixels to display size-10 text, then text which fits in a button on one system may not fit in another.
|
|
|
|
|
.NET does use pixels, but all of the controls are based on a common font and point-size. That being said, there will be issues related to this particularly on machines with differnt DPI settings. You can change the AutoScaleMode property on the form, which will have some affect, but if you really want an application that will scale properly on any system/font/DPI you need to look at WPF.
Scott.
—In just two days, tomorrow will be yesterday.
—Hey, hey, hey. Don't be mean. We don't have to be mean because, remember, no matter where you go, there you are. - Buckaroo Banzai
[ Forum Guidelines] [ Articles] [ Blog]
|
|
|
|
|
Use the Anchor and Dock properties to set your form up so it resizes itself nicely for different resolutions.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi all,
I am using Name "xxx" As "zzz" to rename a file in vb6.My question is how can i rename a file in %systemroot%\inf folder ?What i mean is how to write the path string?
And other question is , is Name can be use for hidden file?If no, can you please suggest a way to rename hidde file?Thanks.
any tips are welcome
regards
cocoonwls
|
|
|
|
|
|
Hi The JZ,
Thanks! I got it
regards
cocoonwls
|
|
|
|
|
Hi i have developed an application in vb.net
i am creating directories at runtime in c:\programfiles\
it is possible in Windows XP.
But in vista, it is creating a problem.
it is not creating a directory.
i think it is problem of permissions.
does any one knows how to set permissions to a folder in Vista
to create directory and file under that folder.
|
|
|
|
|
The user will have to right click the program and select "Run as Administrator", or your application manifest file will have to request Administrator Privileges at runtime. This is also assuming that the account that the user is running the application from has Administrator privileges. Both of the above options will also pop up the ugly UAC dialog boxes.
All in all, I would suggest you find a way to program your application without it needing Administrator privileges.
I hope this helps.
|
|
|
|
|
Thanks Mitch
I have managed the code and now its running correctly
|
|
|
|
|
|
|
Hello all, I'm trying to develop an application to read your emails using a pop3 address, but if the mail provider is, for example, gmail, it will need to connect using SSL, right? But I really don't know how to do that... I'm so lost... Any help?
|
|
|
|
|
|
Well, that component is not free... I was looking for a way to connect to a SSL server using sockets...
|
|
|
|
|
i have looked in my books, I have looked online, I have looked in code Project. Why can't I find this simple answer to my question. I must not be working it correctly on the search engines. Maybe someone here can help me.
Here is goes. This should be a no brainer.
I want to write to a file. I want to put a literal " in the string. How do I do that in Vb .net?
I tried """ with no luck.
So, does anyone know this answer that I should probably be able to recite in my sleep.
|
|
|
|
|
try adding an extra ":
stream.write("""")
will write "
and
stream.write("""Hello""")
will write "Hello"
|
|
|
|