|
Almost there: I expect that the browser, not the server, will launch the app in this case. I think it might have to be done via a URL moniker, like you get on the http://www.bitzi.com site. These will activate file sharing programs such as KaZaA and pass the download parameters into the program. My additional requirement is that the Windows Forms app can activate the browser instance (IE in this case) that created it and get it to navigate to a URL on completion of the process. Simple, eh? :-/
|
|
|
|
|
Monikers are used to tell a browser what application to launch based on the contents of the html page. For example, a PDF file moniker will tell the browser to launch AcrobatReader to render the content PDF content.
You can setup links to launch various programs, like Kazaa, but Kazaa won't return anything back to your browser since it's not written to do so.
Also, your windows app would have a difficult time determining which browser launched it, unless there was only one browser window open. Telling the existing browser to navigate to another URL would not be a trivial task.
RageInTheMachine9532
|
|
|
|
|
I Dim a graphic “Public Ax1g1 As Graphics = MYform1.CreateGraphics” and the call the “bitblt” function to capture the image and then I release the handle “Ax1g1.ReleaseHdc(dc1)”
On any subsequent call to this class “Ax1ThumbnailClass.AxCaptureImage” I get an invalid parameter exception on Ax1g1.ReleaseHdc(dc1).
I’ve tried not releasing the handles and I do not get the exception but the captured image is blank.
Help greatly appreciated!!!!
********************CALLING CODE***********************
Ax1Thumbnail.AxCaptureImage(MYform1.AxWebBrowser1.Location.X, MYform1.AxWebBrowser1.Location.Y)
Myform2.thumbScr1.Image = Ax1Thumbnail.Ax1Image.GetThumbnailImage(50, 50, Nothing, Nothing)
Public Class Ax1ThumbnailClass
Public Ax1g1 As Graphics = MYform1.CreateGraphics()
Public Ax1Image = New Bitmap(150, 150, Ax1g1)
Public Ax1g2 As Graphics = Graphics.FromImage(Ax1Image)
Public dc1 As IntPtr = Ax1g1.GetHdc()
Public dc2 As IntPtr = Ax1g2.GetHdc()
Public Sub AxCaptureImage(ByVal Browser1 As Integer, ByVal Browser2 As Integer)
CallBitBlt.BitBlt(dc2, 0, 0, 150, 150, dc1, Browser1, Browser2, SSRCCOPY)
Ax1g1.ReleaseHdc(dc1)
Ax1g2.ReleaseHdc(dc2)
End Sub
End Class
Public Class bitbltClass
<system.runtime.interopservices.dllimportattribute("gdi32.dll")> _
Public Shared Function BitBlt(ByVal hdcDest As IntPtr, _
ByVal nXDest As Integer, _
ByVal nYDest As Integer, _
ByVal nWidth As Integer, _
ByVal nHeight As Integer, _
ByVal hdcSrc As IntPtr, _
ByVal nXSrc As Integer, _
ByVal nYSrc As Integer, _
ByVal dwRop As System.Int32) As Boolean
End Function
End Class
Thanks, GregC
|
|
|
|
|
hi
i want to use the FtpCommand(API's function) with the command "Quote Site lrecl=80 recfm=fb" in VB6.but this FtpCommand function does not support this command and return an error with the subject of 500 INVALID COMMAND.i tried this function with other commands such as PWD,LS,GET,PUT but it also returns the same error,while this is the suggested function in MSDN for doing FTP.how can i use this function in my program specially with the command "Quote Site lrecl=80 recfm=fb"?i would be so happy if someone answers me.
|
|
|
|
|
The '500 Invalid Command' is comming back from the server your trying to talk to. This means you've sent a command the server didn't recognize. Even though it looks right in VB6, what the API got from VB wasn't right, apparently. This is evidenced by the fact that none of the FTP commands are working. Post the code your using for setting up the call to FTPCommand and the declaration for FTPCommand so we can see whats going on.
RageInTheMachine9532
|
|
|
|
|
hello
may i know how to put a dynamic form
into a static form
please teach me
thank you
Gary
|
|
|
|
|
The only 'forms' you can stick into another form are Windows Forms setup for MDI.
Are you using VB6 or VB.NET? If VB.NET, are you talking about Windows Forms or Web Forms?
What do you mean by 'dynamic' and 'static' forms?
We need a bit more information to understand what your talking about.
RageInTheMachine9532
|
|
|
|
|
im using vb6
and i have try using MDI
is successful
but with 1 problem
it wont open the form i want when i press a button
the form.show n form.hide wont work
why?
thank you for your reply
Gary
|
|
|
|
|
Code samples! There is no way to explain why until we see what your doing, or not doing, correctly.
RageInTheMachine9532
|
|
|
|
|
thank you for your help dave
unfortunately i have deleted it due to the result of failure and confuse
now i just plan to do normal linking coz MDI form i really dont understand
im a beginner in VB
if you can, can you send me a small/plain example
although in planet source code have it but it is quite hard for me to understand due to the module(.bas) that is available inside
if is not possible, it is ok
thank you for your help and advise
|
|
|
|
|
thank you for your help dave
unfortunately i have deleted it due to the result of failure and confuse
now i just plan to do normal linking coz MDI form i really dont understand
im a beginner in VB
if you can, can you send me a small/plain example
although in planet source code have it but it is quite hard for me to understand due to the module(.bas) that is available inside
if is not possible, it is ok
thank you for your help and advise
|
|
|
|
|
I've been working in Visual Foxpro forever and I've just recently learned VB.Net for windows forms and gotten pretty good at that. Now, I've spent the last week trying to learn web form development in VB.Net and can't figure out what's going on...
What looks and works great under "View in Browser" blows up on the Intranet. All of the labels, textboxes and buttons disappear. At one point I had everything disappearing under "View in Browser", but then I figured out I was using the wrong set of controls. Then I got it to where things looked good in the browser preview but disappeared when I hit F5 for a test run. Now, things that look good in the preview AND run on F5, disappear on the Intranet.
I understand that stumbling is ok, so long as you're stumbling forward. At this point though, I don't have time for stumbling. I need to get this one up right away.
========
Stewart
|
|
|
|
|
"View in Browser" isn't meant to allow you to run and debug a web form.
If you have it running in Debug mode, and you need to release it on the Intranet:
* Compile in release mode
* Install .NET on the server
* Create a new virtual directory on the server
* Copy the \bin directory and *.as?x and web.config to the server
* Cross your fingers...
What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
|
|
|
|
|
How do to do that? Pls help me. Suppose their same WORKGROUP. Pls give me a code.
|
|
|
|
|
The code is 42.
Perl combines all the worst aspects of C and Lisp: a billion different sublanguages in one monolithic executable. It combines the power of C with the readability of PostScript. -- Jamie Zawinski
|
|
|
|
|
"The code is 42"... what is it?... I need a real source code which write by Visual Basic 6. hic... pls...
|
|
|
|
|
Is there a way to open a specific Access file using Excel Visual Basic. I have a PC that runs tasks 24/7/365 which moves files, creates new files using Microsoft Querry, send email reminders, but I cannot figure out how to open a specific Access file that contains an autoexec macro to handle all of the querry and reporting functions.
Any help would be greatly appreciated.
|
|
|
|
|
Found this link on MS Support, running a Access Macro from Excel, it uses DDE (Dynamic Data Exchange):
http://support.microsoft.com/default.aspx?scid=kb;en-us;131921
|
|
|
|
|
As my articles in datagrid has different status,so i want to differ them by different backcolor,that is i want a record displayed in datagrid changed its backcolor by its status.
Looking forward to your reply.
Thanks a lot!
|
|
|
|
|
You will have to do it in the ItemDataBound event. Every row that is created will fire this event before creating the actual row.
private grid_ItemDataBound(Byval sender as system.object, byval e as DataGridItemEventArgs) handles grid.ItemDataBound
If e.item.itemtype = ListItemType.Item or ListItemType.AlternatingItem then
'You can do this
dim r as TableCellCollection = e.item.Cells
r.item(0).BackColor = Color.Coral
'or
i = 0
e.item.cells(i).BackColor = Color.FireBrick
End if
end sub
Oops, I thought I was in the ASP.Net section. However, this still may be helpful.
Hope this helps,
Michael
I firmly believe that any man's finest hour, the greatest fulfillment of all that he holds dear, is that moment when he has worked his heart out in a good cause and lies exhausted on the field of battle - victorious.
Vince Lombardi (1913-1970)
|
|
|
|
|
I have solved my problem by your hints.Perhaps I didn't express my problem very well. Anyhow,thanks a lot.
Following are my code:
Sub dgArticles_ItemDataBound(ByVal sender As Object, ByVal e As DataGridItemEventArgs)
Dim item As DataGridItem
For Each item In dgArticles.Items
'put your judge condition here
'assumed it return 1 and 2
Select Case CurrentStatus
Case "1"
item.BackColor = Color.Coral
Case "2"
item.BackColor = Color.Beige
Case Else
'do nothing
End Select
Next item
end sub
I hope I can get your help when i am in need on program.
May you happy!
|
|
|
|
|
Hi all,
I'm a masters student in psychology, have have a general grip on VB.net but I need to measure my participants' reaction time to high precision (i.e. accurate to the ms) and I need a bit of help.
I've had it suggested that I use a timer control and make it count, but I'd much prefer to access the system clock more directly if possible. I'm currently using the vbtimer, and I also previously had it working with timegettime. Some general advice about the most precise way to do this, and what types or objects are involved would be brilliant.
Thanks!
|
|
|
|
|
The most accurate timer in the system is accessed by QueryPerformanceCounter and QueryPerformanceFrequency. You can refer to this[^] MSDN article on how to use it from VB.NET.
RageInTheMachine9532
|
|
|
|
|
i extract icons in size of 32 and display them in toolbars and pictureboxes but when saving ...problem
|
|
|
|
|
Hi
I want to save some icon that extracted from an exe file (using ExtractIconEx) but when I saved them the color of the saved is too less than original and in some cases the saved file is in gray
using imagelist couldn't repair it
who can help me?
|
|
|
|