|
So how would I publish a program with it, ince it is built in? Sorry if I sound like an idiot here.
- "Achieving all knowledge does not mean achieving all wisdom."
- "What makes you smart
?"
|
|
|
|
|
Do you have Visual Studio 2005 or 2008? Visual Studio 2005 and later can do the publish automatically for you with a few clicks. (I described this in the above post.)
If you don't have Visual Studio, you can still publish using ClickOnce, though it's a little more involved. You'd need to look up the free tool included in the .NET SDK called MageUI[^].
FYI, Visual Studio 2005 Express[^] is free; if you're working with C# a lot you should download that if you haven't already.
|
|
|
|
|
I have VS 05 and C#. But, every time I publish something and send it in an eMail, it ALWAYS says the program is missing files, so I thinksit's in the publishing.
- "Achieving all knowledge does not mean achieving all wisdom."
- "What makes you smart
?"
|
|
|
|
|
What are you emailing - the link to the published .application file? That's what you should email.
Can you give us the exact error message? We can better help you then.
|
|
|
|
|
I tr to eMail the entire program. Say you attach a file to an eMail. I attach the program. When they get the eMail, it syas certain vital files are missing.
- "Achieving all knowledge does not mean achieving all wisdom."
- "What makes you smart
?"
|
|
|
|
|
You should zip up all your application files -- go to the folder where your source code is, go in to the bin\debug directory, and zip up all the files there. Email that zip file.
|
|
|
|
|
I have created a user control,right now i want to have attribute of usercontrol which it's String type,and I don't input by hand which instead of I will chose a name for my attribute,same same chose combobox.
Example in Form 'S attribute ,there is a attribute about color
we don't input,instead of we will chose,I also want that
|
|
|
|
|
I can't understand what you are saying. Are you talking about enumerations[^]?
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
Ok,I will repeat what I have said,and please help me
I have a usercontrol which Mycontrol and I want create it's attribute
exam:
protected bool m_TrangThai;
[Browsable(true)]
public Boolean TrangThaiQuanCo
{
get { return this.m_TrangThai; }
set { this.m_TrangThai = value; }
}
My problem I don't know create a combobox as backcolor attribute of Form,so I want to ask you about it
|
|
|
|
|
Hi,
Does anyone know if it's possible to trigger an event whenever a video frame is being refreshed (e.g., every 50 ms for a 20 fps frame rate)? It can be either with DirectX or WMP SDK (or anything else within .NET. Alternatively, I could poll the video player and ask which frame is being played. Can't do that either at this point.
Thank you,
Yigal Agam
|
|
|
|
|
|
I'm not sure if this is the right forum to post this in, but I'm not sure where it fits.
My company distributes some reference books on CD-ROM using 3rd party software called Folio Views. The actual content stays on the CD, but what is called a shadow file gets installed on the user's drive. The shadow file allows the user to highlight and annotate the text with out modifying the actual content (the shadow file acts like an overlay). Because of this the shadow file needs to be modifiable by the user. On Vista, the software gets installed as administrator (after UAC click), but when the user launches the software it loads with the users permissions so they can't write to the shadow file and the load fails. I'm using the setup project built into Visual Studio 2005 right now, but we may buy InstallShield if its better, for this and I can't find an option to set permissions on the files. Is there a custom action I can assign to make the file writable by the "users" group?
Thanks.
|
|
|
|
|
You could fiddle with the permissions in a custom action, yes. This isn't really addressing the root cause of the problem, which is that your shadow file is in the wrong place. I'm guessing you've stuck it in the program files directory - it really should be in the user's profile, under application data, or Documents.
|
|
|
|
|
Yeah, unfortunately I have to work within the bounds of some third party software and there isn't a way to automatically generate a new shadow file for each user so I need to do it this way. Do you know what the command should be in the custom action?
|
|
|
|
|
Ah well if you add a custom action, then you should be able to use the System.IO.File.GetAccessControl(name); to get a FileSecurity object, and then use fsec.AddAccessRule(new FileSystemAccessRule(...));
|
|
|
|
|
What I need to do is append the string " + \" to the last line of a file and then go to the next line and write a string. It would seem something like this should work.
Texg.Write(" + \\");
Texg.Write("\n");
Texg.Write("New Text String");
I get this as output where the @ sign is a rectangle:
+ \ @ A Text String + \@ A Text String + \@ A Text String
What I want is:
+ \
A Text String + \
A Text String + \
A Text String
This is easy in C++ and I am sure I missing something obvious.
|
|
|
|
|
|
Try
Texg.Write(" + \\");
Texg.WriteLine("New Text String");
or
Texg.Write(" + \\");
Texg.Write("\r\n");
Texg.Write("New Text String");
|
|
|
|
|
try:
Texg.Write(@" + \");
Texg.Write(Environment.NewLine);
Texg.Write(@"New Text String");
|
|
|
|
|
|
Well - that's a weird cross post.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
When I click on Create a Folder Button as below I get an error-Object reference not set to an instance of an object. How should I get rid of this error-Object reference not set to an instance of an object
private void btnCreate_Click(object sender, EventArgs e)
{
try
{
if (tvFavorites.SelectedNode.Tag == null)
{
OleDbCommand insertfolder = new OleDbCommand("insert into favFolders (folder_name,folder_parent) values('" + txtFolderName.Text + "'," + tvFavorites.SelectedNode.Name + ") ", dbProfiles);
if (dbProfiles.State == ConnectionState.Closed)
dbProfiles.Open();
insertfolder.ExecuteNonQuery();
string folder_id = "";
insertfolder.CommandText = "select max(folder_id) from favFolders";
folder_id = insertfolder.ExecuteScalar().ToString();
dbProfiles.Close();
TreeNode tn = new TreeNode();
tn.Name = folder_id;
tn.Text = txtFolderName.Text;
tvFavorites.Nodes.Add(tn);
}
else
{
OleDbCommand insertfolder = new OleDbCommand("insert into favFolders (folder_name,folder_parent) values('" + txtFolderName.Text + "'," + tvFavorites.SelectedNode.Parent.Name + ") ", dbProfiles);
if (dbProfiles.State == ConnectionState.Closed)
dbProfiles.Open();
insertfolder.ExecuteNonQuery();
string folder_id = "";
insertfolder.CommandText = "select max(folder_id) from favFolders";
folder_id = insertfolder.ExecuteScalar().ToString();
dbProfiles.Close();
TreeNode tn = new TreeNode();
tn.Name = folder_id;
tn.Text = txtFolderName.Text;
tvFavorites.Nodes.Add(tn);
}
txtFolderName.Text = "";
lblFolderName.Visible = false;
txtFolderName.Visible = false;
btnCreate.Visible = false;
btnCancel.Visible = false;
}
catch (Exception ex)
{
func.ErrorReporter(ex, "008010");
//This line opens the specified file or creates it if it does not exist
//Note that you must use a double slash in the string instead
System.IO.FileStream myLog = new System.IO.FileStream("C:\\myFile.txt", System.IO.FileMode.Open);
//Creates the new TraceListener that specifies myLog as the target for the output
TextWriterTraceListener myListener = new TextWriterTraceListener("C:\\myFile.txt");
//Adds myListener to the Listeners collection
Trace.Listeners.Add(myListener);
Trace.Write("Object reference not set to an instance of an object");
Trace.Flush();
}
}
|
|
|
|
|
Somewhere in your code you are attempting to work with an object reference that does not point to an actual object.
You should step through your code using the debugger to identify which object reference is causing the problem.
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
Thanks for your reply. But I want to know this process of Stepping through the code. Can you please guide me. When I clicked on Debug pulldown menu and clicked on Step Into the application starts to run. What are the next steps I need to take?
|
|
|
|
|
RTFM[^]
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|