|
If the library requires some interaction with the UI, doing things in the constructor of a form is often too early. Better add a button to you form, and do the things in the click event handler. Not sure if that will help here.
|
|
|
|
|
When the entity include a field which is DbGeometry or DbGeography , it will return a error message "The provider did not return a DbSpatialServices instance."
|
|
|
|
|
Hi guys!
I'm not sure this is the right place for this so forgive me if it's not but here goes.
I've made a USB board called PeekyPokey with an API so that you can use .NET languages such as C# for interfacing with electronics stuff like relays, RFID tag readers, tactile buttons, rotary encoders, keypads, sensors, servos and things like that. Project home page on CodePlex:
http://www.peekypokey.org/
The API also comes with an extensive toolkit containing classes for the PC side of things too - like a built in webserver, gamepad drivers, virtual keys, midi interface, general HID interface and so on - things you can use to control electronic devices.
In essence, PeekyPokey has 8 general input/outputs, a virtual COM port, 3.3V/5V power supplies and kind of brings Windows PCs and electronics together in pretty much the same way IOIO does for Android.
The PeekyPokey board targets programmers curious of embedded electronics programming and hardware interfacing. The whole idea is to play, explore, learn and have fun with electronics.
I'm wondering if you'd be interested in me writing an article about the board and how to use it?
NOTE: I'm not selling the boards, I'm just the creator.
Thanks!
|
|
|
|
|
hanzibal2 wrote: I'm not sure this is the right place for this so forgive me if it's not but here goes.
It looks like your tool is free, so post it in the Free Tools forum[^].
|
|
|
|
|
|
I'm working on a dynamic data website with linqtosql dbml file. Could anyone please help in giving some examples on how to update records displayed in a formview that allows paging? The formview exists in the "Edit.aspx" page with DefaultMode="Edit" and DataSourceID="DetailsDataSource" where "DetailsDataSource" is a LinqDataSource with EnableUpdate="true". The bottomrow of the formview contains a LinkButton with CommandName="Update" to perform the update operation. Once I change some info in the bounddatafieds and then click on the linkbutton, the formview loads with empty datafields and no updates are saved to the database.
Any help will be much appreciated.
Thank you.
|
|
|
|
|
how can i start a shell and execute a command and capture output using ganymed-ssh2 c# library
|
|
|
|
|
Considering that's a Java library, there is no direct way to use in .NET.
You'd have to use a "bridge" library to use that in C#. Something like JNI4NET[^] should do it.
As for exactly what you have to do with that SSH2 library, I have no idea. I've never used it nor will I as it's open source and there is no support for it at all.
|
|
|
|
|
|
Hi there !
I haved mapped a network resource to drive "S:". There is a need for username and password to access this path.
Now i'm tryin to write a Windows Service (by using a VS Windows Service Project), which does in a certain interval something with the files located on "S:"
I've tried to put the Account-Property of the corresponding serviceProcessInstaller-Instance to "User" and filled the Username- and Password-Properties with the values of the current User (who has the rights to access this path via windows explorer).
Before accessing some files, my code checks the directory
like:
if (Directory.Exists("S:\\SubDir"))
{
//do it !
}
If i copy my code to a default VS windows console project, it works! But by running my code in a Windows Service the Directory.Exists("S:\\SubDir")-Condition returns false.
Are there missing rights ?
can i include the credentials for accessing this path in my code ? maybe something like this:
SomeType DriveS = new SomeType("S:","username","password");
DriveS.TryToAccess();
Any Ideas ?
Jeff
|
|
|
|
|
Any Ideas:
Your service runs with an account which has no network access at all.
Run your service under an account which can access the the folder. You can change that in mmc.exe in the Properties page of the service.
|
|
|
|
|
Hi,
If you are using Shared folder in the network you may need to create networkconnection to connect using your network credentials.
Check this thread for your answers.[^]
Let us know if this is not working for you.
Thanks
-Amit Gajjar
|
|
|
|
|
Member 10027439 wrote: I haved mapped a network resource to drive "S:". There is a need for username
and password to access this path.
Two parts
1. Map drive
2. Provide credentials to access.
I don't see where you stated how you achieved the first.
|
|
|
|
|
You don't mention how you map the drive and on what OS it is. If you are mapping the drive in a login script on Vista or higher, you have to elevate the script to admin level to do the mapping. The problem is that it will not appear in user space even though it will show up in windows explorer. If your service is running under a user account, it will by default run in the limited user space and will not have access to mapped drives in the admin space. This is an infuriating implementation because Windows handles these issues for the console user but not for processes running as that user.
In this case, the solution is linked connections. There is a registry key you need to add called EnableLinkedConnections. I don't remember the path right now but Google will tell you. If you are mapping drives in a login script and running your service under a user account, you need the linked connections enabled on Vista or Win 7/8. If your login script is a powershell script, you can even set the linked connections from the script provided it is signed and you allow remote scripts to execute.
|
|
|
|
|
Hi guys !
Thank you for your replies !
@Bernhard Hiller:
I already tried this - Didnt work
@AmitGajjar:
Yeah, this solution works. But i have to use the real network path ("\\192.168.2.168\MyFolder") instead of "S:". Thank you !
@jschell / Jason Gleim:
Well... I'm using Windows 7 and mapped via windows explorer the network resource "\\192.168.2.1168\MyFolder" to a network share 'S:' without any scripts. (well i didnt guess the english term 'network share' ) By doing this via windows explorer i provided the needed credentials.
So my mind was that i can write a c# program which is logged in as the user who mapped the network share and because of this there will be no need for providing the credentials again in my code.
|
|
|
|
|
Hi...
I have one groupbox control containing two combobox in that .That groupbox is present in one form at perticuler location...I want to display that same groupbox control in another form with same loaction.without any issue of screen resolution.
Thanks
|
|
|
|
|
OK, go ahead, and if you have any problems feel free to come back here with a detailed question.
Veni, vidi, abiit domum
|
|
|
|
|
Create form in a external page and call this page by iframe at anywhere like....
<iframe src="external-page.aspx" width="300" height="300">
</iframe>
|
|
|
|
|
A single instance of a .NET control cannot be "in" two Forms at the same time.
So, some clarification from you would be helpful:
1. I assume you are using Windows Forms, but please confirm that. Some folks do use the term "Form" (incorrectly) when they are describing WPF.
2. is it the case that at any given time only one of the two Forms will be visible to the end-user, or, are there cases where both will be visible ? If both Forms can be visible, and you want to show your GroupBox on only one of them: what determines on which visible Form it is shown ? Another way of asking this question is to ask: is the location on the screen of both Forms the same... in which case, if their size, and other attributes, like FormBorderStyle, are the same: one will "cover" the other.
3. are both Forms identical in every way, but, location: size, FormBorderStyle, StartPosition, appearance, etc. ?
4. are you using the standard WinForms model in which the Program.cs file, in its static class 'Program contains a static 'Main method in which you have the usual code to start your application, like: Application.Run(new MainForm()); ? That may seem like an odd question, but there is a reason I'm asking it, which I'll explain once you provide more information.
5. what do you mean by: "without any issue of screen resolution;" what could a screen resolution issue be ? Could you mean, by this statement, a possible overlapping of the two Forms when both are displayed (made visible) ?
6. are you familiar with using static classes now ?
bill
Google CEO, Erich Schmidt: "I keep asking for a product called Serendipity. This product would have access to everything ever written or recorded, know everything the user ever worked on and saved to his or her personal hard drive, and know a whole lot about the user's tastes, friends and predilections." 2004, USA Today interview
modified 6-Sep-13 2:42am.
|
|
|
|
|
|
For static members, do you prefer
public static Type Member; or
static public Type Member; where public can be any of the visibility keywords.
I've found I use both , and I'm trying to find out if there's a best practice out there that makes sense.
Software Zen: delete this;
|
|
|
|
|
I prefer option 1, but whichever option you pick, consistency is the key!
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
I use both too, but tend to group the statics at the bottom of the class in it's own region.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
I prefer to put visibility first, and for what it's worth, I don't think I would make a static field public.
|
|
|
|
|
Espen Harlinn wrote: I don't think I would make a static field public I normally don't, but for the purposes of the example...
Software Zen: delete this;
|
|
|
|