Procedure expects parameter - What am I missing
Hello,
The error tells me;
---------------------------
Procedure 'usp_sequ_sel' expects parameter '@sqfkJob', which was not
supplied.
---------------------------
But I do supply it!!
What am I missing??
Here is my Stored Procdure [usp_sequ_sel]
\\
CREATE PROCEDURE dbo.usp_sequ_sel
(@sqfkJob char(36)) AS SET NOCOUNT ON;
SELECT
pkSequId,
sqfkJob,
sqComponentDescription,
sqAction,
sqDuration,
sqSooOrder,
sqSooPrecedent,
sqSooDelay,
sqSooNote,
sqCreatedOn,
sqCreatedBy,
sqEditedOn,
sqEditedBy,
sqrowversion
FROM tbl050Sequ
WHERE (sqfkJob = @sqfkJob)
GO
//
Here is the Variable as defined in f050Sequ
\\
Friend Shared _pkJobID As String 'Using a GUID'
//
This variable is populated in a combobox
\\
Me._pkJobID = Me.cboSelectJob.SelectedValue.ToString
//
Here is the button to load the datagrid.
\\
Private Sub btnLoadTasks_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles btnLoadTasks.Click
'Verifies that the variable '_pkJobID' has gotten the value
MessageBox.Show("From f050SqOO.vb ~ sqfkJob: " & Me._pkJobID)
_dt = _dataSet1.tbl050Sequ 'The dataTable
DAL.da050SequFrm.Fill(_dt)
Me.DataGrid1.DataSource = _dt
End Sub
//
Here is the command located in DataAccess.vb runs the stored procedure.
\\
With cmd050Sequ_sel
.CommandType = CommandType.StoredProcedure
.CommandText = "usp_sequ_sel"
.Connection = sqlConn
With cmd050Sequ_sel.Parameters
.Add(New SqlParameter("@RETURN_VALUE", SqlDbType.Int, 4, _
ParameterDirection.ReturnValue, False, CType(0, Byte), _
CType(0, Byte), "", DataRowVersion.Current, Nothing))
'The line just below fails
'.Add("@sqfkJob", SqlDbType.Text).Value = f050SqOO._pkJobID
'The line just below succeds
.Add("@sqfkJob", SqlDbType.Text).Value = _
"18713191-e116-4d92-8cc2-c2d4e8c34fdb"
End With
End With
//
I use this same scenario in many other forms. For some reason I cannot
see what is different here.
f050SqOO._pkJobID seems not to be getting the value in DataAccess.vb
Help me see the problem.
thank you,
dbuchanan Tag: VPN question Tag: 92339
4 pane SplitContainer
The SplitContainer divides the space in two, either horizontally or
vertically.
I'd like to divide the space in four. By adding more splitters, the
problem is that they don't keep in synch automatically. It'd be nice if
when the mouse hovers in the center of the four regions a cross
movement icon is displayed, and movement in the two axis is allowed.
With the solution of adding more splitters the user is forced to first
move in one direction and then in the other one.
What do you recommend to achieve this?
Thanks. Tag: VPN question Tag: 92336
Adding forms into a panel
Hi everybody:
I am adding several forms into a panel to give MDI appearance to my panel..
Though the forms inside my panel looks fine, I have three problems:
1. The focused form does have the title bar activated (it is gray, like the
inactive forms)
2. The only way to bring to front a form is clicking the title bar (in a MDI
container, the user can click at anyplace in the form and it gets
activated).
3. Cascade, horizontal tile and vertical tile functionality is not provided.
Well, the tile and cascade window organization can be implemented, but I do
not know how to deal with the focus and mouse problem.
Am I doing something wrong? There is another way to implement this
functionality?
Thank you in advance
Ernesto Tag: VPN question Tag: 92332
MDI Child Controls
If I have a second form that is a mdichild, let's say frm2 and I want to
update a textbox control pragmatically...
In my MDI parent, I open 5 instances
Dim f as new frm2
private sub OpenForm()
for i = 0 to 4
f = new frm2
f.mdiparent = me
f.show
end sub
Now, from my parent, I want to update a textbox1 in the active mdi child,
how can I? When I just try f.textbox1.text = "some text" it updates the
control on the last handle created. I tried finding the active child but
couldn't determine how to go from there after I got it.
Any help and links would be great.
Regards,
Brian Tag: VPN question Tag: 92325
Forms are re-locating
Hi,
I have an application which shows forms on two different independant
screens. The Windows desktop is spread across these screens.
The forms are all set to manual positioning, and so to show a form on
the second screen, I simply set the coordinates to be on the second
screen and that is where it goes.
It now seems to have developed a problem however:
When I trace through what is happening all the coordinates get set
correctly, and then I call Show() for the form. When show returns, the
forms coordinates have been changed to show it on the first screen.
I can't trace into the Show function, as it's part of the framework, but
something weird is happening.
Has anybody seen this before or got any idea what could be going on?
Thankyou in advance.
Paul Cheetham. Tag: VPN question Tag: 92320
FindDialog for RichTextBox problem
Hi!
I created a FindDialog for RichTextBox.
I have 2 problem with it:
- when I ShowDialog() my FindDialog, it got the focus and the RichTextBox
stop displaying its current selection (it apparently need the focus to draw
it), so when the user click "Find Next" I select the next match, but the
user has no visual feedback :-/
- I also try the RichTextBoxFins.Reverse option, doesn't seems to work at
all!
Any ideas?
--
If you're in a war, instead of throwing a hand grenade at the enemy, throw
one of those small pumpkins. Maybe it'll make everyone think how stupid war
is, and while they are thinking, you can throw a real grenade at them.
Jack Handey. Tag: VPN question Tag: 92316
Combo refresh/binding problem
Hi-
I have two combobox controls (among other controls) that are all bound to
dataset0 from the "Main" table. Combobox2 is bound to a column that contains
a FK (system_id) which corresponds to the PK from the "Systems" table. These
combobox's also function as picklists and as such are filled from two
corresponding datasets (dataset2 contains the system_id (PK) and SystemName
column from the the "Systems" table. The contents of Combobox2 depends on the
selected item in combobox1.
usage model is as follows:
The controls are all bound to dataset0 by a hand-coded procedure at form
load. This works fine. Combobox1 is populated by dataset1.fill. The user can
scroll through the dataset0 records from ""Main" table by navigation
buttons. The displayed string values in the comboboxes change accordingly.
When the user wants to make changes, he opens the current record for editing
but using a button which unlocks the controls. He then makes a selection from
dataset1 loaded in Combobox1. All good so far.
The change event on Combobox1 fires, and the contents of Combobox2 should
then be loaded by dataset2 which takes a parameter based on the selection
made in combobox1. This is used a parameter to the dataset2 which should
populate combobox2 with the appropriate choices for the selection made in
ComboBox1. But what is reflected in combobox2 is a bunch of rows that all say
"System.Data.DataRowView"
I should mention that this was a port from a VB6 where this worked
correctly. The combobox2.datafield property was set to an integer (system_id)
representing a FK in a column in dataset0. When the user chose the value in
Combobox1, the value was sent as a parameter which was used to a recordset
which yielded values to populate ComboBox2. This recordset came from the
Systems table. ComboBox2.boundcolumn was set to Systems.system_ID (the PK),
and the Combobox2.listfield was set to Systems.systemname. Since the control
was bound to FK system_id from dataset0, whatever value it was sitting on,
would display the correct systemname.
Obviously, I have no idea how to make this scenario work in .NET. Any help
would be appreciated.
--
thx,
jf kaminsky Tag: VPN question Tag: 92315
Sizing controls
My application has a command that inserts controls on a Form.
I move the controls by drag and drop.
Now I need resize the controls like it's made by VS.Net in designer mode.
How can I show the controls' edge lines and resize marks show on the corners?
Thanks. Tag: VPN question Tag: 92312
Window closed event?
In a windows forms app how do you know a window is closing? There seems
to be no event for this.
I have timer object that appears to be firing after the window is closed
(maybe) and I want to shut down and dispose the timer when the window
closes. Tag: VPN question Tag: 92308
What makes this code slow
This code resets a form with two cbo's (comboBoxes) and one datagrid.
The first cbo (cboSelection) selects a main table and filters the
second cbo. The second cbo (cboView) selects the secondary table which
determine the dataAdapter used to fill the dataGrid. Both cbo's are
populated by filling dataAdapters.
This code just empty's the datagrid, cbo's and dataset so the user can
start over to view another set of data.
\\
Private Sub btnResetForm_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnResetForm.Click
'Clear the datagrid
Me.DataGrid1.DataSource = Nothing
Me.DataGrid1.TableStyles.Clear()
'clear the dataset
_dataSet1.Clear()
DAL.da010JobFrm.Fill(_dataSet1, "tbl010Job")
'cboSelection
Me.cboSelection.DataSource = _dataSet1
Me.cboSelection.DisplayMember = "tbl010Job.JobNumber"
Me.cboSelection.ValueMember = "tbl010Job.pkJobId"
_bStillLoadingCboSelection = False
_bStillLoadingCboView = True
End Sub
//
What makes this code slow?
It is as slow as if it was about to throw an error.
Or How can I test this code?
Thank you,
dbuchanan Tag: VPN question Tag: 92306
How to get rgb of custom color
I have a color in a bitmap from a screen capture. the color is defined in
paintbrush with 6 numeric values. how to I convert this to rgb so I can
assign it to some controls on a vb.net form?
Thanks.
--
moondaddy@nospam.nospam Tag: VPN question Tag: 92297
Studio 2005 Style Drag & Drop Hints
I am creating a UI framework that is in someways similar but also very
different to the .Net IDE. The user can drag & drop framed panels anywhere,
float them, split them, etc, etc.
What I have been trying to do is recreate the Drag&Drop hints as in Visual
Studio 2005 IDE. I have tried BilBlt, adding a transparent control over the
drop control and other methods. Some get pretty close to working but I'm not
quite happy with the solution.
Has anyone done this before or have any idea to the best way to do it?
Thanks.
J. Tag: VPN question Tag: 92293
Override Close > Hide problem
Hi
I have two forms, Form1 and FormInfo. In FormInfo I override Close(),
cancels and hides the form. However now Windows isn't able to close my app
automatically when the user tries to close Windows while my app also is
running. Can this be solved without abandoning overriding the form?
/Andreas Zita Tag: VPN question Tag: 92290
Application.ThreadException becomes unwired?
Hi,
I'm writing a C# application that uses Application.ThreadException to
handle uncaught exceptions gracefully. However, I'm having a problem
where it is failing to catch some exceptions, and I've determined this
is because the event handler is becoming unwired: if I reinstall the
handler just before the code that causes the exception, the
Application_ThreadException method is called. Do you know of anything
that can cause this to happen? I've tried to replicate the problem in a
less complex testbed project, but have had no success.
Thanks in advance,
Max Tag: VPN question Tag: 92284
Problem with Scrolling in Tablet PC
Hi All
I am developing an application in C#.NET for Tablet PC. I am working on a
form whose Height is 1024, so thats why scroll comes up if Form Exceeds
Desktop's Hieght. For checking the check boxes or clicking the text boxes to
gain focus or using tab for navigating focus down to the controls which are
not in screen area. When I scrolled and clicked any control which is not in
screen height area then my form automatically gets scrolled to the 0,0
location and am unable to check the checkboxes. Is this the problem of
tablet Pc or am I missing something. Any help regarding the issue will be
highly appreciated.
Thanking In Advance
Fiaz Ali Saleemi Tag: VPN question Tag: 92273
Satellite Assemblies and Win Forms
Hi,
Iâ??m creating a project which uses Satellite Assemblies (SA) to isolate
localized resources. The solution contains eight library projects, one GUI
control project and one Windows Form project.
I know how to approach SA for library projects, but I do not have any idea
how to do it for Windows Forms and Controls. Should I use Localizable
properties on every win form and win control that I create and copy resource
files associated with form/control to SA? Or should I just create resource
file in SA with the exact name as the resx files of form/control?
Which approach is better? Or maybe there is another, different approach that
I should consider? Which approach will allow me to modify form/control in the
design view?
--Start: Different question but still about resources
Can I use String Resource Tools to create resx and corresponding cs file and
then split them into two separate projects â?? resx and string file (string
file is created by String Resources Tool) will go to SA, and cs file to new
library project? Or maybe I can access cs file in file created by SA?
--End.
Iâ??ll be grateful for yours help.
Kind regards,
Jakub G. Tag: VPN question Tag: 92259
Display Word document text in Windows Forms without text editor
I want to open a word document and display all the text in a windows forms.
Like the Ms Word Viewer. Only for read it, no modify.
I do not have problems opening and reading the document. The problem is
display de text. I do it of the following form:
Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs)
Handles MyBase.Load
filename = "C:\1.doc"
Wrd.Documents.Open(filename, confirmConversions, rd, addToRecentFiles,
passwordDocument, passwordTemplate, revert, writePasswordDocument,
writePasswordTemplate, format, encoding, vis)
End Sub
Private Sub Form1_Paint(ByVal sender As Object, ByVal e As
System.Windows.Forms.PaintEventArgs) Handles MyBase.Paint
Dim range As Object
Dim str As New System.Text.StringBuilder
Dim drawfont As Font
Dim drawbrush As SolidBrush
Wrd.ActiveDocument.Range.SetRange(0, Wrd.ActiveDocument.Words.Count)
Wrd.ActiveDocument.Range.Start = 0
Wrd.ActiveDocument.Range.End = Wrd.ActiveDocument.Words.Count - 1
For Each Rng In Wrd.ActiveDocument.Words
' Create font and brush.
drawfont = New Font(Rng.Font.Name, Rng.Font.Size, FontStyle.Regular)
drawbrush = New SolidBrush(Color.Black)
Dim drawFormat As New StringFormat
drawFormat.FormatFlags = StringFormatFlags.DirectionVertical
' Draw string to screen.
str.Append(Rng.Text & " ")
Next
e.Graphics.DrawString(str.ToString, drawfont, drawbrush, x, y)
End Sub
'I don´t use any text editor because I won´t edit the text, only read.
Some suggestion? Tag: VPN question Tag: 92255
Word To .Chm Conversion
Hi,
In my windows application i am creating a word document. Word document has
some pictures in it. I want to convert document file to .chm file. Is there
any class available in .Net to do this?
Thx in advance.
Prasad. Tag: VPN question Tag: 92253
OFFICE AUTOMATION LICENSING
Dear all,
If i develop a windows based application VB.NET , it need to export some
excel and word document from the VB.NET application. such as excel report or
word report and it need to import the reference of office component to do
that, is it ok to deploy the windows application together with the imported
office component dll library to client machine? Tag: VPN question Tag: 92250
2.0 question
what's the difference between the 2 following events:
Form.Closed
Form.FormClosed
??
--
NovaMind development team
NovaMind Software
Mind Mapping Software
<www.nova-mind.com> Tag: VPN question Tag: 92242
Problem using API CreateBitmap function and keeping transparent co
I have a C# DLL that loads a bitmap object from a PNG file. Thanks to Bob
Powell's advice i managed to access the Bitmap data using the lockbits method
and then call the Windows API function CreateBitmap successfully. Then the
DLL provides a COM interface which returns the handle to the bitmap created
using CreateBitmap function.
The problem is that the initial bitmap has a transparent background color,
and when using the CreateBitmap function, the bitmap seems to loose this
color, which is then replaced by black (maybe something to see with
ColorPalette). Furthermore, the createdbitmap is a 32bit bitmap so the alpha
layer which contains transparency informations should be the same. So i don't
know what i missing or doing wrong. here is the code that creates the bitmap
:
Bitmap bitmap = (Bitmap) Bitmap.FromFile(@"C:\tmpicon.png");
BitmapData data = bitmap.LockBits(new Rectangle(new Point(0,0),
bitmap.Size), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb);
IntPtr HBITMAP = CreateBitmap(bitmap.Width, bitmap.Height, 1, 32, data.Scan0);
NB : I also noticed that when opening the PNG file with MS Paint, the
transparent color is replaced by black, whereas opening it with Photoshop or
Windows Picture viewer, the transparency is visible. Can't explain this...
I'd like to understand what im missing to keep the transparent color on the
created bitmap.
Thx for any help. Tag: VPN question Tag: 92237
ToolStripContainer and MDI applications?
Hi,
I have an MDI container form (Form1) that has a MenuStrip and a ToolStrip
embedded in a ToolStripContainer. Form1.MainMenuStrip is set to MenuStrip1.
The "Content" part has a ToolStripPanel docked to Fill the entire space. I
guess this is a pretty normal setup.
The problem is that all Mdi childs are invisible. They open up under the
ToolStripContainer, making them invisible.
What am I doing wrong? I open the Mdi childs like this:
Form2 frm = new Form2();
frm.MdiParent = this;
frm.Show();
Thanks a lot for your help! Tag: VPN question Tag: 92235
MouseUp event "falls through" FileDialog and activates control underneath
Hello,
In my app I have a UI control that responds to MouseUp events and opens a
FileDialog. If an item in the dialog is double-clicked (instead of clicking
on it then clicking OK) AND that item is over my UI control, the final
MouseUp of the double-click is registered by my control and its handler is
called, opening the FileDialog again.
The events happen in this order:
MouseDown
MouseUp
Dialog Opens
Double-click in dialog
Dialog closes
MouseUp
DialogOpens, etc.
I'm looking for suggestions on how to correct this. I've tried removing the
MouseUp handler when the FileDialog is opened, and adding it beck when it is
closed but that doesn't work; it still gets called. I've tried looking for
a way to "eat" the MouseUp but haven't found a way that works. For example,
purging the event queue or marking the event as being handled/ignored.
So, any suggestions?
Keith Tag: VPN question Tag: 92228
RichTextBox + DragDrop = Buggy?
Hi
Consider this simple scenario:
richTextBox1.AllowDrop = true;
richTextBox1.DragDrop += new DragEventHandler(richTextBox1_DragDrop);
richTextBox1.DragEnter += new DragEventHandler(richTextBox1_DragEnter);
richTextBox1.Text = "";
private void richTextBox1_DragDrop(object sender, DragEventArgs e)
{
richTextBox1.Text += e.Data.GetData(typeof(string)) + "\n";
}
private void richTextBox1_DragEnter(object sender, DragEventArgs e)
{
if (e.Data.GetDataPresent("UniformResourceLocator"))
e.Effect = DragDropEffects.Link;
}
When dragging a URL from IE and dropping it on the RichTextBox everything is
fine. But when also clicking in the control, the drop event is activated
once more!? That can't be right?
I have only found this to happen in the RichTextBox. Is it a bug in this
control or am I forgetting something?
/Andreas Zita Tag: VPN question Tag: 92226
Internet connection detection
Hi all.
What's the best way to detect if the machine running my app is connected to
the Net? I don't need any network/dns info, just "connected? true/false".
Thanks!! Tag: VPN question Tag: 92221
displaying config dialog after main form
For the first run of my application, the configuration dialog
needs to be displayed. I have tried loading the config dialog
in the form load, but the form is not loaded yet. What is the
easiest way to display the config dialog?
Sam Tag: VPN question Tag: 92217
Installing Merge Modules from C# Windows Form Application (not using a setup and deployment project)
Installing Merge Modules from C# Windows Form Application (not using a setup
and deployment project)
Hi,
Currently, we have an InstallShield project that creates a setup.exe that
only installs 20 or so merge modules. It does nothing else. We then have
our own custom, C# Windows Form application that installs our software
applications. It does this by copying files, creating registry keys, etc.
So what I'm trying to do is get rid of the separate InstallShield setup.exe.
We want one setup application that installs both the merge modules we need
and our software applications.
Is there any way to run/install merge modules from a C# Windows Form
application? We are not and cannot use a Setup and Deployment Project to do
this.
Thanks. Tag: VPN question Tag: 92216
Opening up windows form with muliple threads
Hi,
I have an application which has browser control in it, i open this form and
it does some automated steps and closes it self every thing wrok so far.
Now wanted to open multiple instances of this form each of them running in
its own thread. But when i try to create this form within newly created
thread it gives me error (somthing like Activex control cannot be
instnciated in a worker thread etc)
any idea hint,
Thanks,
Sajjad Tag: VPN question Tag: 92215
Loading (Running) EXE into GAC
Hi,
Could anybody provide good reason for me to load my windows forms exe into
GAC and then use it as primary application location?
Thanks,
Leonid Tag: VPN question Tag: 92213
Windows Forms in Windows Services
Hi , Is it possible to have Windows Forms in a Windows Service , I have tried
to do it but the application always locked .
Actually I am calling de .show method of the Form in the Onstart Event of
the service .
In the Microsoft documentation I can see that a windows service is a process
that does not have a user interface ; however when I used Visual studio 6.0 I
made services with an user interface ... How can I do this in .NET ... Or it
is not possible
Than you in advance. Tag: VPN question Tag: 92207
detecting the change in the cell of a datagrid
Hi
I am implementing DataGridTextBoxColumn in my Datagrid. I would like to find
out when the data in a cell belonging to this column style is changed. I
would like to format the contents say for instance to a currency if the
contents of the textbox are of numeric type.
I modified the following in the Commit function
Protected Overrides Function Commit(ByVal cm As CurrencyManager, ByVal
RowNum As Integer) As Boolean
'
' Parse the data and write to underlying record.
'
Me.HideEditBox() ' return focus to the DataGrid control
Dim box As DataGridTextBox = CType(Me.TextBox, DataGridTextBox),
Value As String
' Do not write data if not editing.
If box.IsInEditOrNavigateMode Then Return True
If TextBox.Text = "" Then ' in this example, "" maps to DBNull
SetColumnValueAtRow(cm, RowNum, DBNull.Value)
Else
' Parse the data.
Try
If ValidateContents(TextBox.Text) Then
Value = FormatContents(TextBox.Text)
Else
return false ' to retain the old value This is the
problem.
End If
Catch
Return False ' Exit on error and display old "good" value.
End Try
SetColumnValueAtRow(cm, RowNum, Value) ' Write new value.
End If
Me.EndEdit() ' Let the DataGrid know that processing is completed.
Return True ' success
End Function
Commit function is being called twice when I have the return stmt. If I take
it out the Value is nothing and I am losing the old value in the cell. Tag: VPN question Tag: 92206
Application.Run()
Does anybody know why some components like
Microsoft.DirectX.AudioVideoPlayback.Audio rely on the Application.Run
messaging system while other events in other classes dont?
Anyone got a reasonable way of testing that using NUnit as well?
Thanks in advance for any help offered.
Jax Tag: VPN question Tag: 92205
changed Property of Public Control a Designtime on UserControl disapears!
Hi,
I'm having some weird behaviour, and I can't find any solution to this.
I made a UserControl (uclCommands) which contains a Toolbar (ToolBar1) with
Modifiers = Public.
I put this usercontrol on my form and call it Ucl1. In the Property Window
in the Windows Forms Designer I change Ucl1.ToolBar1.ButtonSize to a bigger
value.
Everything goes fine: The buttons get the larger size. but after I compile,
the ButtonSize gets again the original size.....
Does anybody knows why this happens, and what I can do about it? I really
need this because my Usercontrol must have different sizes in my
application.
I tested this with Visual Studio 2005 beta 2 and VS 2003: Both the same
behaviour...
Any help or hints would be really appreciated!
Thanks a lot in advance,
Pieter Tag: VPN question Tag: 92204
NUnitForms - articles and tutorials?
Hello,
Where can I find articles and/or an online tutorial on using NUnitForms
for Windows forms?
dbuchanan Tag: VPN question Tag: 92202
databind with a combobox
Hi all,
I got a problem with binding an array of object with a combobox.
Here is my code:
public class Toto
{
public string Idr;
public string Name;
public Toto(string id, string name)
{
Idr = id;
Name = name;
}
}
... and the ui part:
Toto[] totoList = new Toto[3];
totoList[0] = new Toto("id1", "name1");
totoList[1] = new Toto("id2", "name2");
totoList[2] = new Toto("id3", "name3");
comboBox1.SelectedIndex = -1;
comboBox1.DataSource = totoList;
comboBox1.DisplayMember = "Name";
comboBox1.ValueMember = "Idr";
When the program reached the last statement (...ValueMember) I got an :
"Cannot bind to the new display member. Parameter name: newDisplayMember"
Someone knows why ?
Thx in advance Tag: VPN question Tag: 92200
How to restrict typing characters other than digit in TextBox in C
I am writing some winform application in C#.
I want my TextBox control have following properties:
1. accecpt inputing digits '0','1','2','3','4','5','6','7','8','9', and
display those digits in TextBox.Text as expect
2. If the user input something other than digits such as 'n', TextBox.Text
will not change but perform some operation as I wish.
How to program it.
Thanks.
AJang Tag: VPN question Tag: 92198
Draw line over richtextbox
Hi all,
Just want to ask help from you guys. I'm currently stuck with this problem:
I need to draw a line from richtextbox and connect it to a lable placed on
the form. I'm doing an application that has a similiar concept when you add
comments in ms word, there is a line connecting the text to the comments.
Thanks,
Jon Tag: VPN question Tag: 92193
Howto pass a cookie to a web browser
I have a windows application in vb.net which communicates with different
webservers. In some cases I want to start the internet explorer (or another
browser) with the current session. How can I pass the session cookie to the
browser? Tag: VPN question Tag: 92189
C# Listview subitems with checkbox/combobox
Hi,
I am using the listview in the grid format i.e Listview.View.Details.
I have a requrement where in I have to show checkbox and combo boxes in each
subitems. In other words there should be few checkbox columns and few
combobox columns in the listview. Currently I am able to show check box for
each item in the listview(i.e each row) but I need it for each cells.
Any help/suggestions is highly appreciated
Regards
Hitesh
hiteshsalian@yahoo.co.in Tag: VPN question Tag: 92185
Triggering a Control Event
This is probably a silly question, but is it possible to trigger a button
click event from inside the Form_Load event? I know I can just call the
Button_Click routine, but I'm not exactly sure how to setup the parameters.
Thanks in advance!
Jeff Tolman Tag: VPN question Tag: 92182
Control loaded in IE problem
I'm loading a control in IE. If the control is loaded from the server then
AppDomain.CurrentDomain.FriendlyName contains the URI of the server that the
page is from. If my control is loaded from the GAC on the client machine then
the FriendlyName is "Localhost". Is there a way to get the URI from within
the control.
I've used JScript to pass the document.domain into an OBJECT PARAM but this
requires me to change Security Settings to allow "Initialize and script
ActiveX controls not marked as safe". I'd like to avoid this whole issue.
-Steve Tag: VPN question Tag: 92181
Datagrid row selection
In windows explorer you can select multiple files using combinations of ctrl
and shift clicking, then if you click and hold the mouse button on one of the
already selected files you can drag all the selected files to wherever. I'm
trying to reproduce this kind of behavor in the datagrid, but the problem is
that when I click and hold the mouse button on an already selected row all
the other rows get cleared and only the clicked on row is selected! I thought
I could get around this by keeping track of all the selected rows,
intecepting the MouseDown event on an already selected row and then restoring
all the rows that are supposed to be selected using DataGrid.Select. However,
this doesn't seem to work. It appears that the rows get cleared *after* the
MouseDown event and, therefore, after my code to restore the selected rows.
This is very frustrating!
Does anybody have any ideas on how I can make this work? I have to restore
the selected rows while the user still has the mouse button down so that they
can drag them.
Thanks
WJ Tag: VPN question Tag: 92180
System.InvalidOperationException: Failed to load ImageList
I have seen talk of this around but none of them seem to be exactly my problem.
Anytime I compile the source of our application on my laptop I get the
following error when I run it:
System.Reflection.TargetInvocationException: Exception has been thrown by
the target of an invocation. ---> System.InvalidOperationException: Failed to
load ImageList.
at System.Windows.Forms.ImageListStreamer..ctor(SerializationInfo info,
StreamingContext context)
...
This happens on anybody's computer who runs the program I compiled on mine.
If they compile the same program I did it runs fine on both my computer and
theirs.
I looked into this futher and noticed that the ResEditor can't even open the
.resources file generated when I compile the program. It fails to load the
imagelist resource.
What is the problem? It is as if the resource compiler is not serializing
the imagelist out correctly.
I already tried to do a repair install of Visual Studio 2003. I have a
Windows XP SP2 system on a dell laptop. Tag: VPN question Tag: 92178
MessageBox-Like Focus in a Custom Form?
I am writing a Windows Forms application that manages "Project" content on
CD-ROM and DVD media. If the end-user wants to Open a "project", I have to
prompt them to insert the media if it not already in the drive. Legacy
media contains a heinous Autorun routine that I must intercept. I can do
all of this without problem.
However, I can only intercept the Autorun event if I am the "Top" Form with
Focus. So, I want to display a message box with Cancel and Retry buttons
that also contains my custom code for intercepting the Autorun event.
How do I create a form (or a derived message box) that incorporates my
custom code while maintaining the insistent modality of the MessageBox? Are
there some simple properties that I can set on a normal form or simple way
to inherit from the standard MessageBox and add my own code?
Any advice or suggestions are greatly appreciated.
Carl Tag: VPN question Tag: 92174
TreeNode collapse method does not persist the state of the sub-nodes
Hi all,
I haven't been able to find any post regarding this problem...
the MSDN help about TreeNode.Collapse clearly says:
"The state of a TreeNode is persisted. For example, if the next level
of child nodes was not collapsed previously, when the Expand method is
called, the child nodes appear in their previously expanded state."
but what actually happens, is that all the sub node are collapsed as
well...is that the normal behaviour? how can I persist their state?
Thanks,
Amidan. Tag: VPN question Tag: 92170
If i develop a window application in VPN network, can i use the domain
account so as tologin the app