|
All controls can contain other controls, but I assume you want design time support like the panel has. Do do that add this line of code just before the class declaration.
<Designer("System.Windows.Forms.Design.ParentControlDesigner,System.Design", GetType(IDesigner))> _
|
|
|
|
|
You can also use inherits system.windows.controls.panel .
|
|
|
|
|
Hi,
Username and password in SqlServer 2005, I want to check the user name and password from the database. How to check that? Give me any sample code for that..
Thanks in advance
With Regards
A.Muthunagai
|
|
|
|
|
Are you checking username/password of an account on SQL Server 2005 or do you have a user table? Please elaborate a bit more what you are looking to do...
"I've seen more information on a frickin' sticky note!" - Dave Kreskowiak
|
|
|
|
|
My email address is honest.siulapwa@gmail.com or honest@micropos.co.zm I am the one asked about the crystalreportviewer nor working. I will greatly appreciate your help.
|
|
|
|
|
Does this relate to a prior post ? Did you want to see how much spam you could get by broadcasting your email address to the world ? What is the point of this post ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Sorry i never thought of it that way, but i need help with the crystalreportviewer and this guy was willing to upload some working code of the control.
|
|
|
|
|
So, respond on the thread, send him an email through the site if he needs your email address. Then he will be sure to get it. Who knows if he even happens to be reading the site when you post this ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
never mind iam gonna help u
but excuse me i was busy these days
gonna send u mail and let me know if it helps
|
|
|
|
|
Hi all:
I want to execute .exe(process) when some events is fired from my application. I was able to execute my process by using my following code.
Dim program As New Process<br />
program.StartInfo.FileName = "SH_EVP2.exe"<br />
program.Start()
My Problem is I need to pass filename as paramters to .exe (process)when I execute it. can you advise me how shall I do this?
|
|
|
|
|
Process.Start("SH_EVP2.exe " + yourParamString)
will do it.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hey:
I did the exactly same that you have provided above. Unfortunately, I got some execptional handling error. Then, later I tried:
Process.Start("SH_EVP2.exe ", "input1.sa")
But still it is not taking input1.sa as a file parameter.
Help please.
|
|
|
|
|
hsprasain wrote: Unfortunately, I got some execptional handling error.
Christian's code should do the trick, what is the exception you were getting?
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
The exact code that I wrote as per Christian's suggestion is:
Dim yourParamString As String = "input1.sa"<br />
Process.Start("SH_EVP2.exe" + yourParamString)
The exception that I got while executing the application is:
The system can't find the file specified.
However I have input1.sa in the bin directory. I felt "SH_EVP2.exe" + yourParamString string got concanated and come up with new file name. Thus I'try the other one that I've posted above.
Thanks for your help
|
|
|
|
|
You might have to specify the file path to the parameter file as well...
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
By default it is taking taking the filpath of ../bin and my input file is inside bin. However, I tried with absolute path too. It doesn't make any differnce.
|
|
|
|
|
hsprasain wrote: Dim yourParamString As String = "input1.sa"
Process.Start("SH_EVP2.exe" + yourParamString)
You might be needing a space between the .exe and input1.sa
By the looks of your code, it is looking for: SH_EVP2.exeinput1.sa
Have you tried: Process.Start("SH_EVP2.exe " + yourParamString) , note the space between the last 'e' in exe and the last double quote...
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
Hey:
I tried as per your suggestions but it doesn't work out. Same error. I'm getting really frustrated.
|
|
|
|
|
hsprasain wrote: The system can't find the file specified.
Of course not, you're trying to start SH_EVP2.exeinput1.sa, which does not exist.
hsprasain wrote: I felt "SH_EVP2.exe" + yourParamString string got concanated and come up with new file name.
Yeah, I thought it was obvious you needed a space.
hsprasain wrote: However I have input1.sa in the bin directory.
Doesn't really matter. sh_evp2.exe needs to be in the same folder, or in the general lookup path for windows. Additionally, where-ever sh_evp2.exe is, *it* needs to be able to find input1.sa, that is, even if sh_Evp2.exe starts from anotehr folder, odds are very low it will be able to find input1.sa. Application.ExecutablePath ( from memory ) contains the path to your exe, use Path.Combine to create the full path to input1.sa, make sure that sh_evp2.exe is able to be found, put in a space, and it should work.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi All,
I Want the Week Number of the Date Selected in MonthCalendar.
Can anybody plz forward me the codings in VB.Net.
Thanks & Best Regards,
Noor.
Noor
|
|
|
|
|
When you use Datetimepicker then use the property value and day of year it will show you the day then divide it by 7 you will got the week of year.
the code is : -
<br />
weekofyear=(Datatimepicker1.value.dayofyear)/7<br />
msgbox(weekofyear)<br />
If you uses C# then use toString for converstion.
With regards
Yogesh Agarwal
|
|
|
|
|
Yogesh Agarwal wrote: use the property value and day of year it will show you the day then divide it by 7 you will got the week of year
That only works for years where january the first is the first day of the week.
---
single minded; short sighted; long gone;
|
|
|
|
|
|
How can we enumerate and print through Network Printers?
Any link or code.
Help appreciated both ion VB.Net or C#.
Thank You!
X
|
|
|
|
|
You can use the EnumPrinters API
(Declaration)
<DllImport("winspool.drv", EntryPoint:="EnumPrinters", _
SetLastError:=True, CharSet:=CharSet.Ansi, _
ExactSpelling:=False, _
CallingConvention:=CallingConvention.StdCall)> _
Public Function EnumPrinters(<InAttribute()> ByVal Flags As EnumPrinterFlags, _
<InAttribute()> ByVal Name As String, _
<InAttribute()> ByVal Level As Int32, _
<OutAttribute()> ByVal lpBuf As IntPtr, _
<InAttribute()> ByVal cbBuf As Int32, _
<OutAttribute()> ByRef pcbNeeded As Int32, _
<OutAttribute()> ByRef pcbReturned As Int32) As Boolean
End Function
passing in the appropriate EnumPrinterFlags from:
<Flags()> _
Public Enum EnumPrinterFlags
PRINTER_ENUM_DEFAULT = &H1
PRINTER_ENUM_LOCAL = &H2
PRINTER_ENUM_CONNECTIONS = &H4
PRINTER_ENUM_FAVORITE = &H4
PRINTER_ENUM_NAME = &H8
PRINTER_ENUM_
PRINTER_ENUM_SHARED = &H20
PRINTER_ENUM_NETWORK = &H40
End Enum
|
|
|
|