|
Set the opacity in a loop, calling Invalidate and Application.DoEvents so they get shown, then close the form.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
im using vb..
The name is Sandeep
|
|
|
|
|
If you're using VB6, you need to say so. If you're using VB.NET, then do what I said.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
I cant do what u said.. coz i am using VB..
The name is Sandeep
|
|
|
|
|
|
VB 6..
The name is Sandeep
|
|
|
|
|
In VB.NET this would have been easy. In VB6, I don't think you can do it because VB6 creates its forms differently, without support for Layered Windows, which is required to support opacity.
|
|
|
|
|
OK, I can only assume when you say VB, you mean VB6. VB6 is a dead language, and it sucked to start with. If you have any choice, move to VB.NET. Otherwise, tell people you're using VB6 when you ask questions here.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 Graus,
You said VB6 is a dead language. But nobody have a little experience in working with VB should'nt say like that. They would say it as the most flexible language. We can write a complex coding in other language in a very simple way in VB.
By Dileeeeeeeep.
|
|
|
|
|
It's dead. MS stopped supporting it entirely.
It's been replaced, thankfully, with VB.NET. Finally! Real OOP support!
|
|
|
|
|
1 - it's dead in that it is no longer supported and will not be subject to any updates or service packs
2 - actually, the way this works in VB6 is usually that you write 2 lines of code that call a C++ COM object to do the complex stuff that VB cannot do.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 Xandip,
I hope the code is useful...
Here is the API declaration :
Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" _<br />
(ByVal hwnd As Long, ByVal nIndex As Long) As Long<br />
Private Declare Function SetLayeredWindowAttributes Lib "user32" _<br />
(ByVal hwnd As Long, ByVal crey As Byte, ByVal bAlpha As Byte, ByVal dwFlags As Long) As Long<br />
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" _<br />
(ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long<br />
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)<br />
<br />
Private Const GWL_EXSTYLE = (-20)<br />
Private Const LWA_ALPHA = &H2&<br />
Private Const WS_EX_LAYERED = &H80000
Here is the code where you should use :
Private Sub Command2_Click()<br />
Dim fadeCtr As Integer<br />
Call SetWindowLong(Me.hwnd, GWL_EXSTYLE, GetWindowLong(Me.hwnd, GWL_EXSTYLE) Or WS_EX_LAYERED)<br />
For fadeCtr = 255 To 0 Step -1<br />
Call SetLayeredWindowAttributes(Me.hwnd, 0, fadeCtr, LWA_ALPHA)<br />
DoEvents<br />
Call Sleep(5)<br />
Next<br />
End<br />
End Sub
Please dont use this code in Unload event of form - as you observe, I had used DoEvents in the above function. If this is useful, reply me to answer again.
|
|
|
|
|
Hi
This is my first time to use like this site
I need help in VB coding
I wont to know how I can create a VB program that read a data from a SQL database and then create and insert this data in a text file.
Regards,
jenans
|
|
|
|
|
hi..
in which part do u need help?? taking data from the tables..?? or createing and inserting the data into the textfile??
The name is Sandeep
|
|
|
|
|
Hi
for the data i will use SQL command but i wont to know how i can create and insert into the text file useing what i select in the SQL command
thank you
jenans
|
|
|
|
|
Which bits have you done before ? What code have you written before ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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,
i am having a problem in viewing CR report using vb.net
I have a button and having this code
Dim ReportForm As New frmCrystalReportForm
Dim TableName(0) As String
Dim QueryString(0) As String
TableName(0) = "Strength"
QueryString(0) = "SELECT * FROM Strength"
ReportForm.MdiParent = frmMain
ReportForm.ViewReport("TEST.rpt", TableName, QueryString, "UnRegister")
ReportForm.Show()
on other form i have this
For I As Integer = 0 To UBound(TableName)
Adapter = l_objDBManager.GetDataAdeptor(QueryString(I))
Adapter.Fill(DataSet, TableName(I))
Next
Report.Load(Application.StartupPath & "/Reports/" & ReportName & "")
Report.SetDataSource(DataSet)
on last line i get this error
"no table found in the report "
K Dastgir
|
|
|
|
|
Hi all
Am having two tables, One is from Access and another from Sql,
Now i have to transact the data's in Sql table to Access table?
Can anyone pls give me some idea ASAP?
Thanks and Regards,,
Dana
|
|
|
|
|
They are seperate databases ( bad design ) You'll have to read the data you need from both and then deal with it in memory ( or you could merge the tables to one DB )
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
Dear Christian,
Can you be brief ?
Dana
|
|
|
|
|
I thought I was ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 have read from a text file and got the following result:
""c23","23/05/2007",93.37,94.01,93.22,93.9,6,303767,
"c24","23/05/2007",93.37,94.01,93.22,93.9,6,303767,
"c25","23/05/2007",93.37,94.01,93.22,93.9,6,303786,
"c26","23/05/2007",93.37,94.01,93.22,93.9,6,303787,
i have used
Dim txtData() As String
txtData = strContents.Split(separator)
now i want to loop through txtdata() and save each txtdata(i) to a database table. what is the fastest way to do that knowing that the txt files are really big.
thanks
|
|
|
|
|
The main thing is, you want to create batches of SQL that insert many records at once. That's where your main speed issue will be.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
how can i keep a thread waiting untill the other one finishes. Say i have
Dim t1 As Thread = New Thread(AddressOf execute)
Dim t2 As Thread = New Thread(AddressOf execute)
t1.start(0)
t2.start(1)
But t2 should not start untill t1 finishes. I have to create say varying threads right now i and only creating two threads but i have to actually create as many as there are records in the database. but at the same they won't be more then 5, but could be less even one. At end of the program(thread) i am updating records in the database and that is the reason i dont want to start the next thread before the finish of the first.
Regards
|
|
|
|
|
Use the BackgroundWorker class, and when it fires the event to say that the first thread has finished, start the second one. Why would you start a thread you don't want to run ? Better yet, just have the one thread perform both actions, that's how it will work in the end
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|