|
Can I make a chart in Visual Basic 6 in a form.
What kind of reference must I use?
I don't want to make it myself, I mean drawing it myself.
|
|
|
|
|
leaveu wrote: Can I make a chart in Visual Basic 6 in a form
Yes. But why use VB6, it is pretty dead these days.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Hi gurus.
I need to create floor map for each (4 floors) floor in my company new building.
Map should be similar to Google maps i.e. when map is viewed (image) I want to show employee names in their cubicles. When specific person is searched I want to show where he seats (just that person). Employee (name) should be tied to Office Communicator (IM), which shows status of the person. I can get employee information from Active Directory (name, title, email, etc.)
Did anyone have any experience doing this? Any help would be greatly appreciated.
If I didn't explain good enough let me know and I will try as best as I can.
Thank you all,
Alex.
|
|
|
|
|
If you cross-post, it's unlikely you're going to get much help
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
This question is for both forums and I don't know how to ask it otherwise.
Instead of just answering the way you did, and wasting your time and mine, you could've answer my question, if you can of course. Then you can let me know that I souldn't have posted it in 2 forums.
Again. I've done it only because I know it can be related to both Forums and I'm not sure people visit both of them like you do.
Thank you,
Alex.
I see that you've posted this response directly to me rather than to the forum.
If you had taken the time to read the forum guidelines, you would know that cross-posting is frowned upon. You shouldn't have to be told this - it's common sense. Cross-posting makes it difficult for people to collaborate on a solution and for other people to find help when searching the forums. I'm not wasting yours or my time by stating this, I'm making you aware of your breach of etiquette. As rule 1 in the forum guidelines states - choose the most appropriate forum for your question and post there only. Your statement that most people don't visit all the forums is irrelevent.
Anyway, what has your question got to do with VB.NET? It's clearly a web development issue.
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
Yeah. I know it is. But had web questions answered to me in this Forum before. Sometimes you can get a good idea/push from people in here. Sorry for the breach of etiquette. Usually I don't do this. I really need to make my problem work and right now I'm not even sure how to start.
Tanks, Alex.
|
|
|
|
|
I have setup my EXE(it's like a main menu calling other apps or assemblies) to use mutex for checking if another instance of the exe is running...this all works correctly. I have another access point into the mutex logic from the browser -- it runs different logic having the original exe start the requested application. This works correctly 90% of the time. On occasion even though the original exe is running, the TCPChannel will become disconnected -- without explanation. The only location that the actual disconnection logic exists in the code is in the dispose routine. I put logging in there marking sure that routine wasn't being called and it is not.
What is disconnecting the channel? Is there some unknown timeout I didn't notice?
Thanks.
Nathan
-- modified at 14:28 Wednesday 28th November, 2007
|
|
|
|
|
I am saving data automatically each time a user steps off a field. However, if the user wants to exit using the X button and is stepping off an unsaved field to get to the X button the data just entered is disregarded. Stepping off to any other field is no problem...just the X button. Its like once the X button has been keyed then it overrides the leave event (where I am saving the data) to just exit the form.
Any suggestions. I have fiddled with the Form Closing and the Leave event on a datagridview to no avail.
|
|
|
|
|
you want the Form.FormClosing event.
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use PRE tags to preserve formatting when showing multi-line code snippets
|
|
|
|
|
Hi Luc...This is the first time I've posted here. Thanks for the really fast reply. I'll go back to the FormClosing event and give it another whirl.
|
|
|
|
|
You're welcome.
Wolfpacker wrote: the really fast reply
whatever the day or time, there is always a lot of people around...
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use PRE tags to preserve formatting when showing multi-line code snippets
|
|
|
|
|
Please i can i play sound in vb.net if the sound files are stored in a database.
|
|
|
|
|
Wun'nam wrote: can i play sound in vb.net if the sound files are stored in a database
Yes, you can. You'll have to save the sound file as a binary type, and pull it out and work some magic
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I am creating a windows application using vb .net 2005 and sql server 2005.
i want to print a local (embedded) rdlc report without showing it.
is it possible?
if not, then how do i print the report (displayed in reportiviewer) without showing print dialog.
Thank you.
|
|
|
|
|
i want to scan and save the image file created from my application from the scanner output..provide me with TWAIN.dll along with code or some code to do that...i also want to save it with the file name i give and the path of it...can anyone do that
thanks
drink whisky save water
|
|
|
|
|
Hi Niraj
Bellow is the code for scanning a document from a scanner attached to the system. You have to reference the a file 'wiaaut.dll' which u can get from the internet.
Enjoy scanning without drivers loaded.
Imports System.Reflection
Imports Microsoft.Win32
Imports WIA
'Inside the Scan Button write the codes below.
Dim Dlg1 As New WIA.CommonDialog
Dim Scanner1 As WIA.Device
Dim Img As WIA.ImageFile
Scanner1 = Dlg1.ShowSelectDevice(WIA.WiaDeviceType.ScannerDeviceType, False, False)
Img = Scanner1.Items(1).Transfer
Img.SaveFile(strpathandfilename)
Sekhar
|
|
|
|
|
I dont understand enumerators. Why are they used instead of normal variables...there has to be a benifit? What exactly are they? Does anyone know how to break this topic down for me...i searched MSDN2 and that was way over my head. I just need to know what they are and what are the rules and reasons that they are used. Any help would be great
Erica
|
|
|
|
|
imonfiredammit wrote: I dont understand enumerators. Why are they used instead of normal variables
Enumerators are just objects, just like normal variables are objects.
imonfiredammit wrote: there has to be a benifit? What exactly are they?
They limit the range of possible values that can be assigned to a variable with the specified enumerator's type.
imonfiredammit wrote: Does anyone know how to break this topic down for me...
Can I suggest chapter 9 of Microsoft Visual C# 2005 Step-by-step
Oops! Just realised this is the VB.NET forum. There is an equivalent book for VB.NET.
|
|
|
|
|
Colin Angus Mackay wrote: Enumerators are just objects, just like normal variables are objects.
Hi Colin, well, actually not all normal variables are objects. An integral type (Int16, Int32, etc.. ) is a value type, and it is not stored as an object (reference type) UNLESS it is needed to. It all depends on your code's syntax.
This automatic conversion between value types and reference types is managed transparently by the .net platform by means of two behind-the-scenes processes known as "boxing" and "unboxing" respectively.
Boxing implies first creating on the heap a new instance of an object "compatible" with the original value type (involving dynamic memory allocation) then the actual variable's value must be copied to this new instance.
Unboxing implies dereferencing the value stored in an object instance and convert it back to a value-type.
Dim o as Object
Dim n as Integer
Dim m as Integer
Dim al as New ArrayList
o = 5 ' the value 5 is converted to an object (boxing) before being assigned
n = 0 ' the object's value 5 is dereferenced and stored back in n as a type value (unboxing)
' This means that n holds a copy of the value stored in o (5) not an extra reference to the same object refered by o
m = 10 ' The value 10 is directly stored in variable m as a value type, no heap memory allocation has taken place
al.Add(m) ' The variable m is converted to an object (boxed) before being added to the collection
Some languages like C++ can't treat integral types as objects for the sake of efficiency, other languages like Smalltalk effectively treat every variable (even integral types) as objects, which results in memory allocation/deallocation overhead for every single variable. The .net platform gives you the best of both worlds: on most cases, integral variables will be treated as efficiently as C++'s integral variables, but if needed to, they will be *transparently* converted to an object by the automatic "boxing-unboxing" process, giving you the full benefits of object orientation.
Cheers,
Gerardo
An interesting form of object-oriented programming:
You suggest a novel algorithm, and watch as the rest of your team objects!
|
|
|
|
|
Hi Erica
It's not clear in your post if you are asking about enumerations or enumerators.
They sound similar, but are totally different concepts. However, since you are asking about the difference between them and "normal variables" I assume you mean enumerations.
Talking about Visual Basic (at least with version 2003), their purpose varies depending whether you are compiling with Option Strict On .
With Option Strict Off , there is little difference between an enumeration and and integral variable. The enumeration simply helps the editor's Code Completion engine to suggest possible values for a variable (something really helpful). However, with Option Strict On , they allow you to program more robust applications since you will be creating a new data type that will have a restricted number of possible valid values.
To illustrate the enumeration's superiority *when used in an Option Strict On context*, imagine you are writing some sort of media player application. Most probably you need to control the player's state (playing, stopped, recording, etc). One valid way of doing it using normal integral variables as you suggest would be the following:
<code>
Const psStopped As Integer = 1
Const psPlaying As Integer = 2
Const psPaused As Integer = 3
Const psRecording As Integer = 4</code>
Then, you could somewhere in the code have a variable for controlling the state
<code>
Dim state as Integer
...
...
' Set the player's state to Playing
state = psPlaying</code>
This works, however, since the state value is held on a variable of type Integer, you might inadvertently add the following code
state = 5 ' oops this is an undefined player state
This is valid code and will compile without a fuzz, yet you might put your application in an invalid state and get unwanted results since the value 5 is a valid Integer value, but it is not an expected player state in your app's logic.
However, if you rewrite your application using an enumeration AND compile with Option Strict On:
<code>
Option Strict On
...
Public Enum PlayerStates
Stopped = 1
Playing = 2
Paused = 3
Recording = 4
End Enum
...
Dim state as PlayerStates
...
...
...
state = PlayerStates.Playing;
...
state = 5 ' This will give a compiler error, but ONLY IF compiling with
' Option Strict On
</code>
In this case, the compiler helped you avoid a possible programming error by disallowing assigning an invalid player state, according to the values defined in the PlayerStates enumeration.
This and other "defensive programming" options are available when compiling with Option Strict On, which is something I would recommend in the long run.
Hope I have clarified your doubt.
Cheers,
Gerardo
|
|
|
|
|
Hi Everybody,
Am sameer Pandurangi, a S/W Engineer and trying to build a small application.
Am working on VB.NET on windows application and using SQLSERVER Compact Edition.
I need a code to ZIP the database files and take the backup of it,and vice-versa need to UNZIP them before restoring.
If anyone out there know any thing about Zipping and Un-Zipping of files Please send me the note.
Thankyou
|
|
|
|
|
Have you tried to search Google[^]?
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
|
That is a good one.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Hi
All
My Problem
Save click i am saving my supplier
SearchuniquesupplierID() in this proc actually i am inserting my supplier.
In the checkfortheSupplier() proc i am checking whether
the supplier is already exista or not
For the Forex supplier i can select the multiple
currency . I used listbox.
I got problem in my checkfortheSupplier()
for ex. if i add abc supplier For Europe Country For
two currency EUR and AUD.
Then in my table two rows are created.
but when i try to add same supplier for say EUR and and usd then it creates the proble actually it add
both which should not happen .
Pl update me.
Thanks
<br />
Private Sub ButSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ButSave.Click<br />
checkfortheSupplier()<br />
'updateSupplierID()<br />
If (Supplier = True) Then<br />
If Not IsClientScriptBlockRegistered("alert") Then<br />
Page.RegisterClientScriptBlock("alert", "<script language = 'javascript'>alert('Supplier Already Added!');</script>")<br />
End If<br />
Exit Sub<br />
' End If<br />
Else<br />
<br />
If (RdINR.Checked = True) Then<br />
'inserttheSupplierINR()<br />
SearchuniquesupplierID()<br />
If Not IsClientScriptBlockRegistered("alert") Then<br />
Page.RegisterClientScriptBlock("alert", "<script language = 'javascript'>alert('Supplier Information Added Successfully!');</script>")<br />
End If<br />
ElseIf (RDForex.Checked = True) Then<br />
'inserttheSupplierForex()<br />
SearchuniquesupplierID()<br />
If Not IsClientScriptBlockRegistered("alert") Then<br />
Page.RegisterClientScriptBlock("alert", "<script language = 'javascript'>alert('Supplier Information Added Successfully!');</script>")<br />
End If<br />
<br />
End If 'RDINR if is closed <br />
End If<br />
End Sub<br />
<br />
<br />
#Region "Check Wheather Supplier already added or not"<br />
Public Sub checkfortheSupplier()<br />
Try<br />
connection.Open()<br />
strSql = ""<br />
<br />
For co = 0 To LstCurr.Items.Count - 1<br />
If LstCurr.Items(co).Selected Then<br />
strSql = "select supplier_name,country_id,currency from supplier_mst where supplier_name = '" & Trim(TxtSupplierName.Text) & "' and country_id='" & Trim(DpCountry.SelectedItem.Value) & "' and currency='" & Trim(LstCurr.Items(co).Text) & "'"<br />
command.CommandText = strSql<br />
command.Connection = connection<br />
dataReader = command.ExecuteReader<br />
End If<br />
Next<br />
While (dataReader.Read())<br />
Supplier = True<br />
End While<br />
<br />
<br />
Catch ex As Exception<br />
Finally<br />
dataReader.Close()<br />
connection.Close()<br />
End Try<br />
End Sub<br />
#End Region<br />
<br />
|
|
|
|